How to set up a database in Microsoft Access



Similar documents
Setting up a basic database in Access 2007

Microsoft Access XP Session 1 Week 8

Setting up a basic database in Access 2003

Microsoft Access 2000

Introduction to Microsoft Access 2013

Lab 9 Access PreLab Copy the prelab folder, Lab09 PreLab9_Access_intro

Introduction to Microsoft Access 2010

Creating a Database in Access

Utilizing Microsoft Access Forms and Reports

Using Microsoft Access

Using Microsoft Access Databases

Learning Services IT Guide. Access 2013

MICROSOFT ACCESS A. CREATING A DATABASE B. CREATING TABLES IN A DATABASE

Introduction to Microsoft Access 2007

Instructions for Formatting MLA Style Papers in Microsoft Word 2010

In this example, Mrs. Smith is looking to create graphs that represent the ethnic diversity of the 24 students in her 4 th grade class.

What is a database? The parts of an Access database

Microsoft Access 2007 Module 1

Creating tables in Microsoft Access 2007

Basic Formatting of a Microsoft Word. Document for Word 2003 and Center for Writing Excellence

MS Access Lab 2. Topic: Tables

If the database that is required is similar to a template then whole database can be generated by using a template that already exists.

Creating a Database using Access 2007

Access I Tables, Queries, Forms, Reports. Lourdes Day, Technology Specialist, FDLRS Sunrise


Microsoft Access 2010 Part 1: Introduction to Access

MS Access: Advanced Tables and Queries. Lesson Notes Author: Pamela Schmidt

Use Find & Replace Commands under Home tab to search and replace data.

HOW TO PAGE A DOCUMENT IN MICROSOFT WORD

Search help. More on Office.com: images templates. Here are some basic tasks that you can do in Microsoft Excel 2010.

Creating a Newsletter with Microsoft Word

Creating a Form. A form is something that is created allowing users to enter information in a more visual manner than a datasheet view.

MICROSOFT ACCESS STEP BY STEP GUIDE

Table and field properties Tables and fields also have properties that you can set to control their characteristics or behavior.

Check out our website!

Creating Personal Web Sites Using SharePoint Designer 2007

Steps to Create a Database

Utility Software II lab 1 Jacek Wiślicki, jacenty@kis.p.lodz.pl original material by Hubert Kołodziejski

Microsoft Access Basics

Instructions for Formatting APA Style Papers in Microsoft Word 2010

A database is a collection of data organised in a manner that allows access, retrieval, and use of that data.

Microsoft Access 2010 Overview of Basics

A More Advanced Database Illustration Access 2010

How To Understand The Basic Concepts Of A Database And Data Science

Excel 2003 A Beginners Guide

Access Creating Databases - Fundamentals

Microsoft Using an Existing Database Amarillo College Revision Date: July 30, 2008

Excel 2007 A Beginners Guide

IST 195 Lab 11: MS Access

Click on various options: Publications by Wizard Publications by Design Blank Publication

MICROSOFT ACCESS 2003 TUTORIAL

ECDL. European Computer Driving Licence. Database Software BCS ITQ Level 1. Syllabus Version 1.0

MICROSOFT ACCESS 2007 BOOK 2

To launch the Microsoft Excel program, locate the Microsoft Excel icon, and double click.

Microsoft Access 2010

Creating an Access Database. To start an Access Database, you should first go into Access and then select file, new.

Ohio University Computer Services Center August, 2002 Crystal Reports Introduction Quick Reference Guide

Creating a Gradebook in Excel

Microsoft. Access HOW TO GET STARTED WITH

To reuse a template that you ve recently used, click Recent Templates, click the template that you want, and then click Create.

Instructions for applying data validation(s) to data fields in Microsoft Excel

How to make a line graph using Excel 2007

Microsoft Access 2007

Advanced Word for Windows

Step-by-Step Instructions for Setting Up a Paper in APA Format

To successfully initialize Microsoft Outlook (Outlook) the first time, settings need to be verified.

Installing Remote Desktop Connection

Databases in Microsoft Access David M. Marcovitz, Ph.D.

MICROSOFT OUTLOOK 2010 WORK WITH CONTACTS

BID2WIN Workshop. Advanced Report Writing

User Services. Microsoft Access 2003 II. Use the new Microsoft

GCSE Database Projects in Access

Making an online form in Serif WebPlus

Lesson 07: MS ACCESS - Handout. Introduction to database (30 mins)

Microsoft Expression Web

Reduced Quality Sample

PowerPoint 2007 Lesson 1: Getting Started

IN THIS PROJECT, YOU LEARN HOW TO

Lab Manual. Databases. Microsoft Access. Peeking into Computer Science Access Lab manual

A Guide To Using. Box-Office Version 2. By Nortech Software. The main booking screen

Microsoft PowerPoint 2010 Computer Jeopardy Tutorial

Appendix A How to create a data-sharing lab

Business Objects. Report Writing - CMS Net and CCS Claims

Access Database 2003 Basics

Microsoft Access 2010: Basics & Database Fundamentals

Microsoft Outlook Introduction

Avery Wizard: Using the wizard with Microsoft Word. This is a simple step-by-step guide showing how to use the Avery wizard in word

Converting an Excel Spreadsheet Into an Access Database

Workspaces Creating and Opening Pages Creating Ticker Lists Looking up Ticker Symbols Ticker Sync Groups Market Summary Snap Quote Key Statistics

Creating and Using Databases with Microsoft Access

MS Word 2007 practical notes

Consider the possible problems with storing the following data in a spreadsheet:

Database Database Management System (DBMS)

Setting Up APA Format (Page and Header) for PC s. Step 1 (Preparing the Pages)

CAPITAL V8. Capital Business Software Tutorial Series. Introduction to Capital Business Manager V8 User Interface 1.2

Creating and Using Forms in SharePoint

Microsoft Access Rollup Procedure for Microsoft Office Click on Blank Database and name it something appropriate.

Using Excel for your assignments

Transcription:

Contents Contents... 1 How to set up a database in Microsoft Access... 1 Creating a new database... 3 Enter field names and select data types... 4 Format date fields: how do you want fields with date data type displayed?... 5 Format currency fields: How do you want fields with currency data type displayed?. 6 To set up a primary key... 7 Changing the length of a text field in Microsoft Access... 8 Validation Rules: Pull-down lists (file lookup)... 9 Validation Rules: Picture (Format) Checks... 11 Validation Rules: Presence Checks... 12 Validation Rules: Range Checks... 13 Validation Rules: Uniqueness Checks... 14 Entering data into a database... 15 How to create a form in Microsoft Access... 17 How to set up a database in Microsoft Access Create a New Database Enter field names and select the data types Format fields with date/time and currency data types Set up a primary key Chose field lengths for all the text fields Set up validation rules Enter the data into your database 1

2

Creating a new database Open up Microsoft Access. Go to the File Menu and select New. Then click on Blank Database. Give the database a sensible name, when asked, and then click on Create The database manager window will now appear (shown in the picture on the left). Click on Create table in Design View and you will be able to start setting up your database. 3

Enter field names and select data types Put the name of the field in this column and then select the desired data type from the pull down list. The data type text lets you enter any mixture of characters (letters, numbers and special characters like?!@:;,-) The data type number only allows numeric data. If you go to format you can select integer (whole numbers only) or decimal (sometimes called real numbers numbers with a decimal point in them) The data type yes/no is what Access calls Boolean fields there are only two possible values Yes and No. You can also select data types like dates, times and currency (money) if these are needed in your database. 4

Format date fields: how do you want fields with date data type displayed? You can chose how you would like a date to be shown e.g. 1 st June 2006, or 01/06/2006 or 01-Jun-06. To do this select the field which has a date/time data type and then go to Format and select your preferred option from the pulldown list. In the example shown above the Date of Birth is being set up to have the Short Date Format. 5

Format currency fields: How do you want fields with currency data type displayed? You can chose how you would like a currency field to be shown e.g. 1000, or $1750 or 1000.00. To do this select the field which has a currency data type and then go to Format and select your preferred option from the pull-down list. In the example shown left the Hourly Wage is being set up to be in s. You can then chose how many decimal places you want shown (select 2 if you want the pennies shown, 0 if you want to have the value in pounds only) 6

To set up a primary key A primary key is a field that is unique for every record. Select the field that you want to make the primary key and then click on the key icon. If you want to set up a composite primary key (make several fields together be the primary key because there is not a field that is unique on its own) select all the fields that will be part of the composite key and then click on the key icon. Note: to select several fields hold down the ctrl button on the keyboard while you use the mouse to select all the fields. If you do not set up a primary key then Access sometimes creates one for you and calls it ID. 7

Changing the length of a text field in Microsoft Access Select the field and then in field size type in the length (maximum number of characters you want to allow the user to type in to the field). In this example the surname field has had its length (field size) set to 30: 8

Validation Rules: Pull-down lists (file lookup) In this example we are going to look at how to set up a pull-down list. In a database about students we want to make sure that only male and female can be typed into the gender field. Select the gender field and make the data type text. Then change the data type to lookup wizard. Select I will type in the values I want and then click on Next. If you make a mistake at any time click on Back to go back to the last screen. 9

Type in the items that will be in the list, as shown in this picture and then click on finish. Then click on the Lookup tab and select Limit to List. Type in Yes. If you do not do this last bit then there will be a pull-down list that the user can select from but they could also type in whatever they like. 10

Validation Rules: Picture (Format) Checks Sometimes the data in a field must have a certain pattern e.g. National Insurance Numbers and Postcodes. In this example we are going to set up a format check on National Insurance. All NI Numbers start with 2 letters then have 6 numbers and finally a letter. Select the NI Number field and then in input mask type: LL 00 00 00 L An L means that something must be a letter, a 0 (zero) that something must be a number. The next screenshot shows a slightly more complex input mask that has been set up for a postcode, where the data entered must match one of four possible formats. It is also possible to use input masks to make sure that the data entered has upper or lower case letters, or characters other than letters & numbers in certain positions (e.g. you could use an input mask to ensure that an e-mail address has an @ symbol in it). 11

Validation Rules: Presence Checks In this example we are going to look at how to set up a presence check. A presence check makes sure that data is entered in a field (it cannot be left blank). In a database about students we want to make sure that every student has a name. Select the name field. Then where it says Required type in: Yes Where is says Allow Zero Length type in: No 12

Validation Rules: Range Checks In this example we are going to look at how to set up a range check. For a field called Mark on Test we want to make sure that only numbers between 0 and 100 are entered. First of all make the data type Number Then where it says Validation Rule type in: >=0 and <=100 (This means must be greater than or equal to 0 and less than or equal to 100). Note: To make a field be greater than 0, you would have typed in >0 where it says Validation Rule. 13

Validation Rules: Uniqueness Checks MS Access automatically makes a field you set-up as a primary key have a uniqueness check. If there are any other fields that you want to set up a uniqueness check for then select the field and then: Change the indexed property to say Yes (No Duplicates). 14

Entering data into a database When you have finished setting up the database click on this icon: You will be asked to save the table, give it a sensible name. Your screen will now look like this: You can now type in the data. When you have finished typing in the data click on the cross to close the table. 15

The database manager will now look like the picture above. Double click on the table name if you want to add more data to your database. If you want to change the setup of the database then select the table name and then click on design. Instead of typing the data into the table directly you could create a form and use the form to enter the data. A form is a more userfriendly way of entering data into a database. 16

How to create a form in Microsoft Access Click on Forms tab on the database window. Select Create Form by Using Wizard. Click on the double arrow to move all the fields from available fields to selected fields. Then click on Next. Select the layout you would like here justified has been selected then click next. 17

Then select the style you would like your form to be in here standard has been selected and then click on next. Finally, give your form a name and click on finish. The finished form is shown below you can now use this form to type in more information to your database. The arrows at the bottom of the form can be used to move between records and to add a new record. All the data that you enter using your form will automatically be added to your table. Clicking on this icon (in the top-left corner) will take you to the design view of the form where you can move fields around, change colours, insert pictures etc... Example: to change font colour right click on the field and select properties. 18