Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to show certain #s of records in a report????

Status
Not open for further replies.

jinglin

MIS
May 4, 2004
72
US
I have a report which shows the OrderID,PIN#, DateCreated,etc...
The report is grouped by PIN# bounded to TableA. But I only need the report to show 3 most recent records for each grouped PIN#(based on DateCreated).
How am I going to do it?
Please advise!

Thanks!
Jinglin
 
Instead of basing the report off the table, you will need to create a query that contains the records you want and make that the record source of the report.

If you post some info about your table, someone here can help you create the query that you need.

Leslie


 
Yes, I did the report based on the query, and I used DateCreated field to sort by descending, which will show most recent records...
I created the report by grouping PIN#.
e.g. PIN# 1003-5 will get as many as 10 records out on the report, but I only need 3 out of 10---most recent ones.
Hope this can help you help me out!

Thanks!

Jinglin
 
I might be underestimating the issue since I don't work with reports much, but have you tried to go to your query properties and select:

top values: 3

Then add a sort into the query Decending by whatever date you are using?




Dominus Nihil
(Master of Nothing)
 
Yes, I used top values in PIN# field, and sorted DateCreated field by descending, but still not working the way I wanted.
Thanks anyway.

Jinglin
 
This problem has been solved by Duane in Access Report forum. Please check it out if necessary.

Jinglin
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top