Hi, guys today we talk about how to create database table in Ms Access. A database is a collection of information like tables, query, form and reports which are related to each other. Ms-Access allows you to manage your important information in single database file. The default extension of Ms Access 2007 & above is .accdb. This takes the place of the MDB file extension.
Ms Access database have four major parts in : Tables, Queries, Forms and Reports.
- Tables store your data in your database
- Queries ask questions about information stored in your tables
- Forms allow you to view data stored in your tables
- Reports allow you to print data based on queries/tables that you have
To create database table in Ms Access:
Start Ms Access either by clicking Start -> All Programs -> Microsoft Office -> Microsoft Office Access 2007 or Press WIN+R key to open run dialog box then type ms access then press enter key.
1. Select Blank Database
2. In the File Name box enter a name for the database
3. Now click Create button.
Microsoft Access automatically creates a new table in the database called Table1. This is a temporary name until the table is saved.
Understanding the Views
There are 2 basic views when you work in a table: Design View and Datasheet View.
1. Design View is used to set the data types, insert or delete fields, and set the Primary key.
2. Datasheet View is used to enter the data for the records. By default, Ms-Access places you in Datasheet View.
To Switch to Design view:
1) Click the View button on the Home Ribbon
2) Type a name for the table
3) Click OK
It takes your control in table creation window in Table Tools -> Design Tab. In this window you have to give Field Name, Data Type and Description of table in current database. Before creating the table we have to know about data types. Now you have to insert fields in the table of active database:
1) Type a name for the first field in the table then press enter key.
3) Now select a data type as per requirement.
4) Type any description for the field if required then press enter. Now continue this process until all required fields have been entered into the table.
Note: The order that you enter the field names is the order the fields will appear in the table and on a form.
The Primary Key is the unique identifier for each record in a table. Microsoft Access can not accept duplicate entries in the Primary field. MS Access by default sets the first field in the table as the Primary Key field.
How To Set a Primary Key:
1. Switch to Design View.
2. Position your cursor in the field you wish to set as the Primary Key.
3. Click the Primary Key button on the Ribbon
To enter records in table:
Once you have entered the fields and set the data types it is now time to enter the records in a table. Click Design Tab -> View option -> Click Datasheet View. When you feed data into the table, Ms- Access automatically saves the data after each new record.
Now press Ctrl+ W key to save and close active table in database. Now double click to again open to view, modify the records.
Use the following given arrows at the bottom of the table to navigate among records.
Sorting Records in a Table
Sorting is the process to arrange all records in ascending or descending format as per requirement on any particular column or field. 1. To sort records in a access table, position your cursor in the field that you wish to sort by, by clicking on any record in that field. 2. Click either the Sort Ascending or Sort Descending icon
I hope you like this create database table in Ms Access guide from which you will be able to easily create database table in Ms Access without any extra efforts. If feel any problem in this guide then please use comment box. Thanks to all.