Getting all the users who have author privilege

Unless you want to retrieve custom data from the database, you will hardly ever need to make use of the WPDB class (or its global object, respectively). Though it is obviously possible to do things that way as well.

Just for the sake of completeness, if you had a reason to not use a more abstract function, you’d have to employ JOIN in the select syntax as user roles live in the usermeta table.

But it’d be much simpler to make use of the get_users function:

$args = array(
    'role'         => 'author',
    'orderby'      => 'display_name'
);
$authors = get_users( $args );

[EDIT] As for the question in the comments (ordering by the number of posts):

Use 'post_count' as an argument for the 'orderby' parameter (and read the linked codex page, which gives you all the possible arguments).