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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Report Help

Status
Not open for further replies.

Tarbuza

Technical User
Dec 13, 2000
56
US
Employee

Id
Name
Div_Code
Dept_Code


Inventory

Employee_Id
Inventory_Id
Type
Lease_No

Inventory type can be Hardware, Software or Miscellaneous.

Lease

Lease_No
Start_date
End_date

Report format

Division Code: xxxxxxxxxx

Departement Code:xxxxxxxx

Lease_No Start_dt End_dt #of Hardware # of Sofware


Total by Dept Code for Hardware and Software
Total by Division Code for Hardware

I am making a report through query. How can I get # of Hardware and Software based on Lease # in the above report? Thanks for help.
 
Don't put Lease Number in the detail section of the report, use another grouping (like with Division Code and Department Code). Then in the Lease Number footer you can do the same thing you're doing in the Dept Code and Division Code footer to get the count of records (something like Count(IIf([type]="Hardware",[type])) to find the count of hardware...and then the same for software). Hope that helps.

Kevin
 
I am getting the following error message when I use Count(IIf([type]="Hardware",[type])) .

Aggregate functions are only allowed on output fields of the record source.

Thanks for your help.
 
I would create a totals query or queries that calculate the values and then include these queries in subreports on the main report.

Duane
MS Access MVP
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top