Query Methods Simple SQL Statements Start …
All – most - some ... ALL : Define the term SQL MOST : Describe the syntax for SQL statements SOME : Explain how to use SQL statements on a database Next …
Click to explore more about the SQL Statements … What is a Database? SQL Statements? Thought board What is SQL? Select Statements
What is a Database ..? A database is just a collection of data A simple database could be a computing text book Next …
What is a Database ..? Data about each topic is stored in the book The data is organised into chapters You can search for a topic using the content and index pages Back … Next …
What is a Database ..? Organisations have data that they need to store, collate and analyse 30 years ago this data would have been stored in a filing cabinet Back … Next …
What is a Database ..? Modern organisations use computer systems to store, collate and analyse data These systems are called Databases Back … Explore …
What is SQL ..? SQL (Structured Query Language) is used to search through and manage databases SQL is written as statements that are executed by the database Next …
What is SQL ..? SQL statements can be used to perform the following tasks … Execute queries against a database Retrieve data from a database Insert records in a database Update records in a database Delete records from a database Back … Explore …
Simple SQL Statements … We use SQL Statements to manage large databases SQL statements can be used to Select Data, Update Data and Delete Data Next …
Simple SQL Statements … Think about this SQL Statement … SELECT * FROM Customers; What do you think this SQL statement will do? Back … Next …
Simple SQL Statements … Think about this SQL Statement … SELECT * FROM Customers; This is known as a Select Statement It will select all the data from the Customers table Back … Next …
Simple SQL Statements … SELECT * FROM Customers; Notice that … SELECT and FROM are in capitals The asterisk (*) means everything The semi-colon (;) marks the end of the SQL statement Back … Explore …
Select Statements … The SELECT statement is used to select data from a table The result is stored in a result table, called the Result-Set Next …
Select Statements … SELECT column_name,column_name FROM table_name; SELECT * FROM table_name; What do you think these two SQL statements will do? Will they select the same data? Northwind – create a select statement to ….. Back … Next …
Select Statements … To select data from the Customers table in a database, you could use this statement … SELECT CustomerName,City FROM Customers; Back … Next …
Select Statements … SELECT CustomerName,City FROM Customers; This statement will select the CustmerName and City fields from the Customers table Back … Next …
What do you think this SQL statements will do? Select Statements … Rather than specifying what fields are to be selected, you can add the astrick (*) SELECT * FROM Customers; What do you think this SQL statements will do? Back … Next …
Select Statements … SELECT * FROM Customers; This statement selects everything from the Customers table Back … Explore …
Thought Board … SELECT * FROM Customers; SELECT CustomerName,City FROM Customers; Explore …