جاوا اسکریپت غیر فعال است برای تجربه بهتر، قبل از ادامه، جاوا اسکریپت را در مرورگر خود فعال کنید.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser .
آموزش کامل Access 2003-En
[h=2]Editing Form Records
[h=3]Challenge!
Open the Contact Management database.
Display the Contacts form and use the Status area to display each record shown.
Change the Contact Type of each contact record to that indicated below:
Assign a "Company" Contact Type for the John Smith record
Assign a "Friend" Contact Type for the Michelle George record
Assign a "Friend" Contact Type for the Martha Brinson record
Add make-believe Mobile Phone numbers and Email Name for any record(s) missing this information.
Display the John Smith record.
Click the Calls button on the Contacts form to open the Calls table.
In the Subject field, type: "Redesign"
In the Call Notes field, type: "Reviewed possible plant redesign. Waiting for quote."
Save and close the database.
[h=2]Sorting Records
[h=3]Introduction [h=4]By the end of this lesson, learners should be able to:
Review table records and form records concepts
Perform a multi-field sort
[h=2]Sorting Records
[h=3]Sorting Records to Find Information
Sorting is one method that helps you find information quickly and easily in a database. Records
can be sorted in
ascending order (A-Z) , and
descending order (Z-A) . You can sort by zip
code, last name, first name, company, contact type (e.g., family, friend, relative), etc. You can
even sort by contact type and then by last name within each contact type.
It's easiest to see the
results of a sort if you work in
Datasheet View .
[h=2]Sorting Records
[h=5]To Sort Records:
Open the desired form or table (e.g., Contacts table).
Choose View
Datasheet View from the menu bar if Datasheet View is not already displayed.
Click anywhere in the column you want to sort by (e.g., Last Name).
Click the Ascending or Descending button on the toolbar (or choose Records
Sort
Sort Ascending or Sort Descending from the menu bar).
To sort by
Form View , switch to Form View, select the field you want to sort by, and
click the
Sort button on the toolbar. To see the results, use the status area to move through the records.
[h=2]Sorting Records
[h=3]Performing a multi-field sort
Multi-field sorting allows you to define multiple fields in your sort. You specify the column
to sort by, (e.g., Last Name), and within that column sort by some other specified field
(e.g., First Name). For example, you could sort all the Brown records by first name.
[h=2]Sorting Records
[h=5]To Sort by Multiple Fields:
Open the desired form or table in Datasheet View.
Move the columns to be included in the sort so they are positioned alongside one another.
Moving a column in Access is much like moving a column in Excel . Click in the column
heading of one field to highlight the entire column. Then, drag the entire column so that it sits alongside the other column(s) to be used in the sort.
The column to be sorted first should be positioned to the left of the second column to be sorted, and so on.
Select all fields (columns) involved in the multiple sort process.
Click the
Ascending or
Descending button on the toolbar to sort the records (
or choose
Records
Sort
Sort Ascending or
Sort Descending from the menu bar).
Multiple field sorts cannot be performed in
Columnar or
Tabular Form View .
[h=2]Sorting Records
[h=3]Removing a Sort
After a sort is performed, you will be given the option to save the sort or to remove it to allow
the records to return to the way they were ordered before you applied the sort.
[h=2]Sorting Records
[h=5]To Remove the Sort Order:
Choose Records
Remove ******/Sort from the menu bar.
The records revert to their ordering before the sort was applied.
If you add new records to a table that has been sorted, any new records are
automatically saved .
[h=2]Sorting Records
[h=3]Saving a sort
When you open a table in Access -- any table -- the records are displayed in order based
on values that appear in the primary key field. In other words, Access defaults to a sort on
the primary key when a table is opened. A sort can be performed against any field listed in
a table, however. Sorting table records actually change the table design. When you attempt
to close a table after a sort, Access will prompt you to save the changes to the table design.
[h=2]Sorting Records
[h=5]To save a sort:
Exit the table
Click the Yes button in response to the question, Do you want to save changes to the table?
The sort order is saved . When you open the table again, the records will still be sorted.
[h=5]To cancel a sort:
Exit the table
Click the No button in response to the question, Do you want to save changes to the table?
The change is not saved; the table remains in its original design.
[h=2]Sorting Records
[h=3]Challenge!
Open the Contact Management database.
Open the Contacts table in Datasheet View.
Perform the following single-field sorts :
Sort (descending or ascending) the records by the Last Name field.
Sort (descending or ascending) the records by the State/Province field.
Sort (descending or ascending) the records by the Contact ID field.
Perform the following
multi-field sorts :
Move the City field to the right of the State field and sort (descending or ascending) the records by State and City .
Move the City field to the right of the Last Name field and sort (descending or ascending) the records by Last Name and City .
Remove the last sort performed
Cancel the sort when you close the Contacts table, and click the NO button in
response to the Do you want to save changes to the design of table 'Contacts' system prompt.
[h=2]Finding Records
[h=3]Introduction [h=4]By the end of this lesson, learners should be able to:
Use a wildcard to find a record
[h=2]Finding Records
[h=3]Performing a Simple Find
When you have an extremely large database consisting of thousands of records, you may
need to quickly locate one of them. Access provides an easy way to find individual records: the Find function .
[h=2]Finding Records
[h=5]To use the Find Function:
Click anywhere in the field that contains the data you want to search (e.g., Last Name).
Choose Edit
Find on the menu bar or click the Find button on the toolbar to open the Find and Replace dialog box.
In the Find What field, type the information you want to search. It may be a last name (e.g., Manning) or a portion of the last name (e.g., Man).
The Look In drop-down box defaults to the field or column where the cursor was
positioned when the Find was initiated. You can leave the definition as is if you know the information is contained in this field, or you can select search the entire
table from the drop-down menu list.
In the Match field, Access defaults to Whole Field but you can optionally select either Any Part of Field or Start of Field .
Click the Find Next button to search for the first occurrence of a record that matches the search.
[h=2]Finding Records
[h=3]Performing a Simple Find (continued)
Click the Cancel button if the record was found. The Find and Replace dialog box will close.
OR
Click the Find Next button to search for the next record that meets the Find criteria.
In the event that Access did not find a match for the search, the Office Assistant will pop
up to inform you that there were not any matched records found.
[h=2]Finding Records
[h=3]Using Wildcards to find records
If the simple Find did not find the record you sought then you can try typing an
operator in the
Find What text box of the
Find and Replace dialog box. A common
Access operator is a
wildcard , a symbol representing one or more characters.
Wildcard Usage
Example *
(Asterisk) Used at the beginning or the end of a search string to match one or more characters
Sch* finds Schlotz and Schwartz. *ing finds Wheeling and Browning.?
(Question Mark) Matches any single alphabetic character
Sp?ll finds spell and spill. #
(Pound Sign) Matches any single numeric character
9#1 finds 901, 911, 921, etc.
[h=2]Finding Records
[h=5]To Search for a Record Using a Wildcard:
Choose Edit
Find on the menu bar or click the Find button on the toolbar to open the Find and Replace dialog box.
In the Find What field, type the wildcard combination (e.g., B*) to find the first record where the Last Name begins with the letter B.
Click the Find Next button to begin the search. The first record found that matches the search is highlighted.
(The Office Assistant will provide notification if no matching records were found).
Click the Cancel button if the record was found. The Find and Replace dialog box will close.
OR
Click the Find Next button to search for the next record that meets the Find criteria.
[h=2]Finding Records
[h=3]Challenge!
Open the Contact Management database.
Open the Contacts table in Datasheet View.
Perform a Find Next function against the Contacts:Table Look In field to locate the William Henderson record.
Perform a Find function against the Contacts:Table Look In field and using an A* wildcard combination to locate the first record.
Perform and repeat a Find Next function against the same wildcard combination as you move your way throughout the records in the database.
Close the Contacts table and, if displayed, click the NO button in response to the
Do you want to save changes to the design of table 'Contacts' system prompt.