Task 1: Opening and Copying the Northwind Database

Total Page:16

File Type:pdf, Size:1020Kb

Task 1: Opening and Copying the Northwind Database

UCL EDUCATION & INFORMATION SUPPORT DIVISION INFORMATION SYSTEMS

Access 2003

Using Access

Exercises Task 1: Opening and copying the Northwind database

The following exercises all involve using the Northwind database which is provided with Microsoft Access. The database is read only so in order to use it you will need to either: A: download an editable (not read only) copy from http://www.ucl.ac.uk/training/exercises.htm or B: create a copy of the database yourself.

A: Follow the steps below to open your downloaded copy of the Northwind database: To open the Northwind database:

1. Open the Microsoft Access application.

2. From the File menu select Open.

3. Open Northwind.mdb from wherever you saved it to.

4. Click OK to close the Northwind Traders screen.

5. Click on Display Database Window.

B: Follow the steps below to find, open and create a copy of the database. To open the Northwind database:

1. Open the Microsoft Access application.

2. From the Help menu select Sample Databases.

3. Select Northwind Sample Database. A dialogue box will appear telling you the database is ‘Read Only’.

4. Click OK.

5. Click OK to close the Northwind Traders screen.

6. Click on Display Database Window. To save the database so that you can make changes to it:

7. From the File menu select Properties.

8. Note the path to the database (under Location). On Cluster WTS this is P:\Microsoft Office\OFFICE11\SAMPLES. On most PCs it will be C:\Program Files\Microsoft Office\Office10\Samples.

9. Use Windows Explorer or My Computer to find the database.

10.Copy the database to a new location with the same name. Please copy the file labelled Northwind.mdb not Northwind.ldb.

11.Proceed as in A (above) to open the database. Note: The Save As function is not available for making copies of Microsoft Access databases. UCL Information Systems 2 2003Exercises UCL Information Systems 3 2003Exercises Task 2a: Data navigation and entry in tables

When navigating around the database, use the method indicated in brackets. 1. Open Northwind.mdb (see Task One). 2. Open the Customers table. 3. Go to the first field in the first record of your table. (using the keyboard.) What Country does the customer live in?

______4. Navigate to a new blank record. (using the navigation bar.) 5. Enter a new record as detailed below: Customer ID Company Name Contact Name Contact Title BALGR Big Al’s Groceries Al Malone Owner

Address City Region Postal Code Country Phone Fax 354 Rodeo Dr. Salt Lake City UT 12345 USA

Task 2b: Data navigation and entry in forms

1. Open Northwind.mdb if it isn’t already open (see Task One). 2. Open the Products form. 3. Go to the last record on the form (using the navigation bar.) What is the Unit Price of this product? 4. Go to a new blank record on the form. (using the navigation bar.) 5. Enter a new record as detailed below:

Product Name Supplier ID Category ID Quantity Per Unit Gumbo Mix New Orleans Cajun Delights Seafood 100 – 200g pkgs

Unit Price Units In Stock Units On Order Reorder Level Discontinued 50 103 0 100 Yes

6. Go back to the first record on the form (using the keyboard.)

UCL Information Systems 4 2003Exercises Task 3a: Data selection and editing in tables 1. Open the Products table. 2. Go to record number 35 and copy the contents of the cell containing Supplier. 3. Go to the first record and replace the contents of the cell containing Supplier with the copied data. 4. Close the Products table.

5. Open the Order Details table. 6. Select and delete all records with Order ID 10255. 7. Change the contents of the Quantity field in record number 50 to 40. 8. Use the Undo command to restore the original contents of the field.

Task 3b: Data selection and editing in forms 1. Open the Suppliers form. 2. Select record number 25. 3. Copy and paste record number 25 as a new record. Notice the Supplier ID for this new record. Why has it changed? 4. Modify the new record:  Replace the Contact Name with Guy Saint  Modify the Contact Title to Sales Manager. 5. Close the Suppliers form.

UCL Information Systems 5 2003Exercises Task 4a: Reorganising data in tables

1. Open Northwind.mdb if it isn’t already open (see Task One). 2. Open the Suppliers table. 3. Move the Contact Title column so that it is between Company Name and Contact Name fields. 4. Freeze the three columns mentioned above. Notice what happens to the Supplier ID column. 5. Scroll to the last field in any record to see the result of freezing the columns. 6. Hide the Contact Title and the Supplier ID columns. 7. Close the Suppliers table, saving the changes you have made.

8. Open the Customers table. 9. Change the width of the Contact Name column using the Best Fit method. 10. Sort the table by Contact Title in ascending order. 11. Notice that the Contact Name column is no longer wide enough to display all the data. Use the mouse to change the width so that all contact names are fully visible. 12. Close the Customers table.

13. Re-open the Suppliers table. 14. Unhide the Contact Title column. 15. Unfreeze the columns.

16. Open the Orders table. 17. Sort the records so that records are sorted by Employee and for each employee are sorted alphabetically by Customer. 18. Close all open tables.

Task 4b: Reorganising data in forms 1. Open the Products form. 2. Sort the products by name. 3. Scroll through the records to view the sorted results. 4. Close the Products form.

UCL Information Systems 6 2003Exercises Task 5a: Locating data in tables

Using filters and sorting: 1. Open the Products table. 2. Use a filter to display all Beverages with a unit price of more than $18. Note: do not include the dollar sign [$] in your criteria. 3. Sort the filtered records to check that your filter has worked. How many records are displayed? ______4. Modify the filter to show Beverages with a unit price of $18 or less. How many records are displayed now?

Using Find: 1. Open the Customers table. 2. Find a contact with the surname Camino. What is the record number? 3. Find a customer living in Brazil.

Task 5b: Locating data in forms Using Find and Replace: 1. Open the Customers table. 2. Replace the following:

Find Contacts with Contact Title: Change their Titles to:

Sales Agent Sales Associate

Accounting Manager Accounts Executive (unless they live in Brazil)

Using a filter: 3. Filter the records to display only customers who live in Brazil. How many are there? 4. Remove the filter.

5. Open the Employees form. 6. Find the record for the employee Michael Suyama. 7. Filter the records to display all employees who have worked at the company longer than Michael. 8. How many staff are there in your result? 9. What criterion did you use to display the records?

UCL Information Systems 7 2003Exercises Exercise 6: Advanced filter and criteria 1. Open the Northwind database and open the Products table. 2. Select Filter from the Records menu, then select Advanced Filter/Sort:  For the first level of sort, sort in ascending order of the CategoryID field.  For the second level of sort, sort in descending order of the UnitsInStock field. 3. Check the results then reset the table. 4. Close the Products table. Do not save your changes.

5. Open the Orders table. 6. Use the Advanced Filter/Sort feature to select London and Paris in the Ship City field. Sort the Order Date field into descending order for London and for Paris. 7. Remove the filter to reset the table. 8. Use the Advanced Filter/Sort feature to select all the records with a Shipped Date between 01-Nov-97 and 30-Nov-97. Access should find 36 records. 9. Check the results then reset the table. 10. Use the Advanced Filter/Sort feature to select all the records with an Order Date which is greater than or equal to 01-Jan-98. Access should find 270 records. 11. Check the results then reset the table and close the table without saving.

UCL Information Systems 8 2003Exercises Extra Exercise - Revision 1. Open the Northwind database and open the Suppliers table. 2. Move the Country field to the far left of the table (make it the first column). Make the City field the second field in the table. 3. Search for Ltd in the Company Name field and replace it with plc. 4. Check record 10 and ensure the company name is still Refrescos Americanas LTDA, ie, check that LTDA has not been changed to PLCA. 5. Apply a filter where the criteria is all the contact names starting with Ch. How many records are there? Remove the filter. 6. Hide the Phone and Fax fields. 7. Change the row height to 16. 8. Remove the horizontal gridlines. 9. Change the colour of the background and the vertical gridlines. 10. Change the font and change the point size to 12. 11. Apply a filter for all records where the country is USA, listing the result in alphabetical order of City. Which is the last city? 12. Use Best Fit to set the width of the columns. 13. Print preview. 14. Change the paper orientation to landscape and ensure the Paper Size is set to A4. How many pages are there? 15. Change the left and right margins to 0.5" (1.27cm). 16. Change the font to Arial Narrow and point size to 11. 17. Use the Best Fit option again to change the Column Width. 18. Check to ensure the Phone and Fax fields are still hidden. 19. Check again in Print Preview. How many pages are there? 20. Print one copy. 21. Remove the filter and unhide the phone and fax fields. Close the Table without saving your formats. 22. Open the Orders table. 23. How many records have the employees with surname King and are shipping Via "Speedy Express"? 24. Remove from the view of the table, all the records where the Ship Country is France, Germany, or Italy. How many records are left? Remove the filter. 25. List all the records that do not contain a Ship Postal Code. How many are there? 26. Remove the filter and close the table without saving.

UCL Information Systems 9 2003Exercises

Recommended publications