Cheltenham Courseware Microsoft Access 2003 Manual - Advanced Level SAMPLE

Size: px
Start display at page:

Download "Cheltenham Courseware Microsoft Access 2003 Manual - Advanced Level SAMPLE"

Transcription

1 Cheltenham Courseware Microsoft Access 2003 Manual - Advanced Level

2 Microsoft Access Advanced Level Manual - Page Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without written permission from Cheltenham Courseware unless produced under the terms of a courseware site license agreement with Cheltenham Courseware. All reasonable precautions have been taken in the preparation of this document, including both technical and non-technical proofing. Cheltenham Courseware and all staff assume no responsibility for any errors or omissions. No warranties are made, expressed or implied with regard to these notes. Cheltenham Courseware shall not be responsible for any direct, incidental or consequential damages arising from the use of any material contained in this document. If you find any errors in these training modules, please inform Cheltenham Courseware. Whilst every effort is made to eradicate typing or technical mistakes, we apologise for any errors you may detect. All courses are updated on a regular basis, so your feedback is both valued by us and will help us to maintain the highest possible standards. Sample versions of courseware from Cheltenham Courseware (Normally supplied in Adobe Acrobat format): If the version of courseware that you are viewing is marked as NOT FOR TRAINING,, or similar, then it cannot be used as part of a training course, and is made available purely for content and style review. This is to give you the opportunity to preview our courseware, prior to making a purchasing decision. Sample versions may not be re-sold to a third party. For current license information This document may only be used under the terms of the license agreement from Cheltenham Courseware. Cheltenham Courseware reserves the right to alter the licensing conditions at any time, without prior notice. Please see the site license agreement available at: Contact Information Australia / Asia Pacific / Europe (ex. UK) / Rest of the World info@cheltenhamcourseware.com.au Web: USA / Canada info@cheltenhamcourseware.com Web: UK info@cctglobal.com Web: Cheltenham Courseware Pty. Ltd

3 Microsoft Access Advanced Level Manual - Page 3 INSTALLING THE FILES...5 USING THE NORTHWIND DATABASE...6 INSTALLING THE NORTHWIND DATABASE...6 REVIEW QUESTIONS...8 INTRODUCING STRUCTURED QUERY LANGUAGE...9 WRITING SQL COMMANDS...10 WRITING SQL QUERIES...11 WRITING SQL SUBQUERIES...16 WRITING SQL JOINS...18 INSERTING DATA...21 UPDATING DATA...23 DELETING DATA...24 WRITING SQL QUERIES IN ACCESS REVIEW QUESTIONS...30 WORKING WITH MACROS...32 AUTOMATING TASKS...32 INTRODUCING THE MACRO DESIGN TOOLBAR...33 CREATING MACROS...35 TESTING AND DEBUGGING MACROS...38 MODIFYING MACROS...41 CONDITIONAL PROGRAMMING IN MACROS...41 ADDING MACROS TO FORMS...45 ADDING MACROS TO REPORTS...47 FILTERING DATA...49 DOCUMENTING MACROS...55 REVIEW QUESTIONS...56 PROGRAMMING ACCESS USING VISUAL BASIC...57 USING MACROS VERSUS VISUAL BASIC...57 UNDERSTANDING VISUAL BASIC CONCEPTS...62 USING THE VISUAL BASIC EDITOR WINDOW...68 GETTING HELP WITH VISUAL BASIC...72 REVIEW QUESTIONS...75 USING DATA ACCESS PAGES...76 CREATING DATA ACCESS PAGES...76 MODIFYING DATA ACCESS PAGES...91 SORTING DATA IN DATA ACCESS PAGES...98 SUMMARISING DATA IN DATA ACCESS PAGES...99 EDITING DATA IN DATA ACCESS PAGES PROTECTING DATA IN DATA ACCESS PAGES REVIEW QUESTIONS CONVERTING ACCESS DATABASES CONVERTING DATABASES TO ACCESS CONVERTING FROM ACCESS 2003 TO ACCESS CONVERTING FROM ACCESS 2003 TO ACCESS REVIEW QUESTIONS CUSTOMISING ACCESS CONFIGURING ACCESS 2003 OPTIONS CONFIGURING AUTOCORRECT OPTIONS CUSTOMISING MENUS AND TOOLBARS REVIEW QUESTIONS MANAGING & MAINTAINING DATABASES Cheltenham Courseware Pty. Ltd

4 Microsoft Access Advanced Level Manual - Page 4 OPTIMISING DATABASES WITH TABLE ANALYZER OPTIMISING DATABASES WITH PERFORMANCE ANALYZER DOCUMENTING DATABASES WITH DOCUMENTER ANALYZER AVOIDING ERRORS WITH THE OBJECT DEPENDENCIES TASK PANE REVIEW QUESTIONS Cheltenham Courseware Pty. Ltd

5 Microsoft Access Advanced Level Manual - Page 5 Installing the Sample Files Use Windows Explorer to create a folder called Access 2003 Advanced Samples, in the My Documents folder. If you are installing the sample files from the CD-ROM, place the CD-ROM in the CD drive and copy the files from the access_2003_advanced_eur\exercise_files to the My Documents\Access 2003 Advanced Samples folder. If these files have been copied to your network server, then ask your trainer/supervisor for more information about how to copy these files to your PC s hard disk. Notes for tutors: The above instructions are for Windows that has not been set-up for a multiuser environment (with individual profiles). The instructions above may require modification within a Windows mutiuser environment. Where possible pre-install the relevant work files prior to use by students/delegates. Cheltenham Courseware Pty. Ltd

6 Microsoft Access Advanced Level Manual - Page 6 Using the Northwind Database When you have completed this learning module you will have seen how to: Check for Northwind Install Northwind Installing the Northwind Database About Northwind Northwind is a sample database which ships with Access It contains product and sales data for the fictitious company Northwind Traders. It is recommended that Northwind be installed to follow the lessons in this manual. Checking for Northwind Click the File Search button on the database toolbar: In the Search text box of the Basic File Search task pane, type Northwind. In the Search in area of the task pane, choose Everywhere from the drop down menu. Click Go. If Northwind.mdb appears in the Search Results, double-click on the file to open it and proceed to the next chapter. If Northwind is not found in the Search Results it will need to be installed. Installing Northwind Insert the Microsoft Office 2003 CD-ROM in the CD-ROM drive. Double-click Setup. Note: If your computer has autorun enabled, you will be presented directly with the Microsoft Office 2003 setup screen. Select Add or Remove Features. Click Next. Select both the Access and Choose advanced customization of applications checkboxes. Click Next: Cheltenham Courseware Pty. Ltd

7 Microsoft Access Advanced Level Manual - Page 7 Under Choose update options for applications and tools, select the Microsoft Office Access subtree. Under Sample Databases, select Run all from My Computer: Click Update. Cheltenham Courseware Pty. Ltd

8 Microsoft Access Advanced Level Manual - Page 8 Once the installer completes, click OK to finish. Once the Northwind database is installed, search for it again and open it. Note: You may notice that the Northwind database utilises the older Access 2000 file format. Please note that all pictures and examples in this training manual will display the new Access file format. If you wish, you can convert Northwind into an Access database. For more information, please refer to the file conversion chapter later in this manual. Review Questions How would you: Check for Northwind? Install Northwind? Cheltenham Courseware Pty. Ltd

9 Microsoft Access Advanced Level Manual - Page 9 Introducing Structured Query Language When you have completed this learning module you will have seen how to: Understand SQL Statements Understand SQL Conventions Understand SQL Syntax Use SELECT Statement Select All Data Select Specific Data Select Conditional Data Use ORDER BY Statement Sort Data Use Aggregate Functions Calculate Data Use GROUP BY Statement Group Data Create a Subquery with Equality Create a Subquery with an Aggregate Function Use ANY and ALL Statements Understand SQL Joins Create a Simple Join Sort a Join Create Outer Join Create Left Outer Join Create Right Outer Join Create Full Outer Join Use INSERT Statement Understand INSERT Statement Rules Insert Data using VALUES Insert Data using Defaults Insert Data using SELECT Use UPDATE Statement Update All Rows Update Specific Rows Update Multiple Columns Use DELETE FROM Statement Delete Specific Rows Delete All Rows View SQL in Access 2003 Understand SQL in Access 2003 Write SQL Specific Queries Find Help on SQL Queries Cheltenham Courseware Pty. Ltd

10 Microsoft Access Advanced Level Manual - Page 10 Writing SQL Commands Structured Query Language (SQL) Bases Structured Query Language is called SQL for short. SQL consists of standard English words. Like all programming languages, SQL has specific conventions and grammatical syntax. A wide range of users can use SQL, including Database Administrators, management personnel, application programmers, and other types of end users. Understanding SQL Statements SQL statement consists of reserved words and user-defined words: Reserved words are a fixed part of SQL. They must be spelled exactly as required and cannot be split across lines. User-defined words are created by the user and represent names of various database objects such as relations, columns, views, etc. Understanding SQL Conventions SQL is more readable if indentation and lineation are used. Each clause in a statement should begin on a new line. Start of a clause should line up with start of other clauses. If clause has several parts, they should each appear on a separate line and be indented under the start of clause. Upper case letters represent SQL reserved words. Lower case letters represent user-defined words. A vertical bar ( ) indicates a choice among alternatives. Curly braces ( { } ) indicate a required element. Square brackets ( [ ] ) indicate an optional element. An ellipsis ( ) indicates optional repetition (0 or more times). Understanding SQL Syntax The main elements in SQL are the statements and clauses which make up statements. SELECT command indicates which fields are included in the query result. FROM clause indicates which table(s) the fields are retrieved from. The following is the syntax of the SELECT statement: Cheltenham Courseware Pty. Ltd

11 Microsoft Access Advanced Level Manual - Page 11 SELECT { * [column_name] [, ] } FROM table_name Writing SQL Queries Using SELECT Statement Data is selected using the SELECT statement. Order of the clauses cannot be changed. SELECT [predicate] { * [column_name] [, ] } FROM table_name [WHERE condition] [GROUP BY column_name] [HAVING group_condition] [ORDER BY column_name] ; SELECT command specifies which columns are to appear in the output. FROM clause specifies table or tables to be used. WHERE clause filters rows, subject to some conditions. GROUP BY clause forms groups of rows with the same column value. HAVING clause specifies conditions the grouped records must meet to be displayed. ORDER BY clause specifies the order of the output. Semicolon ; ends the SQL statement. Predicate is optional, and it restricts the number of results returned. There are four predicates: ALL includes all records. DISTINCT omits duplicate data in selected fields. DISTINCTROW omits data based on entire duplicate records. TOPn [PERCENT] limits the records to a number or percentage of records. Only SELECT and FROM are mandatory. Use * as an abbreviation for all columns. Selecting All Data Example 1: Retrieve All Columns, All Rows (list full details of all staff) SELECT sno, fname, lname, position, salary FROM staff; Example 2: Retrieve All data (list full details of all staff) Cheltenham Courseware Pty. Ltd

12 Microsoft Access Advanced Level Manual - Page 12 SELECT * FROM staff; The result table in either case is: sno fname lname position bno salary SL21 John White Manager B SG37 Ann Beech Snr Asst B SG14 David Ford Deputy B SA9 Mary Howe Assistant B SG5 Susan Brand Manager B SL41 Julie Lee Assistant B Selecting Specific Data Example 3: Retrieve Specific Columns, All Rows (produce a list of salaries for all staff, showing only the staff number, sno, the first and last names, and the salary details). SELECT sno, fname, lname, salary FROM staff; The result table is: sno fname lname salary SL21 John White SG37 Ann Beech SG14 David Ford SA9 Mary Howe SG5 Susan Brand SL41 Julie Lee Example 4: Calculated Fields (produce a list of monthly salaries for all staff, showing the staff number, the first and last names, and the salary details). SELECT sno, fname, lname, salary/12 FROM staff; The result table is: sno fname lname col4 SL21 John White SG37 Ann Beech SG14 David Ford SA9 Mary Howe SG5 Susan Brand SL41 Julie Lee Example 5: Named Calculated Fields In the example above, the 4 th column is labelled col4. To name this column use AS clause: Cheltenham Courseware Pty. Ltd

13 Microsoft Access Advanced Level Manual - Page 13 SELECT sno, fname, lname, salary/12 AS monthly_salary FROM staff; The result table is: sno fname lname monthly_salary SL21 John White SG37 Ann Beech SG14 David Ford SA9 Mary Howe SG5 Susan Brand SL41 Julie Lee Selecting Conditional Data Example 6: Comparison Search Condition (list all staff with a salary greater than ) SELECT sno, fname, lname, position, salary FROM staff WHERE salary > 10000; The result table is: sno fname lname position salary SL21 John White Manager SG37 Ann Beech Snr Asst SG14 David Ford Deputy SG5 Susan Brand Manager Example 7: Compound Comparison Search Condition (AND / OR) (list all staff with the position of Manager or Assistant) SELECT sno, fname, lname, position FROM staff WHERE position = Manager OR position = Assistant ; The result table is: sno fname lname position SL21 John White Manager SA9 Mary Howe Assistant SG5 Susan Brand Manager SL41 Julie Lee Assistant Cheltenham Courseware Pty. Ltd

14 Microsoft Access Advanced Level Manual - Page 14 Example 8: Pattern Match Search Condition (LIKE / NOT LIKE) (list all staff with any assistant position, looking for string Ass in their position) SELECT sno, fname, lname, position, salary FROM staff WHERE position LIKE %Ass% ; The result table is: sno fname lname position salary SG37 Ann Beech Snr Asst SA9 Mary Howe Assistant SL41 Julie Lee Assistant Note: SQL has two special pattern matching symbols: % percent represents any sequence of zero or more characters. _ underscore character represents any single character. Using ORDER BY Statement Data is sorted using the ORDER BY statement. Data is sorted in Ascending order by default. To sort data in Descending order, use DESC clause. Sorting Data Example 9: Single Column Ordering (list salaries for all staff, arranged in descending order of salary). SELECT FROM ORDER BY sno, fname, lname, salary staff salary DESC; The result table is: sno fname lname salary SL21 John White SG5 Susan Brand SG14 David Ford SG37 Ann Beech SA9 Mary Howe SL41 Julie Lee Cheltenham Courseware Pty. Ltd

15 Microsoft Access Advanced Level Manual - Page 15 Example 10: Multiple Column Ordering (list of all staff, arranged in ascending order of last name and position). SELECT FROM ORDER BY sno, fname, lname, position staff lname, position; The result table is: sno fname lname position SG37 Ann Beech Snr Asst SG5 Susan Brand Manager SG14 David Ford Deputy SA9 Mary Howe Assistant SL41 Julie Lee Assistant SL21 John White Manager Using Aggregate Functions There are five aggregate functions: COUNT returns the number of values in a specified column. SUM returns the sum of the values in a specified column. AVG returns the average of the values in a specified column. MIN returns the smallest value in a specified column. MAX returns the largest value in a specified column. Each function operates on a single column of a table and returns single values. COUNT, MIN and MAX apply to numeric and non-numeric fields. SUM and AVG apply to numeric fields only. COUNT(*) is a special use of COUNT which counts all rows of a table. Calculating Data Example 11: Use of COUNT(*) (find the total number of staff which have salary of 9000). SELECT COUNT(*) AS count FROM staff WHERE salary = 9000; The result table is: count 2 Example 12: Use of COUNT and SUM (find the total number of Managers and the sum of their salaries). SELECT COUNT(sno) AS count, SUM(salary) AS sum Cheltenham Courseware Pty. Ltd

16 Microsoft Access Advanced Level Manual - Page 16 FROM WHERE staff position = Manager ; The result table is: count sum Example 13: Use of MIN, MAX, AVG (find the minimum, maximum and average staff salary). SELECT MIN(salary) AS min, MAX(salary) AS max, AVG(salary) AS avg FROM staff; The result table is: min max avg Using GROUP BY Statement Data is grouped using the GROUP BY statement. Each item in SELECT list must be single-valued per group. All column names in SELECT list must appear in GROUP BY clause, unless the name is used only in an aggregate function. Grouping Data Example 14: Use of GROUP BY (find number of staff in each branch and their total salaries). SELECT FROM GROUP BY ORDER BY bno, COUNT(sno), AS count, SUM(salary) AS sum staff bno bno; The result table is: bno count sum B B B Writing SQL Subqueries Some SQL statements can have a SELECT embedded within them. A subselect can be used in the WHERE clause of an outer SELECT, where it is called a Subquery or Nested query. Cheltenham Courseware Pty. Ltd

17 Microsoft Access Advanced Level Manual - Page 17 Creating a Subquery with Equality Example 15: Use of Subquery with Equality (list the staff who work in the branch at 163 Main St ). SELECT sno, fname, lname, position FROM staff WHERE bno = (SELECT bno FROM branch WHERE street = 163 Main St ); Note: Inner SELECT finds branch number corresponding to branch at 163 Main St which is ( B3 ). Outer SELECT then retrieves details of all staff who work at this branch. The outer SELECT then becomes: SELECT sno, fname, lname, position FROM staff WHERE bno = B3 ; The result table is: sno fname lname position SG37 Ann Beech Snr Asst SG14 David Ford Deputy SL21 John White Manager Creating a Subquery with an Aggregate Function Example 16: Use of Subquery with Aggregate Function (list all staff whose salary is greater than the average salary). SELECT sno, fname, lname, position, salary FROM staff WHERE salary > (SELECT AVG(salary) FROM staff); Note: You cannot write WHERE salary > AVG(salary). Instead, you can use Subquery to find the average salary (17000), and then use outer SELECT to find those staff members with a salary greater than this: SELECT sno, fname, lname, position, salary FROM staff WHERE salary > 17000; The result table is: sno fname lname position salary SL21 John White Manager SG14 David Ford Deputy SG5 Susan Brand Manager Cheltenham Courseware Pty. Ltd

18 Microsoft Access Advanced Level Manual - Page 18 Using ANY and ALL Statements ANY and ALL may be used with subqueries which produce a single column of numbers. If Subquery is preceded by ALL, the condition will only be true if it is satisfied by all values produced by the Subquery. If Subquery is preceded by ANY, the condition will be true if it is satisfied by any values produced by the Subquery. Example 17: Use of ANY (find staff whose salary is larger than the salary of at least 1 member of the staff at branch B3). SELECT sno, fname, lname, position, salary FROM staff WHERE salary > ANY (SELECT salary FROM staff WHERE bno = B3 ); Note: Inner SELECT produces the set {12000, 18000, 24000} and outer SELECT lists those staff whose salaries are greater than any of the values in this set. The result table is: sno fname lname position salary SL21 John White Manager SG14 David Ford Deputy SG5 Susan Brand Manager Example 18: Use of ALL (find staff whose salary is larger than the salary of every member of the staff at branch B3). SELECT sno, fname, lname, position, salary FROM staff WHERE salary > ALL (SELECT salary FROM staff WHERE bno = B3 ); The result table is: sno fname lname position salary SL21 John White Manager Writing SQL Joins Cheltenham Courseware Pty. Ltd

19 Microsoft Access Advanced Level Manual - Page 19 Understanding SQL Joins In the previous examples, subqueries have provided results from the same table. If result columns come from more than one table, we must use a join. To perform a join, you must include more than one table in the FROM clause, using a comma as a separator and typically including a WHERE clause to specify join column(s). It is also possible to use an alias for a table, named in the FROM clause. An alias is separated from the table name with a space. Creating a Simple Join Example 19: Use of Simple Join (list names of all renters who have viewed a property). SELECT r.mo, fname, lname, pno FROM renter r, viewing v WHERE r.mo = v.mo; Note: To obtain correct rows, include only those rows from both tables which have identical values in the rno columns: r.mo = v.mo. These two columns are the matching columns for two tables. The result table is: mo fname lname pno CR56 Aline Stewart PG36 CR56 Aline Stewart PA14 CR56 Aline Stewart PG4 CR62 Mary Tregear PA14 CR76 John Kay PG4 Sorting a Join With an inner join, if one row of a table is unmatched, the row is omitted from the result table. Outer join retains rows which do not satisfy the join condition. Consider the following two simplified tables: BRANCH1 bno bcity B3 Glasgow B4 B2 Bristol London PROPERTY_FOR_RENT1 pno pcity PA14 Aberdeen PL94 London PG4 Glasgow Cheltenham Courseware Pty. Ltd

20 Microsoft Access Advanced Level Manual - Page 20 Example 21: The INNER JOIN of these two tables SELECT FROM WHERE b.*, p.* branch1 b, property_for_rent1 p b.bcity = p.pcity; OR SELECT FROM ON b.*, p.* branch1 b INNER JOIN property_for_rent1 p b.bcity = p.pcity; The result table is: bno bcity pno pcity B3 Glasgow PG4 Glasgow B2 London PL94 London Note: The result table has two rows where the cities are the same. There are no rows corresponding to the branches in Bristol and Aberdeen. Creating Left Outer Joins Example 22: Left Outer Join (list branches and properties which are in the same city along with any unmatched branches). SELECT FROM ON b.*, p.* branch1 b LEFT JOIN property_for_rent1 p b.bcity = p.pcity; The result table is: bno bcity pno pcity B3 Glasgow PG4 Glasgow B4 Bristol NULL NULL B2 London PL94 London Note: Left outer join includes those rows of first (left) table which are unmatched with rows from second (right) table. Columns from second table are filled with NULLs. Creating Right Outer Joins Example 23: Right Outer Join (list branches and properties in the same city and any unmatched properties). SELECT FROM ON b.*, p.* branch1 b RIGHT JOIN property_for_rent1 p b.bcity = p.pcity; Cheltenham Courseware Pty. Ltd

21 Microsoft Access Advanced Level Manual - Page 21 The result table is: bno bcity pno pcity NULL NULL PA14 Aberdeen B3 Glasgow PG4 Glasgow B2 London PL94 London Note: Right outer join includes those rows of second (right) table which are unmatched with rows from first (left) table. Columns from first table are filled with NULLs. Creating Full Outer Joins Example 24: Full Outer Join (list branches and properties in the same city and any unmatched branches and properties). SELECT FROM ON b.*, p.* branch1 b FULL JOIN property_for_rent1 p b.bcity = p.pcity; The result table is: bno bcity pno pcity NULL NULL PA14 Aberdeen B3 Glasgow PG4 Glasgow B4 Bristol NULL NULL B2 London PL94 London Note: Full outer join includes those rows which are unmatched in both tables. Unmatched columns are filled with NULLs. Inserting Data Using INSERT Statement Data is inserted in the table using the INSERT statement. INSERT INTO table_name [ (column_list) ] VALUES (data_value_list); Column_list is optional. If omitted, SQL assumes a list of all columns in their original order. Any columns omitted must be declared as NULL when the table is created, unless DEFAULT is specified when creating the column. Understanding INSERT Statement Rules Data_value_list must match column_list as follows: Cheltenham Courseware Pty. Ltd

22 Microsoft Access Advanced Level Manual - Page 22 Number of items in each list must be the same. Order of items must correspond directly to the position of items in two lists. Data type of each item in data_value_list must be compatible with data type of the corresponding column. Inserting Data using VALUES Example 25: INSERT VALUES (insert a new record into staff table supplying data for all columns). INSERT INTO staff VALUES ( SG16, Alan, Brown, Assistant, B3, 8300); Inserting Data using Defaults Example 26: INSERT using Defaults (insert a new record into staff table supplying data for all mandatory columns). INSERT INTO VALUES staff (sno, fname, lname, position, bno ( SG16, Alan, Brown, Assistant, B3 ); OR INSERT INTO VALUES staff ( SG16, Alan, Brown, Assistant, B3, NULL); Inserting Data using SELECT Second form of INSERT allows multiple rows to be copied from one or more tables to another. INSERT INTO table_name [ (column_list) ] SELECT ; Example 27: INSERT SELECT Assume there is a table staff_prop_count which contains names of staff and the number of properties they manage: staff_prop_count(sno, fname, lname, prop_cnt). (populate staff_prop_count using staff and property_for_rent). INSERT INTO staff_prop_count (SELECT s.sno, fname, lname, COUNT(*) FROM staff s, property_for_rent p WHERE s.sno = p.sno GROUP BY s.sno, fname, lname); Cheltenham Courseware Pty. Ltd

23 Microsoft Access Advanced Level Manual - Page 23 Updating Data Using UPDATE Statement Data is updated in the table using the UPDATE statement. UPDATE table_name SET column_name1 = data_value1 [, column_name2 = data_value2 ] [WHERE search_condition]; SET clause specifies names of one or more columns which are to be updated. WHERE clause is optional. If omitted, named columns are updated for all rows in table. If specified, only those rows which satisfy search_condition are updated. New data_value(s) must be compatible with the data type for the corresponding column. Updating All Rows Example 28: UPDATE All Rows (give all staff a 3% pay increase). UPDATE staff SET salary = salary*1.03; Updating Specific Rows Example 29: UPDATE Specific Rows (give all Managers a 5% pay increase). UPDATE staff SET salary = salary*1.05 WHERE position = Manager ; Note: WHERE clause finds rows which contain data for Managers. Update is applied only to these particular rows. Updating Multiple Columns Example 30: UPDATE Multiple Columns (promote David Ford (sno = SG14 ) to Manager and change his salary to 18000). UPDATE staff SET position = Manager, salary = WHERE sno = SG14 ; Cheltenham Courseware Pty. Ltd

24 Microsoft Access Advanced Level Manual - Page 24 Deleting Data Using DELETE FROM Statement Data is removed from the table using the DELETE FROM statement. DELETE FROM table_name [WHERE search_condition]; Search_condition is optional. If omitted, all rows are deleted from the table. This does not delete the table. If search_condition is specified, only those rows which satisfy the condition are deleted. Deleting Specific Rows Example 31: DELETE Specific Rows (delete all staff which hold a Manager position). DELETE FROM staff WHERE position = Manager ; Deleting All Rows Example 32: DELETE All Rows (delete all records from the staff table). DELETE FROM staff; Writing SQL Queries in Access 2003 Viewing SQL in Access 2003 SQL is the language which Access 2003 uses to program query operations. To view and/or edit SQL statements while creating a Query, switch from Design View to SQL View: To open the SQL View Open a Query in Design View. Cheltenham Courseware Pty. Ltd

25 Microsoft Access Advanced Level Manual - Page 25 From the main menu, choose View > SQL View: To view a sample SQL statement For example, open the sample Northwind.mdb database. Click on the Queries button under the Objects pane of the Database window. Select a query named Employee Sales by Country: Cheltenham Courseware Pty. Ltd

26 Microsoft Access Advanced Level Manual - Page 26 Click on the Design button: This will open the Design View for the selected query: While in Design View, from the main menu, choose View > SQL View. This will open the SQL View: You can edit the SQL statement directly in this window. Cheltenham Courseware Pty. Ltd

27 Microsoft Access Advanced Level Manual - Page 27 Understanding SQL in Access 2003 SQL statements are little different in Access than in the standard SQL. Lets look at the example: SELECT [First Name], [Last Name], Position FROM [Staff Data] WHERE Position = Assistant ; The column names which contain spaces must be enclosed in square brackets [ ]. If the column name does not contain spaces, square brackets are not needed. Writing SQL Specific Queries SQL Specific queries are queries which can only be created using SQL statements. There are three SQL Specific queries Union queries which combine corresponding fields from two or more tables into one field in the query results. Pass-Through queries which send commands directly to ODBC databases. Data Definition queries which create or edit Access tables. To write an SQL Specific query Click on the New button while in the Queries page of the Database window: Cheltenham Courseware Pty. Ltd

28 Microsoft Access Advanced Level Manual - Page 28 In the New Query dialog box, select Design View and click OK: In the Show Table dialog box, click Close without adding any table: From the main menu, choose Query > SQL Specific > then select the type of query you want to create, Union, Pass-Through or Data Definition: Cheltenham Courseware Pty. Ltd

29 Microsoft Access Advanced Level Manual - Page 29 Finding Help on SQL Queries As always, if you need more help, Access 2003 has more information on SQL queries. To perform an online search, from the main menu, choose Help > Microsoft Access Help: OR press the F1 key OR click on the Help [?] toolbar button. In the Access Help task pane, type "SQL Queries" into the Search for field, and click on the green Start Searching button: Cheltenham Courseware Pty. Ltd

30 Microsoft Access Advanced Level Manual - Page 30 In the Search Results task pane, click on the appropriate link to find information on SQL queries: Review Questions How would you: Understand SQL Statements? Understand SQL Conventions? Understand SQL Syntax? Use SELECT Statement? Select All Data? Select Specific Data? Select Conditional Data? Use ORDER BY Statement? Sort Data? Use Aggregate Functions? Calculate Data? Use GROUP BY Statement? Group Data? Create a Subquery with Equality? Create a Subquery with an Aggregate Function? Use ANY and ALL Statements? Understand SQL Joins? Create a Simple Join? Sort a Join? Create an Outer Join? Cheltenham Courseware Pty. Ltd

31 Microsoft Access Advanced Level Manual - Page 31 Create a Left Outer Join? Create a Right Outer Join? Create a Full Outer Join? Use INSERT Statement? Understand INSERT Statement Rules? Insert Data using VALUES? Insert Data using Defaults? Insert Data using SELECT? Use UPDATE Statement? Update All Rows? Update Specific Rows? Update Multiple Columns? Use DELETE FROM Statement? Delete Specific Rows? Delete All Rows? View SQL in Access 2003? Understand SQL in Access 2003? Write SQL Specific Queries? Find Help on SQL Queries? Cheltenham Courseware Pty. Ltd

32 Microsoft Access Advanced Level Manual - Page 32 Working with Macros When you have completed this learning module you will have seen how to: Understand Macros Use the Macro Window Toolbar Create New Macros Run a Macro Step Through a Macro Modify a Macro Add Conditions to Macros Use the Expression Builder to Create Conditions Run Macros with Conditions Attach Macros to a Form Attach Macros to a Report Filter Records Comment on Macros Print Macro Definitions View Macro Definitions Automating Tasks Understanding Macros Macros present a way of programming Access 2003 to perform a variety of tasks and actions. Macros are easy to create - you simply select from the list of predefined actions and their arguments. Each action performs a specific operation. Each action can have arguments, which specify additional information for that action. Macros are best for performing simple tasks, like opening and closing forms, running reports, and displaying custom toolbars. Macros are individual Access objects listed in the Macros page in the Database window: Cheltenham Courseware Pty. Ltd

33 Microsoft Access Advanced Level Manual - Page 33 Once macros are created, you can attach them to an Event property of any object in your database. Note: Access macros differ from macros in Office 2003 and other applications, as Access does not record the keystrokes. There are two cases when you must use macros When assigning specific actions to a key combination to be used globally in the entire database. When assigning startup actions to the database, such as opening a switchboard form at startup. Introducing the Macro Design Toolbar Using the Macro Design Toolbar The Macro Names button adds a Macro Name column to the macro sheet: Cheltenham Courseware Pty. Ltd

34 Microsoft Access Advanced Level Manual - Page 34 OR from the main menu, choose View > Macro Names: Macro Name column is added to the macro sheet: Conditions button adds the Condition column to the macro sheet: OR from the main menu, choose View > Conditions. Condition column is added to the macro sheet: Insert Rows button inserts one or more blank rows in the grid above the selected row: OR from the main menu, choose Insert > Rows. Delete Rows button deletes the selected row or rows: OR from the main menu, choose Edit > Delete Rows. Cheltenham Courseware Pty. Ltd

35 Microsoft Access Advanced Level Manual - Page 35 Run button runs the macro: OR from the main menu, choose Run > Run. Single Step button runs the macro one action at a time, displaying intermediate information: OR from the main menu, choose Run > Single Step. Creating Macros Creating New Macros Whilst in the Macros page of the Database window, click on the New button: The Macro window opens, displaying the blank macro sheet. Under the Action column, you will see the drop-down list which contains a list of predefined actions for you to choose from: Cheltenham Courseware Pty. Ltd

36 Microsoft Access Advanced Level Manual - Page 36 The Comment column contains optional comments used for documenting macros. Once you select an Action, the pane on the bottom area displays the associated Action Arguments: Depending on the selected action, some arguments are required and some are optional. For example, for the Close action, you can select an Object Type, such as Form: Cheltenham Courseware Pty. Ltd

37 Microsoft Access Advanced Level Manual - Page 37 Once the Object Type is selected, you can select an Object Name. Access will list all available Forms in the current database: The last argument is the Save option (required). Here, you can select what type of actions Access should perform at the end: Note: The information pane at the bottom-right area of the Macro window displays information about the part of the macro sheet that is currently active. If you need more information, press the F1 key for help. Close the Macro window and click Yes to save changes for your new macro: Cheltenham Courseware Pty. Ltd

38 Microsoft Access Advanced Level Manual - Page 38 In the Save As dialog box, enter the name in the Macro Name field, then click OK: The new macro is now available in the Macros tab of the Database window: Testing and Debugging Macros Running a Macro Once you have created a macro, you will have to run it and see if it works. You can run the whole macro at once, or you can run step-by-step through the macro. If you get an error while running a macro, make sure you run through the macro step-by-step to find where the error occurs, and fix it. Cheltenham Courseware Pty. Ltd

39 Microsoft Access Advanced Level Manual - Page 39 To run a macro Select the macro name from the Macros page of the Database window. Click Run button: OR double-click the macro name OR right-click the macro name and choose Run from the popup menu: Stepping Through a Macro If you have received an error while running a macro, you will have to step through the macro in order to find the error and fix it. Cheltenham Courseware Pty. Ltd

40 Microsoft Access Advanced Level Manual - Page 40 To use the Single Step method to run a macro Select the macro name from the Macros page of the Database window. Click Design button to open the Macro window: Whilst in the Macro window, click on the Single Step button: Click on the Run button: Cheltenham Courseware Pty. Ltd

41 Microsoft Access Advanced Level Manual - Page 41 This will open the Macro Single Step dialog box: The Step button moves to the next action, if there are more actions in the macro. This is the default option. The Halt button stops macro execution. The Continue button stops the Single Step mode and runs the rest of the macro without stopping. Modifying Macros Modifying a Macro Select the name of the macro you want to modify from the Macros page of the Database window. Click Design button to open the Macro window. Use the Insert Rows toolbar button or the Insert menu command to add actions. Use the Delete Rows toolbar button or the Edit menu command to delete actions. Use the Cut, Copy, and Paste operations to edit a macro. Use the Undo button to reverse recent changes. When you have finished editing the macro, Save it again. Run and test your newly saved macro to make sure it works properly. Conditional Programming in Macros Adding Conditions to Macros By adding conditions to macros, you can specify if and when actions will happen. Cheltenham Courseware Pty. Ltd

42 Microsoft Access Advanced Level Manual - Page 42 Conditions mean that if the condition is true, then the action(s) will be performed. If the condition is not true, the macro will skip to the next action but only if there is one. Macro conditions are added in the Condition column on the macro sheet: By default, the condition only applies to the action on the same row in the macro sheet. If the condition is not met, the next action (i.e. the next row) will be executed. To extend the condition to the next action, you must enter the ellipsis ( ) in the Condition column of the next row: When debugging a macro, you can temporarily disable an action by entering False in the Condition column: Cheltenham Courseware Pty. Ltd

43 Microsoft Access Advanced Level Manual - Page 43 Using the Expression Builder to create Conditions Right-click inside the Condition field where you want to create a condition, and select Build from the popup menu. In the Expression Builder dialog box, create the logical expression (for example if the Total Pages number is greater than 0) and click OK: Cheltenham Courseware Pty. Ltd

44 Microsoft Access Advanced Level Manual - Page 44 The new expression will be displayed in the Condition field: Running Macros with Conditions When running macros with conditions, Access evaluates each condition and does each of the following. If condition is TRUE, Access runs the action on that row first, then runs all following actions that have an ellipsis ( ) in the Condition column. Access then runs any additional actions that have blank conditions until it encounters another condition, comes across a macro name in the Macro Name column, or reaches the end of the macro. If a condition is FALSE, Access ignores the action on that row and any subsequent actions that have an ellipsis ( ) in the Condition column. Access then moves to the next condition, if there is one: Note: The MsgBox action has a condition [CurrentRecord]=0, meaning if no records are returned for the selected letter, display a message. Then Access goes to the next action with an ellipsis ( ) ShowAllRecords that will show all records. Then Access continues to the next action with an ellipsis ( ) SetValue that will press in the All button. Cheltenham Courseware Pty. Ltd

45 Microsoft Access Advanced Level Manual - Page 45 Adding Macros to Forms Attaching Macros to a Form First select the form in the Forms page of the Database window and click on the Design button: To attach the macro to a form event From the main menu, choose Edit > Select Form OR press the Ctrl + R key combination. The Form is selected: Cheltenham Courseware Pty. Ltd

46 Microsoft Access Advanced Level Manual - Page 46 To attach the macro to a section of the form Click the section selector (for example, Detail section): To attach the macro to a control in the form Select the control (for example, the Exit Microsoft Access button): To attach the macro to the selected form property From the main menu, choose View > Properties OR press the F4 key OR right-click on the selection and select Properties from the popup menu Cheltenham Courseware Pty. Ltd

47 Microsoft Access Advanced Level Manual - Page 47 (available for section or control objects only). Click the Event tab to view a list of events that can occur for the selected object. Select the event you want to run the macro (for example, On Exit). Choose the Macro name from the drop-down list of available macros (for example, Close): Save and close the form design. Adding Macros to Reports Attaching Macros to a Report Select the report in the Reports tab of the Database window and click on the Design button: Cheltenham Courseware Pty. Ltd

48 Microsoft Access Advanced Level Manual - Page 48 To attach the macro to a report event From the main menu, choose Edit > Select Report OR press the Ctrl + R key combination. The Report is selected: To attach the macro to a section of the report Click the section selector (for example, Page Header section): To attach the macro to the selected form property From the main menu, choose View > Properties OR press the F4 key Cheltenham Courseware Pty. Ltd

49 Microsoft Access Advanced Level Manual - Page 49 OR right-click on the selection and select Properties from the popup menu (available for the section or control objects only). Click the Event tab to view a list of events that can occur for the selected object. Select the event you want to run the macro (for example, On Format). Choose the Macro name from the drop-down list of available macros (for example, Sales Totals by Amount): Save and close the report design. Filtering Data Filtering Records The Northwind sample database contains a macro that alphabetically filters the records in the Customer Phone List form. Open the Northwind database by selecting Help > Sample Databases > Northwind Sample Database from the main menu. Cheltenham Courseware Pty. Ltd

50 Microsoft Access Advanced Level Manual - Page 50 Click OK if the splash screen is displayed: In the Main Switchboard window, click on the Display Database Window button: In the Database window, click on the Macros tab, then select the Customer Phone List macro and click on the Design button: Cheltenham Courseware Pty. Ltd

51 Microsoft Access Advanced Level Manual - Page 51 This will open the macro sheet: In the Comment column, you can see that this macro is attached to the Customer Phone List form. In order to see how the macro works, we should run it first. In order to run the macro, we have to open the form attached to the macro. Go back to the Database window, click on the Forms tab, and select Customer Phone List: Cheltenham Courseware Pty. Ltd

52 Microsoft Access Advanced Level Manual - Page 52 Double-click on the form name to open it: As you can see, the form has Alphabet buttons that will filter data when pressed. Only the company names that start with a specified letter of the alphabet will be displayed. Cheltenham Courseware Pty. Ltd

53 Microsoft Access Advanced Level Manual - Page 53 Click on the Design button to see the underlined programming for this form: The row of Alphabetic buttons are actually an Option Group control named CompanyNameFilters, which returns a value depending on which button is selected. If you open the Properties for this control, you will see that the macro Customer Phone List.Alpha Button is attached to the After Update event. This means that the macro will run when the user clicks one of the buttons in the option group. Go back to the Customer Phone List macro sheet to see how this is done: The Alpha Buttons macro applies a filter to the list, based upon which button is pressed. For example, if the A button is pressed, the macro will filter for company names that start with Cheltenham Courseware Pty. Ltd

54 Microsoft Access Advanced Level Manual - Page 54 Pressing on the A button will result in this company list: Now go back to the Customer Phone List macro sheet and scroll down to the last rows. In the GoToControl action row, the stated condition is that if the current record count is greater than 0, the records are displayed and the macro stops. The ellipsis ( ) in the StopMacro action row carries over the condition from the row above it: However, if no records are returned by the filter (based on the condition if the current record count equal to 0), the message will be displayed in the MsgBox action. When the user clicks OK to close the message window, all records are displayed on the screen, as the ellipsis ( ) in the ShowAllRecord action row carries over the condition from the row above it. Furthermore, the next action row containing ellipsis ( ) SetValue, will depress the All button in the form: Cheltenham Courseware Pty. Ltd

55 Microsoft Access Advanced Level Manual - Page 55 Documenting Macros Commenting on Macros To make programming and future updates easier, make sure you comment macros using the Comment column in the macro sheet: Printing Macro Definitions In the Macros page of the Database window, select the macro name. From the main menu, choose File > Print OR press the Ctrl + P key combination. In the Print Macro Definition dialog box, select what information you want to print and click OK: Properties include the container, date created, date of last update, owner, and user. Actions and Arguments include all the actions with their conditions, as well as values for all arguments. Permissions by User and Group include user permissions and group permissions. Cheltenham Courseware Pty. Ltd

56 Microsoft Access Advanced Level Manual - Page 56 Viewing Macro Definitions In the Macros page of the Database window, select a macro name. From the main menu, choose File > Print Preview and make the same selections as for the Print option, as covered in the previous section: Review Questions How would you: Understand Macros? Use the Macro Window Toolbar? Create New Macros? Run a Macro? Step Through a Macro? Modify a Macro? Add Conditions to Macros? Use the Expression Builder to Create Conditions? Run Macros with Conditions? Attach Macros to a Form? Attach Macros to a Report? Filter Records? Comment on Macros? Print Macro Definitions? View Macro Definitions? Cheltenham Courseware Pty. Ltd

57 Microsoft Access Advanced Level Manual - Page 57 Programming Access Using Visual Basic When you have completed this learning module you will have seen how to: Use Visual Basic Modules Convert Macros to Visual Basic Code Understand Modules Create Modules Understand Module Declarations Understand Procedures Use Naming Rules Declare Variables Set Variable Scope Declare Constants Use Methods Use Arguments Customise the Visual Basic Editor Window Set the Visual Basic Editor Options Use Microsoft Visual Basic Help Get Visual Basic Syntax Help Using Macros versus Visual Basic In this manual, we will cover only the basics of Visual Basic programming regarding its use in Access If you want to learn more about Visual Basic, refer to one of the numerous manuals and books on this subject. Using Visual Basic Modules In the previous chapter, we have covered the use of Macros. Another way to program Access is writing Visual Basic modules. Certain procedures cannot be created in Macros - you must use Visual Basic to write them. Examples of Visual Basic usages: - Error handling - Repetitive looping - Custom functions - Optimised performance, etc. Converting Macros to Visual Basic Code There are two methods for converting Macros to Visual Basic (VB) code: Converting from the Macros page of the Database window this is used when you want to make VB code available to the whole database. Converting from the Form or Report Design view this is used when you want to store VB code with a form or report. Cheltenham Courseware Pty. Ltd

58 Microsoft Access Advanced Level Manual - Page 58 To convert a Macro from the Database Window Click on the Macros tab in the Database window. Select a macro you want to convert to VB. From the main menu, choose Tools > Macro > Convert Macros to Visual Basic OR from the main menu, choose File > Save As and in the Save As dialog box, select Module under the As filed. Click OK to continue: This will open up the Convert macro: macro_name dialog box: Check the Add error handling to generated functions and Include macro comments options and click Convert. The Convert macros to Visual Basic message box shows the conversion is finished. Click OK. This will create Converted Macro macro_name module, listed under the Modules folder in the Visual Basic Editor window. Click on the module to see the code: Cheltenham Courseware Pty. Ltd

59 Microsoft Access Advanced Level Manual - Page 59 Scroll to the end of the code window to view the whole Visual Basic code: The Function statement represents the global module that is available to the entire database. The DoCmd statement performs macro action in a Visual Basic procedure. Apostrophe ( ) marks the comment line. The newly created module is also listed in the Modules tab of the Database window: Cheltenham Courseware Pty. Ltd

60 Microsoft Access Advanced Level Manual - Page 60 To convert Form s Macro from the Design View Click on the Forms tab in the Database window. Select a form whose macro you want to convert to VB. Click on the Design view button. From the main menu, choose Tools > Macro > Convert Form s Macros to Visual Basic. This will open up the Convert form macros: macro_name dialog box: Uncheck Add error handling to generated functions and check Include macro comments options and click Convert. The Convert macros to Visual Basic message box shows the conversion is finished. Click OK. Click on the Code toolbar button to open the Visual Basic Editor window with the converted macros code: Cheltenham Courseware Pty. Ltd

61 Microsoft Access Advanced Level Manual - Page 61 Scroll to the end of the code window to view the whole Visual Basic code: The Sub statement represents the local code, stored with a form. The DoCmd statement performs macro action in a Visual Basic procedure. The Apostrophe ( ) marks the comment line. To convert Report s Macro from the Design View Click on the Reports tab in the Database window. Select a report whose macro you want to convert to VB. Cheltenham Courseware Pty. Ltd

62 Microsoft Access Advanced Level Manual - Page 62 Click on the Design view button. From the main menu, choose Tools > Macro > Convert Report s Macros to Visual Basic. This will open up the Convert report macros: macro_name dialog box: Uncheck Add error handling to generated functions and check the Include macro comments option and click Convert. The Convert macros to Visual Basic message box shows the conversion is finished. Understanding Visual Basic Concepts Understanding Modules The Visual Basic module consists of declarations and procedures. Modules are used to create event procedures that execute when an event occurs. There are two types of modules: Module objects listed in the Modules page of the Database window. Form and Report modules stored together with a form or report containing procedures and functions associated with a single form or report. Creating Modules Click on the Modules tab in the Database window. Cheltenham Courseware Pty. Ltd

63 Microsoft Access Advanced Level Manual - Page 63 Click on the New button: The new module, named Module1, opens up in the Visual Basic Editor window: Cheltenham Courseware Pty. Ltd

64 Microsoft Access Advanced Level Manual - Page 64 A newly created module has two or more sections: Declarations section Procedure section(s) If you do not see the Option Explicit declaration, choose Tools > Options from the Visual Basic Editor window s main menu. In the Options dialog box, click on the Editor tab and check the Require Variable Declaration option. Click OK to continue: Cheltenham Courseware Pty. Ltd

65 Microsoft Access Advanced Level Manual - Page 65 Understanding Module Declarations Declarations are listed in the first section of a module. They set requirements and defaults on the module-level. There are two default module-level declarations The Option Compare declaration specifies the default comparison method for string data. This declaration requires an argument: - Binary sorts string data based on the internal binary representation of characters. - Text sorts in a case-insensitive text sort order. - Database sorts in the same order as the database. The Option Explicit declaration forces the declaration of variables used in the module. Understanding Procedures Procedures consist of statements and methods. A statement is a complete instruction to Visual basic and consists of keywords, operations, variables, constants, and expressions. There are three types of statements Declaration statements used to name variables, constants or procedures. Cheltenham Courseware Pty. Ltd

66 Microsoft Access Advanced Level Manual - Page 66 Assignment statements used to give a value or an expression to a variable or a constant. Executable statements used to trigger actions or jump to another location in the procedure. There are two types of procedures A sub procedure is a program code that does not return a value. It usually runs as a separate program called by an event in a form or report. Example of a sub procedure: Sub sub_name (parameters) DoCmd.command_name End Sub A function procedure is a program code that returns a value as a result of a calculation or comparison. Example of a function procedure: Function function_name (parameters) As type calculation End Function Using Naming Rules In any programming, writing clear code is one of the most important practices. This helps you and others understand and maintain your code. In Visual Basic, there are several naming rules and practices: The first character must be a letter. The name has a maximum of 255 characters. Avoid the use of special characters and spaces, periods, exclamation marks, etc. Avoid the use of Visual Basic keywords. Avoid the use of same names for multiple variables in same procedures. Add prefixes to names that can indicate what type of item or variable they are: - con used to indicate a constant - int used to indicate an integer variable - dte used to indicate a date variable - str used to indicate a string variable - rst used to indicate a recordset - frm used to indicate a form Declaring Variables Variables are items with unique names containing data that can be changed during procedure execution. Cheltenham Courseware Pty. Ltd

67 Microsoft Access Advanced Level Manual - Page 67 You can specify the data type for each variable, or let Access assign the default Variant type. A Variant type variable can contain string, date, time, Boolean, or numeric values. The Dim statement is used to declare variables: Dim strname As String Dim intage As Integer, dtebirthday As Date, undeclared You can declare several variables in the same statement, separated by commas. In the above example, we have used prefixes to descriptively name the variables in order to include their data type. The last variable has no data type declaration, so the type is Variant. Setting Variable Scope The Scope of a variable indicates the variable availability to procedures. There are three levels of variable scope Procedure level is set when the variable is declared with a Dim statement in the procedure. Private module level is set when the variable is declared with a Private statement in the declarations module section. The variable is available only to procedures in that module. Public module level is set when the variable is declared with a Public statement in the declarations module section. The variable is available to all procedures in the application. Declaring Constants Constants are items with unique names, within which data cannot be changed during procedure execution. A constant data type can be a string or number value, another constant, or an expression. The Const statement is used to declare constants and give them a value: Const conyear As Integer = 1990 Const contitle As String = President You can declare several constants in the same statement separated by commas. In the above example, we have used prefix con to descriptively name the constants instead of their data types. You must assign a constant a value at the time of declaration. Cheltenham Courseware Pty. Ltd

68 Microsoft Access Advanced Level Manual - Page 68 Using Methods Methods are actions that database objects can perform, or procedures that apply to database objects. Access 2003 modules can use nearly 160 methods that apply to different database objects. Some examples of methods are: - Opening or closing a form. - Sounding a beep when a specific event occurs. - Going to a specific field in a form. - Filtering records for a report. - Printing multiple copies of a report, etc. Methods have specific syntax that indicate the object and the action: SetFocus Forms![Customer Phone List]![Company Name].SetFocus In the example above, the method moves the cursor to the Company Name field in the Customer Phone List form. Using Arguments Arguments are used in the sub or function procedure calls. They are optional, depending on the procedure. There are two ways you can list arguments: in a procedure order, or by name. For example, this is the sub procedure with an argument list: Sub GetArguments (strname As String, dtebirthday As Date, intage As Integer) When you run the procedure, you can list the arguments in the same order as the procedure: GetArguments John, #11/12/1967#, 36 Or, you can list the arguments using their names in any order: GetArguments dtebirthday:=#11/12/1967#, intage:=36, strname:= John Using the Visual Basic Editor Window Cheltenham Courseware Pty. Ltd

69 Microsoft Access Advanced Level Manual - Page 69 Customising the Visual Basic Editor Window Once you open the Visual Basic Editor window, you can change its look. From the main menu, choose View > then select the elements you want to see in the editor window: In the Code view, the Object list box displays a list of all controls in the form or report: Cheltenham Courseware Pty. Ltd

70 Microsoft Access Advanced Level Manual - Page 70 In the Code view, the Procedure list box displays a list of all procedures in the module object: Setting the Visual Basic Editor Options Once you open the Visual Basic Editor window, you can change its features. From the main menu, choose Tools > Options. This opens up the Options dialog box: The Code Settings group controls the code editing. Auto Syntax Check option checks for syntax errors as you type the code. Require Variable Declaration option includes the Option Explicit Cheltenham Courseware Pty. Ltd

71 Microsoft Access Advanced Level Manual - Page 71 declaration in new modules. Auto List Members option displays a list of keywords as you type the code. Auto Quick Info option displays syntax when you type a method or procedure name. Auto Data Tips option displays the current value of a variable when you rest your mouse pointer on the name. Auto Indent option indents a line of code to match the previous line. Tab Width option sets the number of characters for TAB key. The Window Settings group controls the editor window behaviours. Drag-and-Drop Text Editing option allows drag-and-drop editing in a module. Default to Full Module view option shows all procedures in the module by default. Procedure Separator option displays a horizontal line between procedures. Click the Editor Format tab to specify the appearance of the different types of text in the editor window: Click the General tab to set Form Grid Settings, Error Trapping and Compile options: Cheltenham Courseware Pty. Ltd

72 Microsoft Access Advanced Level Manual - Page 72 Click the Docking tab to allow docking for editor windows: Getting Help with Visual Basic Using Microsoft Visual Basic Help Open the Visual Basic Editor window. From the main menu, choose Help > Microsoft Visual Basic Help OR press the F1 key OR click on the Microsoft Visual Basic Help [?] button on the toolbar: Cheltenham Courseware Pty. Ltd

73 Microsoft Access Advanced Level Manual - Page 73 If you get the following message, you must install the Microsoft Visual Basic Help first. Click on the Yes button, and follow the installation instructions: The Microsoft Visual Basic Help task pane opens up. Here you can find extensive reference for various Visual Basic topics: Getting Visual Basic Syntax Help While you are editing statements in the Visual Basic Editor window, you can get syntax help from the Edit menu: Cheltenham Courseware Pty. Ltd

74 Microsoft Access Advanced Level Manual - Page 74 OR right-click inside the statement and choose desired help from the popup menu. List Properties/Methods lists all properties and methods available for selected statement: List Constants lists all intrinsic constants that are valid for a specific item in the argument list. Quick Info displays the complete syntax with the current item highlighted in bold: Parameter Info displays the complete syntax with the current parameter highlighted in bold: Cheltenham Courseware Pty. Ltd

75 Microsoft Access Advanced Level Manual - Page 75 Complete Word automatically completes the word when you begin typing. Review Questions How would you: Use Visual Basic Modules? Convert Macros to Visual Basic Code? Understand Modules? Create Modules? Understand Module Declarations? Understand Procedures? Use Naming Rules? Declare Variables? Set Variable Scope? Declare Constants? Use Methods? Use Arguments? Customise the Visual Basic Editor Window? Set the Visual Basic Editor Options? Use Microsoft Visual Basic Help? Get Visual Basic Syntax Help? Cheltenham Courseware Pty. Ltd

76 Microsoft Access Advanced Level Manual - Page 76 Using Data Access Pages When you have completed this learning module you will have seen how to: Use Data Access Pages Create pages using the AutoPage Create pages using the Page Wizard Create pages using an Existing HTML Document Create pages using the Design View Choose a Theme Add Text Add Controls Format Text and Labels Align Content Size Content Add Images Add Backgrounds Sort Data Summarise Data Add a New Record Delete a Record Customise the Navigation Bar Protect Fields Creating Data Access Pages Using Data Access Pages Data access pages allow you to connect Access databases to the Internet. With data access pages you can share database data and allow viewing and/or editing of dynamic data at your website. To display data access pages, the user must use Internet Explorer 5.5 or later and have a Microsoft Office 2003 licence. There are several ways to create data access pages: AutoPage Page Wizard Existing HTML Document Design View Creating pages using the AutoPage The quickest way to create data access pages is to use the AutoPage feature. AutoPage automatically adds all the fields from selected table or query. Data is displayed in a form-like style. Cheltenham Courseware Pty. Ltd

77 Microsoft Access Advanced Level Manual - Page 77 To create a data access page using AutoPage In the Database window, click on the Pages tab, then click on the New button: In the New Data Access Page dialog box, select AutoPage: Columnar: Choose the table or query where the object s data comes from by selecting it from the drop-down list: Cheltenham Courseware Pty. Ltd

78 Microsoft Access Advanced Level Manual - Page 78 Click OK to create a data access page: Cheltenham Courseware Pty. Ltd

79 Microsoft Access Advanced Level Manual - Page 79 At the bottom of the data access page, you will notice the Record Navigation Bar. From the main menu, choose File > Save to open the Save As Data Access Page dialog box: Select the location and name the data access page and click Save. You may be asked whether you want to set the current folder as the default location for data access pages. Click Yes to accept, or No to decline. You may also see a warning dialog box. Click OK: Cheltenham Courseware Pty. Ltd

80 Microsoft Access Advanced Level Manual - Page 80 The new data access page is listed in the Pages section of Database window: To view a data access page in your browser Select the data access page in the Pages page of the Database window. From the main menu, choose File > Web Page Preview. Cheltenham Courseware Pty. Ltd

81 Microsoft Access Advanced Level Manual - Page 81 The data access page opens in the browser window: Creating pages using the Page Wizard Another way to create data access pages is using the Page Wizard. The Page Wizard allows additional options for creating a data access page. For example, you can choose fields from more than one table or query, grouping, selecting multiple fields for sorting, etc. Cheltenham Courseware Pty. Ltd

82 Microsoft Access Advanced Level Manual - Page 82 To create a data access page using the Page Wizard In the Database window, click on the Pages tab, and then click on the New button. In the New Data Access Page dialog box, select Page Wizard and click OK to continue: OR from the Pages page of Database window, double-click on Create data access page by using wizard: This will open the Page Wizard dialog box. Select the table or query from the Tables/Queries drop-down list: Cheltenham Courseware Pty. Ltd

83 Microsoft Access Advanced Level Manual - Page 83 Under the Available Fields list, select one field and click the [>] button to transfer it to the Selected Fields: If you want to select all the fields, click on the [>>] button: Cheltenham Courseware Pty. Ltd

84 Microsoft Access Advanced Level Manual - Page 84 If you want to remove a field from the Selected Fields list, select the field and click on the [<] button. Repeat the same steps for other tables and/or queries from which you want to add fields to the data access page. Once you have finished selecting fields, click Next button to continue. To group data in the data access pages This page of the wizard allows you to add grouping levels. Select the field you want to group by, and click on the [>] button: A new grouping level will be added to the data access page. If you want to choose the grouping interval, click on the Grouping Options button: Cheltenham Courseware Pty. Ltd

85 Microsoft Access Advanced Level Manual - Page 85 The Grouping Intervals dialog box allows you to choose how you want to group the group-level field(s). Click OK to accept change or Cancel to close the dialog box: Back in the Page Wizard, click Next to continue. To sort data in the data access pages This page of the wizard allows you to sort records. Select the sorting field(s) from the drop-down lists: Cheltenham Courseware Pty. Ltd

86 Microsoft Access Advanced Level Manual - Page 86 The default sorting order is ascending. If you want to change the sorting order, click the Ascending button to change it into Descending: Once you have selected all of the sorting fields, click on the Next button to continue. The last page of the wizard allows you to add a title to the page and set other options: Cheltenham Courseware Pty. Ltd

87 Microsoft Access Advanced Level Manual - Page 87 Open the page option takes you directly to the Page view. Modify the page s design option takes you directly to the Design view. Do you want to apply a theme to your page option allows you to add predefined styles to the data access page. Display Help on working with the page option gives you help while working on the page design. Click Finish. Depending on what you have selected, the page will be opened in either the Page view or the Design view. This is a sample of the page in the Design view: Cheltenham Courseware Pty. Ltd

88 Microsoft Access Advanced Level Manual - Page 88 Creating pages using an Existing HTML Document If you already have an HTML document that contains layout, graphics, and text that you want to use in your data access pages, you can use the following procedure to create a data access page. To create a data access page using an Existing Web page In the Database window, click on the Pages tab, and then click on the New button. In the New Data Access Page select Existing Web page and click OK to continue: Cheltenham Courseware Pty. Ltd

89 Microsoft Access Advanced Level Manual - Page 89 OR from the Pages page of the Database window, double-click on Edit Web page that already exists: This will open the Locate Web Page dialog box where you can select the already existing web page. Click Open to continue: Cheltenham Courseware Pty. Ltd

90 Microsoft Access Advanced Level Manual - Page 90 This will open the web page in the Design view: Creating pages using the Design View If you already have an HTML document that contains layout, graphics and text you want to use in your data access pages, you can use the following procedure to create a data access page. To create a data access page using an Existing Web page In the Database window, click on the Pages tab, and then click on the New button. In the New Data Access Page select Design View and click OK to continue: Cheltenham Courseware Pty. Ltd

91 Microsoft Access Advanced Level Manual - Page 91 OR from the Pages page of the Database window, double-click on Create data access page in Design view. This will open the blank page in Design view. Simply drag and drop fields from the Field List window to the page grid and use the Toolbox to add controls to the data access page: Note: If the Field List pane is not automatically displayed when opening the page, from the main menu, select View > Field List. Modifying Data Access Pages Choosing a Theme In the Database window, click on the Pages tab. Cheltenham Courseware Pty. Ltd

92 Microsoft Access Advanced Level Manual - Page 92 Select the data access page you want to modify and click the Design button: Once the page is opened in Design view, from the main menu, choose Format > Theme. This will open the Theme dialog box: Cheltenham Courseware Pty. Ltd

93 Microsoft Access Advanced Level Manual - Page 93 Under the Choose a Theme list, select the theme you want, and you will see an example in the right pane: Note: If the theme you selected is not installed, the Install button is displayed on the right pane. Click on the Install button to install the selected theme from the Office 2003 CD. Vivid Colors option displays the text links and button colours with a brighter colour scheme. Active Graphics option refers to Animated GIF files. Background Image option activates or deactivates the background image. Set Default button sets the current theme as the default theme for all new data access pages. Click OK to apply the theme. Adding Text You can add text to the page areas above or below the grid section header. Simply position the insertion point on the page and type the text: Cheltenham Courseware Pty. Ltd

94 Microsoft Access Advanced Level Manual - Page 94 The Grid section is the area generally used for data-related text and controls, as the absolute positioning of the grid allows you to place fields in a structured layout. Adding Controls Controls are objects that can be placed on data access pages that display data, perform actions, or can be used for visual display. The Toolbox contains controls that you can add to the page design: Click on a Button in the Toolbox and then click on the page to add this control to the page: ICON CONTROL DESCRIPTION Label Used to display text on a page. Labels are useful for descriptive or instructional text. Labels are not associated with a data source. Bound Span Used to display data from a field in the database or result of an expression. Text Box Used to input data on a page. Text boxes are unbound to accept input or display a calculation. Scrolling Text Used to add a marquee for displaying scrolling text. Cheltenham Courseware Pty. Ltd

95 Microsoft Access Advanced Level Manual - Page 95 Option Group Option Button Check Box Drop-down List List Box Command Button Expand Record Navigation Office PivotTable Office Chart Office Spreadsheet Hyperlink Hyperlink Image Movie Image Line Rectangle Used to select a limited list of choices. Sometimes interchangeable with List Boxes when selecting from only a few pre-defined options. Used to set Yes/No values from an underlying query or table. Used to set Yes/No values from an underlying query or table. Used to display a pre-determined list of values. Drop-down Lists are useful when limiting selection choices or when enforcing data integrity. Used to display a pre-determined list of values. List boxes are useful when limiting selection choices or when enforcing data integrity. Used to execute a pre-defined set of actions in a macro or event procedure written in visual basic. Used to add a button for expanding and collapsing grouped records. Used to add a Record Navigation bar that contains buttons for display, edit, delete, sort, and filter. Used to add a PivotTable. PivotTables can be associated with a data source. Used to add a Chart. Used for analysing data. Used to add Excel Spreadsheets for adding data or importing a spreadsheet from Excel. Used to insert a link to a file or a web page. Used to insert an image with a link to a file or a web page. Used to insert a movie on a page. Used to insert an image on a page. Used when displaying horizontal lines. Useful when displaying breaks between fields within a page. Used when displaying rectangle shapes. Useful when displaying sections within a page. Formatting Text and Labels In the page Design view, select the text or label(s) you want to format. From the Formatting (Page) toolbar, select any formatting tool and apply appropriate formatting: Style, Font, Font Size, Bold, Italic, Underline, Align Left, Center, Align Right, Decrease Indent, Increase Indent, Numbering, Bullets, Fill/Back Color, Font/Fore Color, Line/Border Color, Line/Border Width, and Special Effect: Aligning Content In the page Design view, select the content you want to align. Cheltenham Courseware Pty. Ltd

96 Microsoft Access Advanced Level Manual - Page 96 From the main menu, choose Format > Align > alignment option: OR right-click on the selection and select Align > alignment option from the popup menu: Sizing Content In the page Design view, select the content you want to resize. From the main menu, choose Format > Size > sizing option: Cheltenham Courseware Pty. Ltd

97 Microsoft Access Advanced Level Manual - Page 97 OR right-click on the selection and select Size > sizing option from the popup menu: Adding Images From the Toolbox, click on the Image button. Place the Image control on the page: This will open the Insert Picture dialog box. Select the image file you want to place and click Insert. To change various image properties, right-click on the image and select Element Properties from the popup menu. Under the Format tab, you can modify image border properties, height, width, margins, etc: Cheltenham Courseware Pty. Ltd

98 Microsoft Access Advanced Level Manual - Page 98 Adding Backgrounds Data access page background can be displayed with flat colour or a tiled image. To add a Background Colour From the main menu, choose Format > Background > Color > Transparent (default) or any other colour: To add a Background Picture From the main menu, choose Format > Background > Picture. This will open the Insert Picture dialog box. Locate your background image and click Insert. The picture will automatically fill in the background in a tiled style. Sorting Data in Data Access Pages Sorting Data In the page Design view, select the group section bar. Right-click the selection and choose Group Level Properties from the popup menu. In the properties dialog box, enter the name of the field you want the records to be sorted by in the DefaultSort property box: Cheltenham Courseware Pty. Ltd

99 Microsoft Access Advanced Level Manual - Page 99 If you cannot see the whole text in the property box, right-click on the box and choose Zoom from the popup menu to zoom it up: As usual, if the field name includes a space, make sure to enclose the name with square brackets [ ]. By default, the records are sorted in ascending order. If you want to switch to descending order, enter a space after the field name and then type DESC: Summarising Data in Data Access Pages Summarising Data The AutoSum feature in the data access page Design view allows you to add calculated summaries quickly to a page. In the page Design view, select the bound span control you want to summarise: Cheltenham Courseware Pty. Ltd

100 Microsoft Access Advanced Level Manual - Page 100 Click on the AutoSum tool from the toolbar and choose from the list: Save the page. From the main menu, choose File > Web Page Preview to see the summary result: Cheltenham Courseware Pty. Ltd

101 Microsoft Access Advanced Level Manual - Page 101 Editing Data in Data Access Pages In data access pages, much the same as in the forms, you can use the Record Navigation Bar to add, edit and delete records. Adding a New Record From the main menu, choose File > Web Page Preview. Notice the Record Navigation Bar at the bottom of the page: To add a new record From the Record Navigation Bar, click the New record button: Type the data in the first field. Press the TAB key to move to the next field. Click on the Save button to save the record: Or click on the Undo button to undo the changes: Deleting a Record From the main menu, choose File > Web Page Preview. Use the Next and Previous buttons on the Record Navigation Bar to locate the record you want to remove. Click on the Delete button to remove the record: Cheltenham Courseware Pty. Ltd

102 Microsoft Access Advanced Level Manual - Page 102 If the data access page does not display the changes, refresh the browser window by pressing the F5 key. Protecting Data in Data Access Pages Customising Navigation Bar The easiest way to protect the data in data access pages is to limit the Record Navigation Bar functionality. In the page Design view, select the Navigation control: Right-click on selection and choose Navigation Buttons from the popup menu: Uncheck any button you want to remove from the Record Navigation Bar. For example, uncheck the New button to disable adding new records: If you want to add the control back to the Navigation bar, check the button again. Cheltenham Courseware Pty. Ltd

103 Microsoft Access Advanced Level Manual - Page 103 Protecting Fields If you want to protect only certain fields from editing, you can change their properties. In the page Design view, select the field you want to protect and open its properties: In the properties dialog box, click on the Other tab. Under the ReadOnly property box, select True to protect the field from editing. Save the page. Review Questions How would you: Use Data Access Pages? Create pages using the AutoPage? Create pages using the Page Wizard? Create pages using an Existing HTML Document? Create a page using the Design View? Choose a Theme? Add Text? Add Controls? Format Text and Labels? Align and Size Content? Add Images and Backgrounds? Sort Data? Summarise Data? Add a New Record? Delete a Record? Customise the Navigation Bar? Protect Fields? Cheltenham Courseware Pty. Ltd

104 Microsoft Access Advanced Level Manual - Page 104 Converting Access Databases When you have completed this learning module you will have seen how to: Convert Databases Convert Database Objects Enable Databases Share Databases across various Access versions Convert an Access 2003 database to an Access 97 database Convert an Access 2003 database to an Access 2000 database Converting Databases to Access 2003 In Microsoft Access, incompatibility exists between different versions of Access. Therefore, you will need to convert your database(s) to Access 2003 in order to work on them. You can convert databases created with Access 2.0 or later to Access Note: You do not need to convert 2002 databases in order to work on them in Access 2003, as they both use the same file format. Converting Databases Before any conversion, you should first create a backup copy of your Access database. If opened, close the database you want to convert. If the database is used in a multiple-user environment, make sure that all users have closed the database. In an empty Access 2003 window, choose Tools > Database Utilities > Convert Database > To Access File Format from the main menu. In the Database to Convert From dialog box, select the database to be converted to Access 2003, then click on the Convert button: Cheltenham Courseware Pty. Ltd

105 Microsoft Access Advanced Level Manual - Page 105 In the Convert Database Into dialog box, enter the database name in the File name field, and then click on the Save button: You will see the warning dialog box. Click on the OK button to proceed: Cheltenham Courseware Pty. Ltd

106 Microsoft Access Advanced Level Manual - Page 106 Note: If your Access database has linked tables, make sure these tables remain in the original folder, so that the converted database can find them. If Access cannot find linked databases, the converted database will not work properly. Linked tables are not converted automatically; so you must convert them manually. Converting Database Objects If you do not want all of the objects in the older-version database to be converted to Access 2003, you can convert only specific objects: Tables, Queries, Forms, Reports, Pages, Macros, and Modules. To convert Database Objects to Access 2003 Create a new Access 2003 database, or open an already existing one. From the main menu, choose File > Get External Data > Import. In the Import dialog box, select the older-version database and click on the Import button: In the Import Objects dialog box, select the object(s) and click on the OK button: Cheltenham Courseware Pty. Ltd

107 Microsoft Access Advanced Level Manual - Page 107 Enabling Databases In some cases, you might want to open an older-version Access database in Access 2003 without converting it first. This may be necessary if some of the database users do not have Access By enabling a database, you can still add, modify and delete records, but you cannot modify any existing objects or add new objects using Access To enable a Database From the main menu, choose File > Open. Select an older-version Access database and click Open. In the Convert/Open Database dialog box, select the Open Database option and click OK: Cheltenham Courseware Pty. Ltd

108 Microsoft Access Advanced Level Manual - Page 108 Note: You cannot import or link an Access 2003 table into an enabled database. Sharing Databases across various Access versions You can also use a one-file database with several versions of Access by creating a front-end / back-end database out of a one-file database. The oldest-version database file is the back-end containing all data. The Access 2003 database is the front-end containing all converted objects. To create a one-file Access database Convert the oldest-version database to Access Open the converted database and choose Tools > Database Utilities > Database Splitter from the main menu,. In the Database Splitter dialog box, click on the Split Database button: In the Create Back-end Database dialog box, the File name will be automatically named with suffix _be. Keep that name and click on the Split button: Cheltenham Courseware Pty. Ltd

109 Microsoft Access Advanced Level Manual - Page 109 Once you have split the database into front-end and back-end, delete the back-end database. From the main menu, choose Tools > Database Utilities > Linked Table Manager. Link the new Access 2003 front-end to the tables in the older-version (backend) database. Click the Select All button, and then OK to link all tables: Converting from Access 2003 to Access 97 Converting an Access 2003 database to an Access 97 database When converting an Access 2003 database to an Access 97 database, you will lose any features and functionalities specific to the Access 2003 version. Cheltenham Courseware Pty. Ltd

110 Microsoft Access Advanced Level Manual - Page 110 To convert an Access 2003 to an Access 97 database Before any conversion, you should first create a backup copy of your Access database. If the database is used in a multiple-user environment, make sure that all users have closed the database. Open the Access 2003 database. If the database has password protection for the code, open the Visual Basic Editor first. From the main menu, choose Tools > Macro > Visual Basic Editor OR press the Alt + F11 key combination. In the Visual Basic Editor, choose Tools > Database_name Properties from the main menu: In the Project Properties dialog box, select the Protection tab and enter the password in the Password field, then click OK: Cheltenham Courseware Pty. Ltd

111 Microsoft Access Advanced Level Manual - Page 111 Close the Visual Basic Editor to return to the Access window. From the main menu, choose Tools > Database Utilities > Convert Database > To Access 97 File Format. In the Convert Database Into dialog box, enter the database name in the File name field, and then click on the Save button. Converting from Access 2003 to Access 2000 Converting an Access 2003 database to an Access 2000 database When converting an Access 2003 database to an Access 2000 database, you will lose any features and functionalities specific to the Access 2003 version. To convert an Access 2003 to an Access 2000 database Before any conversion, the first step is to create a backup copy of your Access database. If the database is used in a multiple-user environment, make sure that all users have closed the database. Open the Access 2003 database. If the database has password protection for the code, enter the password following the same steps used in the Access 2003 to Access 97 conversion, as explained in the previous section. From the main menu, choose Tools > Database Utilities > Convert Database > To Access 2000 File Format. In the Convert Database Into dialog box, enter the database name in the File name field, and then click the Save button. Review Questions How would you: Convert Databases? Convert Database Objects? Enable Databases? Share Databases across various Access versions? Convert an Access 2003 database to an Access 97 database? Convert an Access 2003 database to an Access 2000 database? Cheltenham Courseware Pty. Ltd

112 Microsoft Access Advanced Level Manual - Page 112 Customising Access 2003 When you have completed this learning module you will have seen how to: Set Access 2003 Options Set View Options Set General Options Set Edit/Find Options Set Keyboard Options Set Datasheet Options Set Forms/Reports Options Set Pages Options Set Advanced Options Set International Options Set Error Checking Options Set Spelling Options Set Tables/Queries Options Set AutoCorrect Options Exclude AutoCorrect Rules Remove AutoCorrect Rules Add Replace AutoCorrect Rules Remove Replace AutoCorrect Rules Open the Customize Dialog Box Customise Toolbars Create Custom Toolbars Remove Toolbars Customise Commands Add Buttons to Toolbars Remove Buttons from Toolbars Customise Options Configuring Access 2003 Options Setting Access 2003 Options Access 2003 allows you to customise the workplace by configuring many available options. To access the options, choose Tools > Options from the main menu. In the Options dialog box, you can find more information on each option by clicking on the Help [?] button first: Cheltenham Courseware Pty. Ltd

113 Microsoft Access Advanced Level Manual - Page 113 The cursor will change to include the question mark,?. Simply click on the option name or option selection item (checkbox, radio button, drop-down list, etc.): Cheltenham Courseware Pty. Ltd

114 Microsoft Access Advanced Level Manual - Page 114 Now you can read the information for the selected option: If you have made any changes to the current tab options, you can apply those changes by clicking on the Apply button. Then you can click on another tab to view/change more options. Otherwise, you can click on the OK button to apply changes and close the Options dialog box. Setting View Options From the main menu, choose Tools > Options. Cheltenham Courseware Pty. Ltd

115 Microsoft Access Advanced Level Manual - Page 115 From the Options dialog box, click on the View tab: The Show group allows you to specify what features you will see when you startup Access 2003: Status bar option shows or hides the status bar at the bottom of the screen. Startup Task Pane option shows or hides the Access side pane. New object shortcuts option shows or hides shortcuts in the Database window that you can use to start a new database object. For example, in the Tables page, the shortcut named Create table in Design view will create a table in the Design view. Hidden objects option shows or hides objects in the Database window that have the Hidden property. If shown, objects will appear as dimmed icons. System objects option shows or hides system tables as dimmed icons. Windows in Taskbar option shows a button on the Windows taskbar for every open database object or window. You must have Internet Explorer Active Desktop feature installed for this option to work. The Show in Macro Design group allows you to change what you see whilst working with macros: Names column option displays the Macro Name column in a macro sheet. Conditions column option displays the Condition column in a macro sheet. The Click options in database window group controls how you work in the Database window: Single-click open option opens an object with single mouse click. Cheltenham Courseware Pty. Ltd

116 Microsoft Access Advanced Level Manual - Page 116 Double-click open option opens an object with a double mouse click. This is the default setting. Setting General Options From the main menu, choose Tools > Options. From the Options dialog box, click on the General tab: The Print margins group allows you to change the margins compatible with your printer and paper size: Left margin, Right margin, Top margin, and Bottom margin. Recently used file list option specifies how many files are displayed when you choose File from the main menu, or when the opening task pane appears. Provide feedback with sound option activates sound alerts. Compact on Close option automatically compacts and repairs the database upon closing. Remove personal information from this file properties on save option removes your name, company name, or any other personal information. Default database folder option specifies the default folder where you will save new databases. The Use four-digit year formatting group allows you to apply the default format to This database or All databases. Cheltenham Courseware Pty. Ltd

117 Microsoft Access Advanced Level Manual - Page 117 The Name AutoCorrect group allows you to correct any problems that occur when you make changes in an object: Track name AutoCorrect info option stores the information it needs to correct naming errors. Perform name AutoCorrect option repairs naming errors as they occur. Log name AutoCorrect changes option generates a log named AutoCorrect Log that contains the changes. New database sort order option in Access 2003 now allows you to choose from a list of 33 languages that change the default alphabetic sort order for new databases. The Web Options button opens the dialog box where you can change the default Appearance for both the Hyperlink color and the Followed hyperlink color. You can also specify if you want to Underline hyperlinks: Setting Edit/Find Options From the main menu, choose Tools > Options. Cheltenham Courseware Pty. Ltd

118 Microsoft Access Advanced Level Manual - Page 118 From the Options dialog box, click on the Edit/Find tab: The Default find/replace behavior group specifies the extent of the search: Fast search option searches the current field only and matches the entire field. General search option searches all the fields and matches any part of the field. Start of field search option searches the current field and matches only the beginning characters in the field. The Confirm group displays the message requiring confirmation from the user: Record changes option requires confirmation when a record changes. Document deletions option requires confirmation when you delete a database object. Action queries option requires confirmation when you run an action query. The Filter by form defaults for [current database] Show list of values in group allows you to limit or expand the size of the value list displayed in the Filter By Form window: Local indexed fields option limits the value list to the indexed fields in the current database. Local nonindexed fields option includes the non-indexed fields in the current database. ODBC fields option includes fields in a linked table in an external source. Cheltenham Courseware Pty. Ltd

119 Microsoft Access Advanced Level Manual - Page 119 Don t display lists where more than this number of records is read option sets the maximum number of records to be used to generate the list of unique values for the field. Setting Keyboard Options From the main menu, choose Tools > Options. From the Options dialog box, click on the Keyboard tab: The Move after enter group controls what happens when you press the RETURN button: Don t move option keeps the insertion point in the current field. Next field option moves the insertion point to the next field. Next record option moves the insertion point to the next record in the table or form. The Arrow key behavior group controls what happens when you press the RIGHT ARROW and LEFT ARROW keys: Next field option moves the insertion point to the next field when you press the RIGHT ARROW key or previous field when you press the LEFT ARROW key. Next character option moves the insertion point to the next character when you press the RIGHT ARROW key or to the previous character when you press the LEFT ARROW key. Cheltenham Courseware Pty. Ltd

120 Microsoft Access Advanced Level Manual - Page 120 The Behavior entering field group controls what happens when the insertion point enters the field: Select entire field option selects all of the characters in the field. Go to start of field option moves the insertion point in front of the first character in the field without selecting any characters. Go to end of field option moves the insertion point to the end of the field after the last character without selecting any characters. Cursor stops at first/last field option locks the inserting point within the current record and stops the RIGHT ARROW and LEFT ARROW keys from moving the insertion point. Datasheet IME Control option sets the East Asian IME Mode set to "No Control" when entering data into a table datasheet. (Note: The IME Mode applies to all East Asian languages, and allows you to set the properties that control the behavior of a field in a table, or a control in a form.) Setting Datasheet Options From the main menu, choose Tools > Options. From the Options dialog box, click on the Datasheet tab: The Default colors group allows you to change the colours of the following: Font option specifies the font colour. Default setting is Black. Background option specifies the background colour. Default setting is White. Gridlines option specifies the gridlines colour. Default setting is Silver. Cheltenham Courseware Pty. Ltd

121 Microsoft Access Advanced Level Manual - Page 121 The Default font group allows you to change the following: Font option specifies font name. Default setting is Arial. Weight option specifies font weight from Thin to Heavy. Default setting is Normal. Size option specifies the font size from 8 to 72 points. Default setting is 10. Underline option sets font style to underline. Italic option sets font style to italic. The Default gridlines showing group allows you to show or hide the following: Horizontal option shows or hides the horizontal gridlines in the datasheet. Vertical option shows or hides the vertical gridlines in the datasheet. Default column width option specifies the width of the columns in a new datasheet. The Default cell effect group specifies the cell effect from Flat, Raised or Sunken. Show animations option shows movement in the datasheet. Show Smart Tags on Datasheets option - a new Access 2003 feature - shows a Smart Tag Action button when moving to a control with an attached Smart Tag. Setting Forms/Reports Options From the main menu, choose Tools > Options. From the Options dialog box, click on the Forms/Reports tab: Cheltenham Courseware Pty. Ltd

122 Microsoft Access Advanced Level Manual - Page 122 The Selection behavior group relates to the results of dragging a rectangle in the design view to select controls. Partially enclosed option selects all controls with any part within the drawn rectangle. Fully enclosed option selects only controls fully within the drawn rectangle. Form template option specifies an existing form template for new designs. Report template option specifies an existing report template for new designs. Always use event procedures option takes you directly to the VB Editor window when you click the Build button in the property sheet. Show Smart Tags on Forms option - a new Access 2003 feature - shows a Smart Tag Action button when moving to a control with an attached Smart Tag. Use Windows Themed Controls on Forms option - a new Access 2003 feature - applies the Windows display theme that is currently set to Access forms. Setting Pages Options From the main menu, choose Tools > Options. From the Options dialog box, click on the Pages tab: The Default Designer Properties group controls the sections design: Section Indent option specifies the default indent for each section. Alternate Row Color option specifies the colour to display in alternate rows of the group header and footer sections. Cheltenham Courseware Pty. Ltd

123 Microsoft Access Advanced Level Manual - Page 123 Caption Section Style option specifies the default style for the caption section. Footer Section Style option specifies the default style for the footer section. The Default Database/Project Properties group controls the properties: Use Default Page Folder option specifies the default page folder. If checked, enter the folder to use as a default page folder. Use Default Connection File option specifies the default connection file. If checked, enter the ODC or Microsoft Data link to use as a default connection file. Setting Advanced Options From the main menu, choose Tools > Options. From the Options dialog box, click on the Advanced tab: The DDE operations group controls how the database interacts with other applications: Ignore DDE requests option ignores Dynamic Data Exchange (DDE) requests from external sources. Enable DDE refresh option allows DDE links. Command-line arguments option specifies values you want the Command function to return. OLE/DDE timeout (sec) option specifies the time-period after which Access will re-attempt to perform OLE or DDE operations. Cheltenham Courseware Pty. Ltd

124 Microsoft Access Advanced Level Manual - Page 124 Refresh interval (sec) option specifies the time-period for updating DDE links if Enable DDE refresh option is checked. Enter a value between 1 and 32,766. Number of update retries option specifies the number of times Access tries to save a changed record locked by another user. Enter a value between 0 and 10. ODBC refresh interval (sec) option specifies the time-period after which Access refreshes records you are accessing through ODBC connection. Enter a value between 1 and 32,766. Update retry interval (msec) option specifies the time-period after which Access tries to save a changed record locked by another user. Enter a value between 0 and Default File Format option - enhanced in Access allows you to choose between Access 2000 and Access as a default file format for new databases. The Default open mode group allows you to choose how you work with the database on the network: Shared option allows others to open the database at the same time you have it opened. Exclusive option gives you sole access to the database. The Default record locking group allows you to choose how the database behaves while shared on the network: No locks option does not lock records while they are being edited. All records option locks records in a form or datasheet as long as the form or datasheet is open. Edited record option locks only the record currently being edited. Open databases using record-level locking option locks only one row or record instead of locking an entire page that may have several records. Setting International Options From the main menu, choose Tools > Options. From the Options dialog box, click on the International tab: Cheltenham Courseware Pty. Ltd

125 Microsoft Access Advanced Level Manual - Page 125 The Default direction group allows you to choose from two directions of the text: Left-to-right option starts entering data in the left-most column and places the next data in the column to the right, etc. Right-to-left direction option starts entering data in the right-most column and places the next data in the column to the left, etc. The General alignment group gives you a choice between two modes: Interface mode option sets General alignment consistent with the user interface language. For example, if the direction is left-to-right, the text is left-aligned. Text mode option sets General alignment according to the direction of the first language-specific characters it encounters. The Cursor movement group controls the cursor moves within bidirectional text that has various languages in the same sentence: Logical option moves cursor within bidirectional text according to the direction of the language it is encountering. For example, for English words the insertion point moves left-to-right, for Arabic words the insertion point moves right-to-left. Visual option moves cursor within bidirectional text by moving to the next adjacent character. Use Hijri Calendar option to change the setting to the Middle Eastern calendar. Cheltenham Courseware Pty. Ltd

126 Microsoft Access Advanced Level Manual - Page 126 Setting Error Checking Options The Automatic Error Checking feature is new to Access Its function is simple - to flag errors in report and form designs, and offer suggestions for remedying them. From the main menu, choose Tools > Options. From the Options dialog box, click on the Error Checking tab: The Settings group allows you to activate error checking in Access, as well as the manner in which error messages are displayed. Enable error checking option enables automatic error checking when checked. Error indicator color option allows you to choose the colour of the error indicator, which will appear in the upper-left comer of the error-causing control. The Form/Report Design Rules group allows you to set specific guidelines that dictate how a form or report can or cannot be designed. These include: Unassociated label and control option specifies that you cannot select a label and a control that are not associated with one another. New associated labels option specifies that you cannot add a label to a form or report that is not associated with another control. Keyboard shortcut errors option specifies that you cannot select a control that demonstrates an invalid shortcut key. Cheltenham Courseware Pty. Ltd

127 Microsoft Access Advanced Level Manual - Page 127 Invalid control properties option specifies that you cannot select a control with invalid property values. Common report errors option specifies that you cannot have a report with invalid sorting and grouping definitions, and that the report cannot exceed the paper width. Setting Spelling Options From the main menu, choose Tools > Options. From the Options dialog box, click on the Spelling tab: Dictionary Language option specifies the language. English (U.S.) is default. Add words to option specifies the dictionary file to which to add words. Suggest from main dictionary only option tries to suggest corrections only from the main dictionary. If you want the spell check to use the custom dictionary as well, uncheck this option. Ignore words in UPPERCASE option ignores uppercase words whilst spellchecking. Ignore words with numbers option ignores words with numbers whilst spellchecking. Ignore Internet and file addresses option ignores internet or file addresses whilst spellchecking. Cheltenham Courseware Pty. Ltd

128 Microsoft Access Advanced Level Manual - Page 128 The Language-specific group options are specific and apply to different languages. AutoCorrect Options will be discussed later in this manual. Setting Tables/Queries Options From the main menu, choose Tools > Options. From the Options dialog box, click on the Tables/Queries tab: The Table design area includes: The Default field sizes group specifies the size for the Text data type fields, and the size for the Number data type fields. Default field type option sets the default data type. AutoIndex on Import/Create option sets automatic indexing for all fields that start or end with the characters typed in this option box. The Show Property Update Options buttons allows you the discretion of propagating property changes made in a table/query to controls that are bound to that particular field. The Query design area includes: Show table names option displays the table names in the Table row of the query grid. Output all fields option displays all the fields in a query s underlying tables and queries when you run the query. Cheltenham Courseware Pty. Ltd

129 Microsoft Access Advanced Level Manual - Page 129 Enable AutoJoin option automatically creates an INNER JOIN between two tables in the query grid if and only if they have fields with the same name and same data type, and one of these fields is the primary key field for its table. The Run permissions group specifies if others are permitted to view data retrieved by queries or to run action queries: Owner s option allows all users to view or run the query, but only the owner can edit query. User s option applies the permissions defined for that classification of user. The SQL Server Compatible Syntax (ANSI 92) group formats queries exclusively in ANSI 92 standard syntax: This Database option applies formatting for the current database. Default for new databases option applies formatting for all new databases. The Query design font group - new in Access allows you to set the default font and font size for the results of your queries. Font option allows you to set the query result font type. The default is Tahoma. Font Size option allows you to set the query result font size. The default is 8. Configuring AutoCorrect Options Setting AutoCorrect Options AutoCorrect options will automatically correct misspelled words as you type. From the main menu, choose Tools > AutoCorrect Options OR from the main menu, choose Tools > Options. From the Options dialog box, click on the Spelling tab. Click on the AutoCorrect Options button. This will open the AutoCorrect dialog box: Cheltenham Courseware Pty. Ltd

130 Microsoft Access Advanced Level Manual - Page 130 The AutoCorrect options are self-explanatory. Exceptions are covered later in this section. Replace With options are covered later in this section. Excluding AutoCorrect Rules The Exceptions button opens the AutoCorrect Exceptions dialog box. Click on the First Letter tab: In the Don t capitalize after field, type the abbreviation with the period at the end. Click on the Add button to add this rule. Click on the INitial CAps tab: Cheltenham Courseware Pty. Ltd

131 Microsoft Access Advanced Level Manual - Page 131 In the Don t correct field, type the word you want to add. Click on the Add button to add this rule. Removing AutoCorrect Rules The Exceptions button opens the AutoCorrect Exceptions dialog box. In the First Letter tab, or the INitial CAps tab, select the rule you want to delete. Click on the Delete button to remove the rule. Adding Replace AutoCorrect Rules When you check the Replace text as you type option, you can specify which words you can replace with correct words: In the Replace field, type a commonly misspelled word, or a word you want to use as a shortcut to generate another word or symbol. In the With field, type the correctly spelled word, or the wanted word or symbol. Click Add button. Click OK to close the AutoCorrect dialog box. Cheltenham Courseware Pty. Ltd

132 Microsoft Access Advanced Level Manual - Page 132 Removing Replace AutoCorrect Rules Select the rule you want to remove. Click on the Delete button: Customising Menus and Toolbars Opening Customize Dialog Box From the main menu, choose View > Toolbars > Customize OR from the main menu, choose Tools > Customize OR right-click anywhere on the toolbar or menu bar and select Customize from the popup menu: Customising Toolbars Using any of the methods described above open the Customize dialog box. Click on the Toolbars tab: Cheltenham Courseware Pty. Ltd

133 Microsoft Access Advanced Level Manual - Page 133 This will list all available Toolbars, both built-in and custom. Check the check box for any toolbar you want displayed. Uncheck the check box for any toolbar you want to hide. Click Close when done. Creating Custom Toolbars Using any of the methods described above, open the Customize dialog box. Click on the Toolbars tab. Click on the New button: This will open the New Toolbar dialog box: Type the Toolbar name and click OK. You will notice that a new, empty toolbar appears in addition to the Customize dialog box, and that the new toolbar will appear in the Toolbars list: Cheltenham Courseware Pty. Ltd

134 Microsoft Access Advanced Level Manual - Page 134 Make sure that the new toolbar is selected, and click the Properties button: This will open the Toolbar Properties dialog box: Cheltenham Courseware Pty. Ltd

135 Microsoft Access Advanced Level Manual - Page 135 Toolbar Name option displays the name of the toolbar. You can edit the name here. Type option allows you to choose what type of custom bar you want to create: Menu Bar Toolbar Popup Docking option specifies what kind of docking is allowed for this custom bar: Allow Any Can t Change No Vertical No Horizontal Cheltenham Courseware Pty. Ltd

136 Microsoft Access Advanced Level Manual - Page 136 Show on Toolbars Menu option displays the toolbar name in the list or popup menu. Allow Customizing option allows changes to the toolbar s appearance or behaviour. Allow Resizing option allows resizing of the floating toolbar. Allow Moving option allows moving the toolbar between the floating and docked position. Allow Showing/Hiding option allows showing or hiding the toolbar using these methods: Right-click a toolbar and check or clear the toolbar name in the popup menu. From the main menu, choose View > Toolbars and check or clear the toolbar name in the list. Check or clear the toolbar name in the Customize dialog box, under the Toolbars tab. Removing Toolbars Using any of the methods described above open the Customize dialog box. Click on the Toolbars tab. Select the toolbar you want to remove and click on the Delete button: Customising Commands Once you create a new toolbar, you can add Commands and/or buttons to it. Use any of the methods described above to open the Customize dialog box. Cheltenham Courseware Pty. Ltd

137 Microsoft Access Advanced Level Manual - Page 137 Click on the Commands tab: Choose the category you want under the Categories list. Choose the command you want under the Commands list. To find more information about the command, click on the Description button. Adding Buttons to Toolbars Under the Commands list, click on the button you want to add to the toolbar. The cursor will change into an x: Cheltenham Courseware Pty. Ltd

138 Microsoft Access Advanced Level Manual - Page 138 Drag the button toward the toolbar until the cursor changes to the plus sign +: Cheltenham Courseware Pty. Ltd

139 Microsoft Access Advanced Level Manual - Page 139 You will see a new button on the toolbar: Removing Buttons from Toolbars With the Customize dialog box open, drag the button off the toolbar: OR right-click on the button and choose Delete from the popup menu: Customising Options Using any of the methods described above, open the Customize dialog box. Click on the Options tab: Cheltenham Courseware Pty. Ltd

140 Microsoft Access Advanced Level Manual - Page 140 The Personalized Menus and Toolbars group allows you to customise your work with Menus and Toolbars: Show Standard and Formatting toolbars on two rows option displays the two default toolbars on two rows when available. Always show full menus option displays all commands on menus. Show full menus after a short delay option displays the most used commands first. If you rest the mouse pointer over the menu, it expands to show all commands. Reset my usage data clears all automatically saved menu and toolbar settings. The Other group allows you to customise how command bars look and behave: Large icons option displays larger button images. List font names in their font option displays the drop-down list of fonts in their own font. Show ScreenTips on toolbars option displays the name of the button when the mouse pointer rests over the button. Show shortcut keys in ScreenTips option displays the shortcut key combination with the button name in the ScreenTip. Cheltenham Courseware Pty. Ltd

141 Microsoft Access Advanced Level Manual - Page 141 Menu animations option specifies whether or not menus are animated when displayed. Review Questions How would you: Set Access 2003 Options? Set View Options? Set General Options? Set Edit/Find Options? Set Keyboard Options? Set Datasheet Options? Set Forms/Reports Options? Set Pages Options? Set Advanced Options? Set International Options? Set Error Checking Options? Set Spelling Options? Set Tables/Queries Options? Set AutoCorrect Options? Exclude AutoCorrect Rules? Remove AutoCorrect Rules? Add Replace AutoCorrect Rules? Remove Replace AutoCorrect Rules? Open Customize Dialog Box? Customise Toolbars? Create Custom Toolbars? Remove Toolbars? Customise Commands? Add Buttons to Toolbars? Remove Buttons from Toolbars? Customise Options? Cheltenham Courseware Pty. Ltd

142 Microsoft Access Advanced Level Manual - Page 142 Managing & Maintaining Databases When you have completed this learning module you will have seen how to: Use the Table Analyzer Rename Tables Add Key Fields Use the Performance Analyzer Use the Documenter Analyzer Print Documentation Export Documentation Use the Object Dependencies tool Optimising Databases with Table Analyzer The Table Analyzer helps you optimise a database by reducing data redundancy using a set of related tables, suggesting additional optimization, adding more indexes, etc. Using the Table Analyzer From the main menu, choose Tools > Analyze > Table. This will open the Table Analyzer Wizard dialog box: Cheltenham Courseware Pty. Ltd

143 Microsoft Access Advanced Level Manual - Page 143 The first page of the wizard gives an introduction on how the Table Analyzer looks at the problem. You can also click on the Show me an example buttons to view an example. Click Next to continue. The second page of the wizard gives an introduction on how the Table Analyzer solves the problem. You can also click on the Show me an example buttons to view an example. Click Next to continue: The next page of the wizard allows you to select which Tables you want to analyse. To skip the introductory pages of the wizard next time you run the Table Wizard, you should uncheck the Show introductory pages option. Click Next to continue: Cheltenham Courseware Pty. Ltd

144 Microsoft Access Advanced Level Manual - Page 144 The next page of the wizard allows you to decide how to split up the data. You can let wizard decide, or you can decide. Click Next to continue: Cheltenham Courseware Pty. Ltd

145 Microsoft Access Advanced Level Manual - Page 145 If you select the wizard to make a decision you might see the message containing the wizard s recommendation. If so, click OK. The next page of the wizard represents a diagram of the suggested redistribution of information: Cheltenham Courseware Pty. Ltd

146 Microsoft Access Advanced Level Manual - Page 146 You can see more instructions on how to handle the wizard s suggestions by clicking the Tips button at the top right-hand corner of the dialog box: Read the Tips instructions to help you implement the wizard s suggestions: The wizard suggests that you create a Lookup Table for each field with a link from the original Employees table (Table1) to Table2 and Table3: Cheltenham Courseware Pty. Ltd

147 Microsoft Access Advanced Level Manual - Page 147 Renaming Tables Once you approve the table structures, you have to Rename the proposed tables. Select each table and click on the Rename Table button: Cheltenham Courseware Pty. Ltd

148 Microsoft Access Advanced Level Manual - Page 148 Enter the new Table Name and click OK: When you finish renaming tables, click on Next to continue. Adding Key Fields The next page of the wizard allows you to verify the primary key fields. Wizard adds the Generated Unique ID primary key fields for newly generated tables. The original table does not have the primary key. If there is a field that can be used as a primary key, select that field in the table and click on the Set Unique Identifier button: The field is now a primary key, marked with the key icon: Cheltenham Courseware Pty. Ltd

149 Microsoft Access Advanced Level Manual - Page 149 To undo the change, select the field and click on the Undo button: If there is no field in the table that can be used as a primary key, you can assign a generated key. Select the table without a primary key and click on the Add Generated Key button: Cheltenham Courseware Pty. Ltd

150 Microsoft Access Advanced Level Manual - Page 150 The generated primary key field is added, marked with the key icon: After adding primary key fields, click on Next to continue. On the final page, the wizard offers to create a query for you that looks like your original table and has the same name. Letting the wizard create a query ensures that you can continue to work with all the forms and reports created using the original table. Click Finish to close the wizard: Cheltenham Courseware Pty. Ltd

151 Microsoft Access Advanced Level Manual - Page 151 Optimising Databases with Performance Analyzer The Performance Analyzer helps you optimise a database by analysing all objects in the database and suggesting ways you can improve the database performance. Using the Performance Analyzer From the main menu, choose Tools > Analyze > Performance. The Performance Analyzer dialog box opens, containing tabs for each type of database object: Cheltenham Courseware Pty. Ltd

152 Microsoft Access Advanced Level Manual - Page 152 Select the appropriate tab, or click on the All Object Types tab to list all database objects. Check the check box besides the object(s) you want to analyse and click the OK button: To analyse the entire database, click on the All Object Types tab and click on the Select All button to check all objects. Click OK to start the analysis: Cheltenham Courseware Pty. Ltd

153 Microsoft Access Advanced Level Manual - Page 153 A Performance Analyzer message box displays the analysing process: At the end of the process, the Performance Analyzer displays the Analysis Results: Cheltenham Courseware Pty. Ltd

154 Microsoft Access Advanced Level Manual - Page 154 Key icons specify what kind of information is contained in the finding list: Recommendation, Suggestion, Idea or Fixed. Analysis Notes pane describes the results for the selected list item. If there are any Recommendations, you can click on the Optimize button to implement the analyzer s recommendations. Click Close to close the Performance Analyzer. Documenting Databases with Documenter Analyzer The Documenter Analyzer helps you document databases, which is one of most important tasks in a database management system. Using the Documenter Analyzer From the main menu, choose Tools > Analyze > Documenter. The Documenter dialog box opens, containing tabs for each type of database object: Check the objects from each tab you want documented, or click the All Object Types tab and click on the Select All button to document the whole database. Click on the Options button. This will open the Print Table Definition dialog box: Cheltenham Courseware Pty. Ltd

155 Microsoft Access Advanced Level Manual - Page 155 The Include for Table group allows you to limit what table elements you want to print: - Properties - Relationships - Permissions by User and Group. The Include for Fields group allows you to limit what field information you want to print: - Nothing - Names, Data Types, and Sizes - Names, Data Types, Sizes, and Properties The Include for Indexes group allows you to limit what index information you want to print: - Nothing - Names and Fields - Names, Fields, and Properties Click OK twice to start the Documenter. The Status Bar displays the analysis progress. Printing Documentation The report is opened in Print Preview: Cheltenham Courseware Pty. Ltd

156 Microsoft Access Advanced Level Manual - Page 156 Right-click on the report to open the popup menu where you can configure Page Setup and other print options: Exporting Documentation Once you have generated the report you can export the documentation data. Right-click on the report to open the popup menu and select the Export option Cheltenham Courseware Pty. Ltd

157 Microsoft Access Advanced Level Manual - Page 157 OR from the main menu, choose File > Export. This will open the Export Report dialog box where you can select the location, file name and file type for export: You can save the report in various Excel, HTML Document, Text File, Rich Text Format, Snapshot Format and XML Document formats. Once you select the type under the Save as type field, click on the Export button: A Printer message box displays the exporting process: Avoiding errors with the Object Dependencies task pane The Object Dependencies task pane is a new Access 2003 feature that assists you in avoiding errors (i.e. those that occur when renaming queries, Cheltenham Courseware Pty. Ltd

158 Microsoft Access Advanced Level Manual - Page 158 tables, or fields), thus improving database performance. It helps you by displaying all of the objects that depend on the object you are currently working on, as well the objects that your object relies upon. Using the Object Dependencies Tool To use the Object Dependencies feature you must first activate the Name AutoCorrect feature, which tracks information about object interdependency. From the main menu, select Tools > Options. In the Options dialog box, click on the General tab: Click on the Track name AutoCorrect info checkbox, and in the displayed dialog box, click OK: Click OK to close the Options dialog box. To view the Object Dependencies, select an object name in the Database window: Cheltenham Courseware Pty. Ltd

159 Microsoft Access Advanced Level Manual - Page 159 From the main menu, select View > Object Dependencies OR right-click on the object, and select Object Dependencies from the menu: The Object Dependencies task pane will display a list of the objects that are dependent on the object that you selected. To see a list of objects that your object relies on, select the Objects that I depend on option button: Cheltenham Courseware Pty. Ltd

160 Microsoft Access Advanced Level Manual - Page 160 You can also click on an expand (+) icon to see a complete list of object elements: Review Questions How would you: Use the Table Analyzer? Rename Tables? Add Key Fields? Use the Performance Analyzer? Use the Documenter Analyzer? Print Documentation? Export Documentation? Use the Object Dependencies tool? Cheltenham Courseware Pty. Ltd

Chapter 6. SQL Data Manipulation

Chapter 6. SQL Data Manipulation Chapter 6 SQL Data Manipulation Pearson Education 2014 Chapter 6 - Objectives Purpose and importance of SQL. How to retrieve data from database using SELECT and: Use compound WHERE conditions. Sort query

More information

STRUCTURED QUERY LANGUAGE (SQL)

STRUCTURED QUERY LANGUAGE (SQL) STRUCTURED QUERY LANGUAGE (SQL) EGCO321 DATABASE SYSTEMS KANAT POOLSAWASD DEPARTMENT OF COMPUTER ENGINEERING MAHIDOL UNIVERSITY SQL TIMELINE SCOPE OF SQL THE ISO SQL DATA TYPES SQL identifiers are used

More information

SAMPLE. Excel 2010 Advanced. Excel 2010 Advanced. Excel 2010 Advanced Page 1

SAMPLE. Excel 2010 Advanced. Excel 2010 Advanced. Excel 2010 Advanced Page 1 Excel 2010 Advanced Excel 2010 Advanced Page 1 Excel 2010 Advanced 2010 Cheltenham Courseware Pty. Ltd. www.cheltenhamcourseware.com.au Excel 2010 Advanced Page 2 2010 Cheltenham Courseware Pty. Ltd. All

More information

Word 2016 Advanced. North American Edition SAMPLE

Word 2016 Advanced. North American Edition SAMPLE Word 2016 Advanced Word 2016 Advanced North American Edition WORD 2016 ADVANCED Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without

More information

WORD 2016 INTERMEDIATE Page 1. Word 2016 Intermediate. North American Edition SAMPLE

WORD 2016 INTERMEDIATE Page 1. Word 2016 Intermediate. North American Edition SAMPLE Word 2016 Intermediate WORD 2016 INTERMEDIATE Page 1 Word 2016 Intermediate North American Edition 2015 Cheltenham Group Pty. Ltd. - www.cheltenhamcourseware.com WORD 2016 INTERMEDIATE Page 2 2015 Cheltenham

More information

Publisher 2016 Foundation SAMPLE

Publisher 2016 Foundation SAMPLE Publisher 2016 Foundation Publisher 2016 Foundation Microsoft Publisher 2016 Foundation - Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied

More information

Excel 2010 Advanced. Excel 2010 Advanced SAMPLE

Excel 2010 Advanced. Excel 2010 Advanced SAMPLE Excel 2010 Advanced Excel 2010 Advanced Excel 2010 Advanced Page 2 2010 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without written permission

More information

Microsoft Publisher 2013 Foundation. Publisher 2013 Foundation SAMPLE

Microsoft Publisher 2013 Foundation. Publisher 2013 Foundation SAMPLE Microsoft Publisher 2013 Foundation Publisher 2013 Foundation Microsoft Publisher 2013 Foundation - Page 2 2013 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may

More information

Publisher 2016 Foundation. North American Edition SAMPLE

Publisher 2016 Foundation. North American Edition SAMPLE Publisher 2016 Foundation Publisher 2016 Foundation North American Edition Microsoft Publisher 2016 Foundation - Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this

More information

Publisher 2013 Foundation SAMPLE

Publisher 2013 Foundation SAMPLE Publisher 2013 Foundation Publisher 2013 Foundation Microsoft Publisher 2013 Foundation - Page 2 2013 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied

More information

Microsoft Access XP Edition for ECDL Syllabus 4.5 (UK only)

Microsoft Access XP Edition for ECDL Syllabus 4.5 (UK only) ECDL Module 5 WORKBOOK Databases Microsoft Access XP Edition for ECDL Syllabus 4.5 (UK only) PAGE 2 - ECDL MODULE 5 (OFFICE XP) - WORKBOOK 1995-2007 Cheltenham Courseware Ltd. All trademarks acknowledged.

More information

Excel 2013 Advanced. Excel 2013 Advanced SAMPLE

Excel 2013 Advanced. Excel 2013 Advanced SAMPLE Excel 2013 Advanced Excel 2013 Advanced Excel 2013 Advanced Page 2 2013 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without written permission from

More information

Microsoft Access 2003 Edition for ECDL Syllabus 4.5 (UK only)

Microsoft Access 2003 Edition for ECDL Syllabus 4.5 (UK only) ECDL Module 5 WORKBOOK Databases Microsoft Access 2003 Edition for ECDL Syllabus 4.5 (UK only) PAGE 2 - ECDL MODULE 5 (OFFICE 2003) - WORKBOOK 1995-2007 Cheltenham Courseware Ltd. All trademarks acknowledged.

More information

Excel 2016 Advanced SAMPLE

Excel 2016 Advanced SAMPLE Excel 2016 Advanced Excel 2016 Advanced Excel 2016 Advanced Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without written permission from

More information

Publisher 2010 Foundation. Publisher 2010 Foundation Level SAMPLE

Publisher 2010 Foundation. Publisher 2010 Foundation Level SAMPLE Publisher 2010 Foundation Publisher 2010 Foundation Level Microsoft Publisher 2010 Foundation - Page 2 1995-2012 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document

More information

Excel 2013 Advanced. Excel 2013 Advanced SAMPLE

Excel 2013 Advanced. Excel 2013 Advanced SAMPLE Excel 2013 Advanced Excel 2013 Advanced Excel 2013 Advanced Page 2 2013 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without written permission from

More information

Excel 2010 Foundation. Excel 2010 Foundation SAMPLE

Excel 2010 Foundation. Excel 2010 Foundation SAMPLE Excel 2010 Foundation Excel 2010 Foundation Excel 2010 Foundation Page 2 2010 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without written permission

More information

SAMPLE. PowerPoint 2010 Advanced. PowerPoint 2010 Advanced. PowerPoint 2010 Advanced Page 1

SAMPLE. PowerPoint 2010 Advanced. PowerPoint 2010 Advanced. PowerPoint 2010 Advanced Page 1 PowerPoint 2010 Advanced PowerPoint 2010 Advanced Page 1 PowerPoint 2010 Advanced 2010 Cheltenham Courseware Pty. Ltd. www.cheltenhamcourseware.com.au PowerPoint 2010 Advanced Page 2 2010 Cheltenham Courseware

More information

Excel 2016 Advanced. North American Edition SAMPLE

Excel 2016 Advanced. North American Edition SAMPLE Excel 2016 Advanced Excel 2016 Advanced North American Edition Excel 2016 Advanced Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without

More information

PowerPoint 2010 Intermediate. PowerPoint 2010 Intermediate SAMPLE

PowerPoint 2010 Intermediate. PowerPoint 2010 Intermediate SAMPLE PowerPoint 2010 Intermediate PowerPoint 2010 Intermediate PowerPoint 2010 Intermediate Page 2 2010 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied

More information

PowerPoint 2013 Intermediate. PowerPoint 2013 Intermediate SAMPLE

PowerPoint 2013 Intermediate. PowerPoint 2013 Intermediate SAMPLE PowerPoint 2013 Intermediate PowerPoint 2013 Intermediate PowerPoint 2013 Intermediate Page 2 2013 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied

More information

PowerPoint 2013 Advanced. PowerPoint 2013 Advanced SAMPLE

PowerPoint 2013 Advanced. PowerPoint 2013 Advanced SAMPLE PowerPoint 2013 Advanced PowerPoint 2013 Advanced PowerPoint 2013 Advanced Page 2 2013 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without

More information

SAMPLE. Access 2010 Foundation. Access 2010 Foundation. Access 2010 Foundation Page 1

SAMPLE. Access 2010 Foundation. Access 2010 Foundation. Access 2010 Foundation Page 1 Access 2010 Foundation Access 2010 Foundation Page 1 Access 2010 Foundation 2010 Cheltenham Courseware Pty. Ltd. www.cheltenhamcourseware.com.au Access 2010 Foundation Page 2 2010 Cheltenham Courseware

More information

Cheltenham Courseware Microsoft Excel 2003 Manual - Advanced Level

Cheltenham Courseware   Microsoft Excel 2003 Manual - Advanced Level Cheltenham Courseware www.cheltenhamcourseware.com Microsoft Excel 2003 Manual - Advanced Level Page 2 - Excel 2003 - Advanced Level Manual 1995-2010 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged.

More information

ECDL / ICDL SYLLABUS 5.0. ECDL Module 4. Spreadsheets Office 2003 Edition ECDL Syllabus Five SAMPLE

ECDL / ICDL SYLLABUS 5.0. ECDL Module 4. Spreadsheets Office 2003 Edition ECDL Syllabus Five SAMPLE ECDL / ICDL SYLLABUS 5.0 ECDL Module 4 Spreadsheets Office 2003 Edition ECDL Syllabus Five ECDL Module Four - Page 2 1995-2010 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part

More information

Access 2010 Foundation. Access 2010 Foundation SAMPLE

Access 2010 Foundation. Access 2010 Foundation SAMPLE Access 2010 Foundation Access 2010 Foundation Access 2010 Foundation Page 2 2010 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without written

More information

PowerPoint 2013 Advanced. PowerPoint 2013 Advanced SAMPLE

PowerPoint 2013 Advanced. PowerPoint 2013 Advanced SAMPLE PowerPoint 2013 Advanced PowerPoint 2013 Advanced PowerPoint 2013 Advanced Page 2 2013 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without

More information

PowerPoint 2016 Advanced SAMPLE

PowerPoint 2016 Advanced SAMPLE PowerPoint 2016 Advanced PowerPoint 2016 Advanced PowerPoint 2016 Advanced Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without written

More information

PowerPoint 2010 Intermediate PowerPoint 2010 Intermediate Page 1 SAMPLE

PowerPoint 2010 Intermediate PowerPoint 2010 Intermediate Page 1 SAMPLE PowerPoint 2010 Intermediate PowerPoint 2010 Intermediate Page 1 PowerPoint 2010 Intermediate 2010 Cheltenham Courseware Pty. Ltd. www.cheltenhamcourseware.com.au PowerPoint 2010 Intermediate Page 2 2010

More information

SAMPLE. Access 2010 Intermediate. Access 2010 Intermediate. Access 2010 Intermediate Page 1

SAMPLE. Access 2010 Intermediate. Access 2010 Intermediate. Access 2010 Intermediate Page 1 Access 2010 Intermediate Access 2010 Intermediate Page 1 Access 2010 Intermediate 2010 Cheltenham Courseware Pty. Ltd. www.cheltenhamcourseware.com.au Access 2010 Intermediate Page 2 2010 Cheltenham Courseware

More information

Excel 2013 Foundation. Excel 2013 Foundation SAMPLE

Excel 2013 Foundation. Excel 2013 Foundation SAMPLE Excel 2013 Foundation Excel 2013 Foundation Excel 2013 Foundation Page 2 2013 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without written permission

More information

Access 2010 Intermediate. Access 2010 Intermediate SAMPLE

Access 2010 Intermediate. Access 2010 Intermediate SAMPLE Access 2010 Intermediate Access 2010 Intermediate Access 2010 Intermediate Page 2 2010 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without

More information

Microsoft Visio 2016 Foundation. Microsoft Visio 2016 Foundation Level North American Edition SAMPLE

Microsoft Visio 2016 Foundation. Microsoft Visio 2016 Foundation Level North American Edition SAMPLE Microsoft Visio 2016 Foundation Microsoft Visio 2016 Foundation Level North American Edition Visio 2016 Foundation - Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of

More information

Lecture 06. Fall 2018 Borough of Manhattan Community College

Lecture 06. Fall 2018 Borough of Manhattan Community College Lecture 06 Fall 2018 Borough of Manhattan Community College 1 Introduction to SQL Over the last few years, Structured Query Language (SQL) has become the standard relational database language. More than

More information

Excel 2016 Foundation. North American Edition SAMPLE

Excel 2016 Foundation. North American Edition SAMPLE Excel 2016 Foundation Excel 2016 Foundation North American Edition Excel 2016 Foundation Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied

More information

Excel 2016 Foundation SAMPLE

Excel 2016 Foundation SAMPLE Excel 2016 Foundation Excel 2016 Foundation Excel 2016 Foundation Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without written permission

More information

PowerPoint 2010 Foundation PowerPoint 2010 Foundation Page 1 SAMPLE

PowerPoint 2010 Foundation PowerPoint 2010 Foundation Page 1 SAMPLE PowerPoint 2010 Foundation PowerPoint 2010 Foundation Page 1 PowerPoint 2010 Foundation 2010 Cheltenham Courseware Pty. Ltd. www.cheltenhamcourseware.com.au PowerPoint 2010 Foundation Page 2 2010 Cheltenham

More information

PowerPoint 2010 Foundation. PowerPoint 2010 Foundation SAMPLE

PowerPoint 2010 Foundation. PowerPoint 2010 Foundation SAMPLE PowerPoint 2010 Foundation PowerPoint 2010 Foundation PowerPoint 2010 Foundation Page 2 2010 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without

More information

Access 2016 Foundation SAMPLE

Access 2016 Foundation SAMPLE Access 2016 Foundation Access 2016 Foundation Access 2016 Foundation Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without written permission

More information

Cheltenham Courseware Microsoft Excel 2007 Intermediate Level

Cheltenham Courseware   Microsoft Excel 2007 Intermediate Level Cheltenham Courseware www.cheltenhamcourseware.com Microsoft Excel 2007 Intermediate Level Excel 2007 Intermediate - Page 2 1995-2008 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE.

More information

Cheltenham Courseware Microsoft Project 2007 Manual - Foundation Level SAMPLE

Cheltenham Courseware   Microsoft Project 2007 Manual - Foundation Level SAMPLE Cheltenham Courseware www.cctglobal.com Microsoft Project 2007 Manual - Foundation Level Page 2 - Project 2007 Foundation Level 1995-2010 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE.

More information

Access 2016 Foundation. North American Edition SAMPLE

Access 2016 Foundation. North American Edition SAMPLE Access 2016 Foundation Access 2016 Foundation North American Edition Access 2016 Foundation Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied

More information

Cheltenham Courseware Microsoft Excel 2007 Advanced Level

Cheltenham Courseware   Microsoft Excel 2007 Advanced Level Cheltenham Courseware www.cheltenhamcourseware.com Microsoft Excel 2007 Advanced Level Excel 2007 Advanced - Page 2 1995-2010 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part

More information

Microsoft Project 2010 Foundation. Microsoft Project 2010 Manual - Foundation Level SAMPLE

Microsoft Project 2010 Foundation. Microsoft Project 2010 Manual - Foundation Level SAMPLE Microsoft Project 2010 Foundation Microsoft Project 2010 Manual - Foundation Level Page 2 - Project 2010 Foundation Level 1995-2011 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No

More information

CS317 File and Database Systems

CS317 File and Database Systems CS317 File and Database Systems Lecture 4 Intro to SQL (Chapter 6 - DML, Chapter 7 - DDL) September 17, 2018 Sam Siewert Backup to PRClab1.erau.edu If PRClab1.erau.edu is down or slow Use SE Workstation

More information

Microsoft Project 2016 Foundation. Microsoft Project 2016 Manual - Foundation Level SAMPLE

Microsoft Project 2016 Foundation. Microsoft Project 2016 Manual - Foundation Level SAMPLE Microsoft Project 2016 Foundation Microsoft Project 2016 Manual - Foundation Level Microsoft Project 2016 Foundation - Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part

More information

Cheltenham Courseware Microsoft Project 2007 Manual - Foundation Level SAMPLE

Cheltenham Courseware   Microsoft Project 2007 Manual - Foundation Level SAMPLE Cheltenham Courseware www.cctglobal.com Microsoft Project 2007 Manual - Foundation Level Page 2 - Project 2007 - Foundation Level 1995-2010 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged.

More information

CMP-3440 Database Systems

CMP-3440 Database Systems CMP-3440 Database Systems Advanced SQL Lecture 07 zain 1 Select Statement - Aggregates ISO standard defines five aggregate functions: COUNT returns number of values in specified column. SUM returns sum

More information

Microsoft Project 2016 Foundation. Microsoft Project 2016 Manual - Foundation Level North American Edition SAMPLE

Microsoft Project 2016 Foundation. Microsoft Project 2016 Manual - Foundation Level North American Edition SAMPLE Microsoft Project 2016 Foundation Microsoft Project 2016 Manual - Foundation Level North American Edition Microsoft Project 2016 Foundation - Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged.

More information

Reduced Quality Sample

Reduced Quality Sample Microsoft Visio Visio 2007 2007 Essentials Visio Essentials Mobile MOUSe Microsoft Visio 2007 Visio Essentials Version # 1.0 08/08/2010 11:23 AM Visio 2007 Essentials PAGE 2 All trademarks acknowledged.

More information

ECDL / ICDL SYLLABUS 5.0. ECDL Module 3. Word Processing Office 2003 Edition ECDL Syllabus Five SAMPLE

ECDL / ICDL SYLLABUS 5.0. ECDL Module 3. Word Processing Office 2003 Edition ECDL Syllabus Five SAMPLE ECDL / ICDL SYLLABUS 5.0 ECDL Module 3 Word Processing Office 2003 Edition ECDL Syllabus Five ECDL Syllabus Five Using Windows XP / MS Office 2003 - Module Three - Page 2 1995-2010 Cheltenham Courseware

More information

Excel 2016 Intermediate. North American Edition SAMPLE

Excel 2016 Intermediate. North American Edition SAMPLE Excel 2016 Intermediate Excel 2016 Intermediate North American Edition Excel 2016 Intermediate Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be

More information

Cheltenham Courseware Microsoft Word 2007 Foundation Level

Cheltenham Courseware   Microsoft Word 2007 Foundation Level Cheltenham Courseware www.cheltenhamcourseware.com Microsoft Word 2007 Foundation Level Word 2007 Foundation - Page 2 TUTOR SETUP INFORMATION Please copy the sample files into the My Documents folder.

More information

SAMPLE. Word 2010 Foundation. Word 2010 Foundation. WORD 2010 FOUNDATION Page 1

SAMPLE. Word 2010 Foundation. Word 2010 Foundation. WORD 2010 FOUNDATION Page 1 Word 2010 Foundation WORD 2010 FOUNDATION Page 1 Word 2010 Foundation 2010 Cheltenham Courseware Pty. Ltd. - www.cheltenhamcourseware.com.au WORD 2010 FOUNDATION Page 2 2010 Cheltenham Courseware Pty.

More information

Microsoft Word 2013 Foundation. Microsoft Word 2013 Foundation SAMPLE

Microsoft Word 2013 Foundation. Microsoft Word 2013 Foundation SAMPLE Microsoft Word 2013 Foundation Microsoft Word 2013 Foundation WORD 2013 FOUNDATION Page 2 2013 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without

More information

Excel 2016 Intermediate SAMPLE

Excel 2016 Intermediate SAMPLE Excel 2016 Intermediate Excel 2016 Intermediate Excel 2016 Intermediate Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without written

More information

Microsoft Word 2016 Foundation SAMPLE

Microsoft Word 2016 Foundation SAMPLE Microsoft Word 2016 Foundation Microsoft Word 2016 Foundation WORD 2016 FOUNDATION Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without

More information

Microsoft Word 2013 Foundation. Microsoft Word 2013 Foundation SAMPLE

Microsoft Word 2013 Foundation. Microsoft Word 2013 Foundation SAMPLE Microsoft Word 2013 Foundation Microsoft Word 2013 Foundation WORD 2013 FOUNDATION Page 2 2013 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without

More information

Microsoft Word 2016 Foundation. North American Edition SAMPLE

Microsoft Word 2016 Foundation. North American Edition SAMPLE Microsoft Word 2016 Foundation Microsoft Word 2016 Foundation North American Edition WORD 2016 FOUNDATION Page 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document

More information

ECDL Module 3. REFERENCE MANUAL Word Processing. Microsoft Word XP Edition for ECDL Syllabus Four

ECDL Module 3. REFERENCE MANUAL Word Processing. Microsoft Word XP Edition for ECDL Syllabus Four ECDL Module 3 REFERENCE MANUAL Word Processing Microsoft Word XP Edition for ECDL Syllabus Four - ECDL MODULE 3 (USING OFFICE XP) - MANUAL٢PAGE 1995-2006 Cheltenham Courseware Ltd. Crescent House 24 Lansdown

More information

Microsoft Project 2003

Microsoft Project 2003 Microsoft Project 2003 MANUAL - FOUNDATION LEVEL European Edition PAGE 2 - PROJECT 2003 - FOUNDATION LEVEL MANUAL 1995-2004 Cheltenham Courseware Ltd. Crescent House 24 Lansdown Crescent Lane Cheltenham

More information

Subquery: There are basically three types of subqueries are:

Subquery: There are basically three types of subqueries are: Subquery: It is also known as Nested query. Sub queries are queries nested inside other queries, marked off with parentheses, and sometimes referred to as "inner" queries within "outer" queries. Subquery

More information

CSCU9Q5. Relational Algebra. Operators. Relational operators. Database Principles and Applications. CSCU9Q5 - Database P&A

CSCU9Q5. Relational Algebra. Operators. Relational operators. Database Principles and Applications. CSCU9Q5 - Database P&A Relational Algebra The relational algebra is a theoretical language It is the theoretical basis of query languages such as SQL (more later). CSCU9Q5 Database Principles and Applications Relational Algebra

More information

1) Introduction to SQL

1) Introduction to SQL 1) Introduction to SQL a) Database language enables users to: i) Create the database and relation structure; ii) Perform insertion, modification and deletion of data from the relationship; and iii) Perform

More information

Microsoft Windows 8.1 Foundation. Windows 8.1 Foundation For Business Users SAMPLE

Microsoft Windows 8.1 Foundation. Windows 8.1 Foundation For Business Users SAMPLE Microsoft Windows 8.1 Foundation Windows 8.1 Foundation For Business Users WINDOWS 8.1 FOUNDATION FOR BUSINESS USERS PAGE 2 2013 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of

More information

COMP102: Introduction to Databases, 5 & 6

COMP102: Introduction to Databases, 5 & 6 COMP102: Introduction to Databases, 5 & 6 Dr Muhammad Sulaiman Khan Department of Computer Science University of Liverpool U.K. 8/11 February, 2011 Introduction: SQL, part 2 Specific topics for today:

More information

ECDL Module 6. Presentation. Windows Vista / Microsoft Office 2007 Edition Syllabus Five

ECDL Module 6. Presentation. Windows Vista / Microsoft Office 2007 Edition Syllabus Five ECDL Module 6 Presentation Windows Vista / Microsoft Office 2007 Edition Syllabus Five ECDL Module Six - Page 2 1995-2008 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this

More information

FOCUS ON: DATABASE MANAGEMENT

FOCUS ON: DATABASE MANAGEMENT EXCEL 2002 (XP) FOCUS ON: DATABASE MANAGEMENT December 16, 2005 ABOUT GLOBAL KNOWLEDGE, INC. Global Knowledge, Inc., the world s largest independent provider of integrated IT education solutions, is dedicated

More information

ECDL Module 3 WORKBOOK. Word Processing. Microsoft Word XP Edition for ECDL Syllabus Four

ECDL Module 3 WORKBOOK. Word Processing. Microsoft Word XP Edition for ECDL Syllabus Four ECDL Module 3 WORKBOOK Word Processing Microsoft Word XP Edition for ECDL Syllabus Four PAGE 2 - ECDL MODULE 3 WORKBOOK (USING OFFICE XP) 1995-2005 Cheltenham Courseware Ltd. Crescent House 24 Lansdown

More information

Microsoft Windows 10 Foundation. Windows 10 Foundation For Business Users SAMPLE

Microsoft Windows 10 Foundation. Windows 10 Foundation For Business Users SAMPLE Microsoft Windows 10 Foundation Windows 10 Foundation For Business Users WINDOWS 10 FOUNDATION FOR BUSINESS USERS PAGE 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this

More information

Microsoft Word Foundation Level

Microsoft Word Foundation Level Microsoft Word 2007 Foundation Level WORD 2007 FOUNDATION - PAGE 2 TUTOR SETUP INFORMATION Please copy the sample files into the My Documents folder. 1995-2008 Cheltenham Courseware Pty. Ltd. All trademarks

More information

Microsoft Windows 8.1 Foundation. Windows 8.1 Foundation For Business Users SAMPLE

Microsoft Windows 8.1 Foundation. Windows 8.1 Foundation For Business Users SAMPLE Microsoft Windows 8.1 Foundation Windows 8.1 Foundation For Business Users WINDOWS 8.1 FOUNDATION FOR BUSINESS USERS PAGE 2 2013 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of

More information

ECDL Module 4. Spreadsheets. Windows Vista / Microsoft Office 2007 Edition Syllabus Five

ECDL Module 4. Spreadsheets. Windows Vista / Microsoft Office 2007 Edition Syllabus Five ECDL Module 4 Spreadsheets Windows Vista / Microsoft Office 2007 Edition Syllabus Five ECDL Module Four - Page 2 1995-2008 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of

More information

Word 2010 Basics BY M.DAWY.ASWAN

Word 2010 Basics BY M.DAWY.ASWAN Word 2010 Basics BY M.DAWY.ASWAN Page 2 2010 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without written permission from Cheltenham Courseware

More information

Microsoft Windows 10 Foundation. Windows 10 Foundation For Business Users SAMPLE

Microsoft Windows 10 Foundation. Windows 10 Foundation For Business Users SAMPLE Microsoft Windows 10 Foundation Windows 10 Foundation For Business Users WINDOWS 10 FOUNDATION FOR BUSINESS USERS PAGE 2 2015 Cheltenham Group Pty. Ltd. All trademarks acknowledged. E&OE. No part of this

More information

Example 1 - Create Horizontal View. Example 2 - Create Vertical View. Views. Views

Example 1 - Create Horizontal View. Example 2 - Create Vertical View. Views. Views Views Views RECALLS: View Dynamic result of one or more relational operations operating on the base relations to produce another relation. o Virtual relation that does not actually exist in the database

More information

Follow these steps to get started: o Launch MS Access from your start menu. The MS Access startup panel is displayed:

Follow these steps to get started: o Launch MS Access from your start menu. The MS Access startup panel is displayed: Forms-based Database Queries The topic presents a summary of Chapter 3 in the textbook, which covers using Microsoft Access to manage and query an Access database. The screenshots in this topic are from

More information

SAMPLE. Excel 2010 Intermediate. Excel 2010 Intermediate. Excel 2010 Intermediate Page 1

SAMPLE. Excel 2010 Intermediate. Excel 2010 Intermediate. Excel 2010 Intermediate Page 1 Excel 2010 Intermediate Excel 2010 Intermediate Page 1 Excel 2010 Intermediate Excel 2010 Intermediate Page 2 2010 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document

More information

Access Intermediate

Access Intermediate Access 2010 - Intermediate 103-134 Advanced Queries Quick Links Overview Pages AC116 AC117 Selecting Fields Pages AC118 AC119 AC122 Sorting Results Pages AC125 AC126 Specifying Criteria Pages AC132 AC134

More information

STIDistrict Query (Basic)

STIDistrict Query (Basic) STIDistrict Query (Basic) Creating a Basic Query To create a basic query in the Query Builder, open the STIDistrict workstation and click on Utilities Query Builder. When the program opens, database objects

More information

SQL Queries. COSC 304 Introduction to Database Systems SQL. Example Relations. SQL and Relational Algebra. Example Relation Instances

SQL Queries. COSC 304 Introduction to Database Systems SQL. Example Relations. SQL and Relational Algebra. Example Relation Instances COSC 304 Introduction to Database Systems SQL Dr. Ramon Lawrence University of British Columbia Okanagan ramon.lawrence@ubc.ca SQL Queries Querying with SQL is performed using a SELECT statement. The general

More information

Chapter 7. Introduction to Structured Query Language (SQL) Database Systems: Design, Implementation, and Management, Seventh Edition, Rob and Coronel

Chapter 7. Introduction to Structured Query Language (SQL) Database Systems: Design, Implementation, and Management, Seventh Edition, Rob and Coronel Chapter 7 Introduction to Structured Query Language (SQL) Database Systems: Design, Implementation, and Management, Seventh Edition, Rob and Coronel 1 In this chapter, you will learn: The basic commands

More information

Creating a Crosstab Query in Design View

Creating a Crosstab Query in Design View Procedures LESSON 31: CREATING CROSSTAB QUERIES Using the Crosstab Query Wizard box, click Crosstab Query Wizard. 5. In the next Crosstab Query the table or query on which you want to base the query. 7.

More information

Microsoft Access XP (2002) - Advanced Queries

Microsoft Access XP (2002) - Advanced Queries Microsoft Access XP (2002) - Advanced Queries Group/Summary Operations Change Join Properties Not Equal Query Parameter Queries Working with Text IIF Queries Expression Builder Backing up Tables Action

More information

Lesson 2. Data Manipulation Language

Lesson 2. Data Manipulation Language Lesson 2 Data Manipulation Language IN THIS LESSON YOU WILL LEARN To add data to the database. To remove data. To update existing data. To retrieve the information from the database that fulfil the stablished

More information

12. MS Access Tables, Relationships, and Queries

12. MS Access Tables, Relationships, and Queries 12. MS Access Tables, Relationships, and Queries 12.1 Creating Tables and Relationships Suppose we want to build a database to hold the information for computers (also refer to parts in the text) and suppliers

More information

CSC Web Programming. Introduction to SQL

CSC Web Programming. Introduction to SQL CSC 242 - Web Programming Introduction to SQL SQL Statements Data Definition Language CREATE ALTER DROP Data Manipulation Language INSERT UPDATE DELETE Data Query Language SELECT SQL statements end with

More information

Project Manual - Foundation Level SAMPLE

Project Manual - Foundation Level SAMPLE Project 2003 Manual - Foundation Level PAGE 2 - PROJECT 2003 - FOUNDATION LEVEL MANUAL 1995-2007 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied

More information

You can write a command to retrieve specified columns and all rows from a table, as illustrated

You can write a command to retrieve specified columns and all rows from a table, as illustrated CHAPTER 4 S I N G L E - TA BL E QUERIES LEARNING OBJECTIVES Objectives Retrieve data from a database using SQL commands Use simple and compound conditions in queries Use the BETWEEN, LIKE, and IN operators

More information

Intermediate SQL: Aggregated Data, Joins and Set Operators

Intermediate SQL: Aggregated Data, Joins and Set Operators Intermediate SQL: Aggregated Data, Joins and Set Operators Aggregated Data and Sorting Objectives After completing this lesson, you should be able to do the following: Identify the available group functions

More information

Database Systems: Design, Implementation, and Management Tenth Edition. Chapter 7 Introduction to Structured Query Language (SQL)

Database Systems: Design, Implementation, and Management Tenth Edition. Chapter 7 Introduction to Structured Query Language (SQL) Database Systems: Design, Implementation, and Management Tenth Edition Chapter 7 Introduction to Structured Query Language (SQL) Objectives In this chapter, students will learn: The basic commands and

More information

Database Management Systems,

Database Management Systems, Database Management Systems SQL Query Language (3) 1 Topics Aggregate Functions in Queries count sum max min avg Group by queries Set Operations in SQL Queries Views 2 Aggregate Functions Tables are collections

More information

COSC 304 Introduction to Database Systems SQL. Dr. Ramon Lawrence University of British Columbia Okanagan

COSC 304 Introduction to Database Systems SQL. Dr. Ramon Lawrence University of British Columbia Okanagan COSC 304 Introduction to Database Systems SQL Dr. Ramon Lawrence University of British Columbia Okanagan ramon.lawrence@ubc.ca SQL Queries Querying with SQL is performed using a SELECT statement. The general

More information

Computing Basics Series. Internet Explorer 8 Basics SAMPLE

Computing Basics Series. Internet Explorer 8 Basics SAMPLE Computing Basics Series Internet Explorer 8 Basics Internet Explorer 8 Basics Page 2 2010 Cheltenham Courseware Pty. Ltd. All trademarks acknowledged. E&OE. No part of this document may be copied without

More information

Relational Database Management Systems for Epidemiologists: SQL Part I

Relational Database Management Systems for Epidemiologists: SQL Part I Relational Database Management Systems for Epidemiologists: SQL Part I Outline SQL Basics Retrieving Data from a Table Operators and Functions What is SQL? SQL is the standard programming language to create,

More information

Unit 3 Fill Series, Functions, Sorting

Unit 3 Fill Series, Functions, Sorting Unit 3 Fill Series, Functions, Sorting Fill enter repetitive values or formulas in an indicated direction Using the Fill command is much faster than using copy and paste you can do entire operation in

More information

Unit 3 Functions Review, Fill Series, Sorting, Merge & Center

Unit 3 Functions Review, Fill Series, Sorting, Merge & Center Unit 3 Functions Review, Fill Series, Sorting, Merge & Center Function built-in formula that performs simple or complex calculations automatically names a function instead of using operators (+, -, *,

More information

Objective 1: Familiarize yourself with basic database terms and definitions. Objective 2: Familiarize yourself with the Access environment.

Objective 1: Familiarize yourself with basic database terms and definitions. Objective 2: Familiarize yourself with the Access environment. Beginning Access 2007 Objective 1: Familiarize yourself with basic database terms and definitions. What is a Database? A Database is simply defined as a collection of related groups of information. Things

More information

SQL BASICS WITH THE SMALLBANKDB STEFANO GRAZIOLI & MIKE MORRIS

SQL BASICS WITH THE SMALLBANKDB STEFANO GRAZIOLI & MIKE MORRIS SQL BASICS WITH THE SMALLBANKDB STEFANO GRAZIOLI & MIKE MORRIS This handout covers the most important SQL statements. The examples provided throughout are based on the SmallBank database discussed in class.

More information

SQL functions fit into two broad categories: Data definition language Data manipulation language

SQL functions fit into two broad categories: Data definition language Data manipulation language Database Principles: Fundamentals of Design, Implementation, and Management Tenth Edition Chapter 7 Beginning Structured Query Language (SQL) MDM NUR RAZIA BINTI MOHD SURADI 019-3932846 razia@unisel.edu.my

More information