Basic SQL Terminology

  • SQL Query — A SQL Query is just simple SQL code to return data, can also be called a SQL statement. You may hear “write me a SQL Query to get data on California from a database”. It can be as short as one line and as long as thousands of lines long.

  • Database Vs Table — A database holds multiple tables. Think of a Table as a sheet within an Excel workbook, and the Database is the entire Excel workbook that has multiple Excel sheets. You will specifically query data from a single Excel sheet, AKA querying data from a single SQL table (that’s within a specific database)

    • Consider an Excel workbook with population statistics on all 50 states. A single sheet may contain specific, detailed data on New York while another sheet will have data for California. The table would be the same as the New York sheet or the California sheet, while the entire Excel workbook can be compared to the SQL database.