Access Review
Access Objects Tables Queries Forms Reports Relationships
How Access Saves a Database The Save button in Access differs from the Save button in other Windows programs such as Word and Excel. When you press the Save button in Access, you are saving the design of an Access object and NOT the data or the file itself. Access automatically saves data as it is entered into the database.
Object Creation Create tab on the ribbon bar. Tables Queries Forms Reports
Object Creation Database Tools tab on the ribbon bar. Relationships
Table Creation The best method to use is Table Design.
Table Creation Type in each field name. Select each field s data type. Only if necessary, modify each field s various properties. Only if necessary, set the primary key field of the table. Finally, save the table and give the table a name.
Form Creation The best method to use is Form Wizard.
Form Creation At each step of the Form wizard, you may or may not need to do anything depending on the requirements given on the exam paper.
Report Creation The best method to use is Report Wizard.
Report Creation At each step of the Report wizard, you may or may not need to do anything depending on the requirements given on the exam paper.
Create a Query in Design View Step 1 click the Query Design button in the Create tab ribbon on the ribbon bar to open a new blank query in design view. Step 2 In the Show Table dialog box, add only those tables to the query window that are required. Then, close the Show Table dialog box. Step 3 Add to the query design grid only those fields that are required. Step 4 If necessary, choose a sort order, either ascending or descending, to only those fields that are required. Step 5 Create the query s criteria for only those fields for which a criteria is needed. Step 6 Save the query with the specified name.
Query 1 List all of the products whose unit price is less than 100 dollars using the ProductName, UnitsOnOrder, and UnitPrice fields of the Products table. Sort the query in ascending order according to the ProductName field. Save this query as Products Costing Less Than 100 Dollars.
Query Creation Step 1 Start Click the Query Design button.
Query Creation Step 2 Add Tables To add the table(s) to the query window. Double-click only those tables that are required for the query.
Query Creation Step 3 Add Fields Double-click only those fields that are required for the query. To add the fields to the query design grid.
Query Creation Step 4 Sort If necessary, choose a sort order, either ascending or descending, to only those fields that a sort is required.
Query Creation Step 4 Sort Choose the sort order.
Query Creation Step 4 Sort
Query Creation Step 5 Criteria Create the query s criteria for only those fields for which a criteria is needed.
Query Creation Step 5 Criteria This is the only criteria for the example query question
Query Creation Step 6 Save
Numeric Criteria Comparison operators o > o < o >= (greater than or equal to) o <= (less than or equal to) o <> (not equal to) Treat values in the criteria of currency fields just like the values in the criteria of number fields. Leave the currency symbol ($) out of the criteria.
Using the And Logical Operator When you need to use multiple criteria for a query, you use the appropriate logical operators to combine the criteria. The And logical operator specifies that all criteria must be met. Multiple criteria on the same row of the query design grid combine the criteria into an And criteria.
Query 2 Multiple Criteria Same Field Logical AND operator List all of the books whose list price is greater than 30 dollars and less than 40 dollars using the Title, ListPrice, and Publisher fields of the Books table. Sort the query in ascending order according to the ListPrice field. Save this query as Mid Priced Books.
Query 2 Multiple Criteria, Same Field
Query 3 Multiple Criteria Different Fields Logical AND operator List all of the products whose units on order is equal to 0 and whose unit price is less than 50 dollars using the ProductName, UnitsOnOrder, and UnitPrice fields of the Products table. Save this query as Products Not on Order Costing Less Than 50 Dollars.
Query 3 Multiple Criteria, Different Fields
Using the Or Logical Operator When you need to use multiple criteria for a query, you use the appropriate logical operators to combine the criteria. The Or logical operator specifies that one or the other of the criteria must be met Multiple criteria must be on separate rows to create an Or criteria.
Query 4 Multiple Criteria Same Field Logical OR operator List all of the products whose units in stock is less than 20 or greater than 100 using the ProductName, UnitsInStock, and UnitPrice fields of the Products table. Save this query as Products with Few or Many in Stock.
Query 4 Multiple Criteria, Same Field
Query 5 Multiple Criteria Different Fields Logical OR operator List all of the books that are published after 1996 or whose list price is greater than or equal to 40 dollars using the Title, Year, ListPrice, and Publisher fields of the Books table. Save this query as New or Expensive Books.
Query 5 Multiple Criteria, Different Fields
General Text Field Criteria Criteria for Text Fields not involving specific values utilize patterns. Patterns utilize the wildcard character * The wildcard character represents any sequence of 0 or more characters.
General Text Field Criteria Three types of general patterns. o Begins with. o Ends with. o Contains.
Query 6 General Text Field Criteria Begins with pattern List all of the books where the author s name begins with the letter G using the Title, Author, Year, and ListPrice fields of the Books table. Save this query as Authors beginning with a G.
Query 6 Begins With Pattern The criteria is: Like G*
Query 7 General Text Field Criteria Contains pattern List all of the books where the title contains the word the using the Title, Author, Year, and ListPrice fields of the Books table. Save this query as Book Titles Containing the Word The.
Query 7 Contains Pattern The criteria is: Like *the*
Query 8 General Text Field Criteria Ends with pattern List all of the books where the author s name ends with the letter T using the Title, Author, Year, and ListPrice fields of the Books table. Save this query as Authors ending with a T.
Query 8 Ends With Pattern The criteria is: Like *T