Database Journal
MS SQL Oracle DB2 Access MySQL PostgreSQL Sybase PHP SQL Etc SQL Scripts & Samples Links Database Forum

» Database Journal Home
» Database Articles
» Database Tutorials
MS SQL
Oracle
DB2
MS Access
MySQL
» RESOURCES
Database Tools
SQL Scripts & Samples
Links
» Database Forum
» Sitemap
Free Newsletters:
DatabaseDaily  
News Via RSS Feed


follow us on Twitter
Database Journal |DBA Support |SQLCourse |SQLCourse2
 

Featured Database Articles

MS Access

Posted Oct 6, 2003

MS Access for the Business Environment: Reporting in MS Access: Grouped Transactional Report Part II - Page 3

By William Pearson

Set up Sorting and Grouping of Data in the Report

We are ready to sort our data. MS Access requires that we do so before we can define groupings. Keep in mind that any sorting in the source query will be irrelevant.

1.  Select View --> Sorting and Grouping from the main menu in the Design View.

The Sorting and Grouping dialog appears.

2.  Click the top row within the Field/Expression column.

3.  Click the selector arrow that becomes visible.

A list of fields in the Customer_Orders_Source query appears.

4.  Select the CustomerID field in the list.

5.  Leave the Sort Order column setting at the default of Ascending.

6.  Click the Group Header field below the Field/Expression and Sort Order grid in the dialog (in the Group Properties section of the dialog).

7.  Using the down arrow in the Group Header field, select Yes to group on CustomerID.

8.  In the same manner, select Yes in the Group Footer field immediately underneath the Group Header field.

9.  Leave the remaining Group Properties at default.

10.  Select the OrderDate field for the Field/Expression column of the next row.

11.  Leave the Sort Order column setting, again, at the default of Ascending.

12.  Click the Group Header field below the Field/Expression and Sort Order grid in the dialog.

13.  Using the down arrow, select Yes to group on OrderDate.

14.  In the same manner, select Yes in the Group Footer field immediately below.

15.  Leave the remaining group properties at default.

The Sorting and Grouping dialog appears as shown in Illustration 6.


Illustration 6: Sorting and Grouping Dialog, with Settings

16.  Close the Sorting and Grouping dialog.

The report again appears in an empty state, although our recent settings have been applied. The telling difference, however, is the appearance, as seen in Illustration 7 (partial view), of the Header / Footer sections for the CustomerID and ShippedDate fields.


Illustration 7: The Report with Header / Footer Additions (Partial View)

Having accomplished the preliminary group and sort criteria, we will begin the process of bringing data into our currently blank report.



MS Access Archives

Comment and Contribute

 


(Maximum characters: 1200). You have characters left.

 

 




Latest Forum Threads
MS Access Forum
Topic By Replies Updated
Help With Microsoft Access kasy 0 September 4th, 07:35 PM
Linked table not sorting or filtering - ODBC error Java 1 August 28th, 10:37 AM
Use Parameter in select statement (Sql in Microsoft Access) katty.jonh 1 July 25th, 06:45 AM
Query Issue algebroni 7 July 23rd, 04:22 PM


















Thanks for your registration, follow us on our social networks to keep up-to-date