Home > Articles > Data > SQL

  • Print
  • + Share This
This chapter is from the book

Using Fully Qualified Table Names

The SQL examples used thus far have referred to columns by just the column names. Referring to columns using fully qualified names (using both the table and column names) is also possible. Look at this example:

Input

SELECT products.prod_name
FROM products;

This SQL statement is functionally identical to the first one used in this lesson, but here a fully qualified column name is specified.

Table names, too, may be fully qualified, as shown here:

Input

SELECT products.prod_name
FROM crashcourse.products;

Once again, this statement is functionally identical to the one just used (assuming, of course, that the products table is indeed in the crashcourse database).

Situations exist where fully qualified names are required, as we will see in later lessons. For now, it is worth noting this syntax so you’ll know what it is if you run across it.

  • + Share This
  • 🔖 Save To Your Account