From the course: SQL Essential Training

Unlock the full course today

Join today to access over 23,100 courses taught by industry experts.

Simplifying JOINs

Simplifying JOINs

- [Instructor] So we've seen from our example that's in front of us, our first example that joins have a special syntax when referring to field names. Since two tables in any given database may have fields with the identical names, when creating joins, we must specify the table name followed by the column name that we would like to join so that the SQL browser knows exactly which version of the field we are referencing. Now this syntax requires that the table name be listed first followed by the column or field name. Now joins are often used with aliases just as we visited prior. Now we introduce aliasing to reduce the amount of typing that's required when we're building out a SQL statement with a join. Let's visit how we would do this. Now I'm going to make some alterations that's going to be more in line with a real world query when we are building a SQL statement with a join. Here we have the invoice, and I'm just going…

Contents