In SQL, we use two kinds of aliases. These are Table alias and Column alias.
The function of Column alias is to put in order the output. It is much easy to access and read the output.
The other kind of alias is Table alias. We have to place as alias after the name o the table. It should be in the clause FROM. It makes the way easy when we have to get our input from two different tables. The benefit of alias can be seen while doing joins.
Here, the basic structure of table and column alias is given:
FROM "table_name" "table_alias"
We have to use the alias behind the item for which it is used. The distance can be shown by white gap.
Los Angeles $1550 Jan-06-2011
San Diego $350 Jan-07-2011
Boston $400 Jan-08-2011
Boston $750 Jan-09-2011
The reference is just like GROUP BY clause.
FROM Store_Information A1
GROUP BY A1.store_name
Los Angeles $1550
San Diego $350