The SELECT statement is used to fetch data from a HIVE table.
column1,column2 are the columns of the table./p>
The '*' is used to select all the fields from the table
emp_id | city |
---|---|
101 | California |
102 | Mumbai |
103 | Delhi |
104 | Bangalore |
105 | Delhi |
Selects only emp_id and city.
emp_id | name | city | salary |
---|---|---|---|
101 | John | California | 50000 |
102 | Tom | Mumbai | 40000 |
103 | Harry | Delhi | 80000 |
104 | Rahul | Bangalore | 60000 |
105 | Sakil | Delhi | 90000 |
Selects all the values from Employee table.