Chapter 18 - Introduction to SQL Flashcards
What is SQL?
» SQL is a declarative language used to query and update tables in a relational database
What does the SELECT command do?
» Used to extract a collection of fields from a given table
What does the FROM command do?
» Specifies from which table the data will come from
What does the WHERE command do?
» Lists the search criteria
What does the ORDER BY command do?
» List the fields that the results are to be sorted on
What is one key feature to remember about the ORDER BY command?
» Default order is always ASC
What are the 2 types of commands in the ORDER BY statement?
» ASC
» DESC
What does the = command mean?
» Equal to
» Such as Title = “Death note”
What does the != command mean?
» Not equal to
What does the >= command mean?
» Greater than or equal to
What does the <= command mean?
» Less than or equal to
What does the IN command do?
» Equal to a value within a set of values
What is the LIKE command?
» Similiar to
What does the BETWEEN..AND command mean?
» Within a range
» Such as Datepublish BETWEEN 01 AND 31
What is the IS NULL operator?
» Field does not contain a value