> For the complete documentation index, see [llms.txt](https://pavithrasundaram091097s-organiza.gitbook.io/my-space/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://pavithrasundaram091097s-organiza.gitbook.io/my-space/skills/hackerrank/employee-names.md).

# Employee Names

Write a query that prints a list of employee names (i.e.: the *name* attribute) from the **Employee** table in alphabetical order.

{% embed url="<https://www.hackerrank.com/challenges/name-of-employees/problem?isFullScreen=true>" %}

Sol:

SELECT name FROM Employee ORDER BY name asc;

Explanation:

* SELECT name: This part of the query specifies that we want to retrieve the values from the name column of the Employee table.
* FROM Employee: This specifies the table from which we want to retrieve the data, which is the Employee table.
* ORDER BY name ASC: This part of the query specifies the order in which the results should be sorted. It orders the results in ascending order based on the values in the name column.
