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

Summing Rows of Crosstab Query

Status
Not open for further replies.

ImASig

Technical User
Jul 24, 2000
20
US
I have a parameter query with MACHINES as my column heading and DATE as my row heading. The value is the amount of money a machine makes on a particular date. I need to know how to get the sum of the money a machine makes for a range of dates. So I either need to sum the entire row of a machine for each date or just get one column for the range of dates instead of each individual date having it's own column. Any help would be great.
 
I have to be honest I am not real sure what you are doing here. You say you are doing a parameter query but you seem to describe a crosstab query. If all you want is the amount between dates I suggest you look at the dsum() function. It works kinda like.

dsum("fieldname","tablename","datefield between #date1# and #date2#")
good luck

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top