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

Report Percentage Calculation - HELP

Status
Not open for further replies.

TheBlade

MIS
Aug 12, 2001
29
NZ
I have a report with 30 fields per record (each has a numeric value from 1-5). What I want to do is calculate the total percentage of record fields that are <3. Anybody have an idea on the best way to do this in the report? it is difficult to do in a query, cos I'd have to specify criteria for each field and there isn't enough room to do this for all of them.

Thanks in advance!

TheBlade
 
I would create a cross-tab query based off the table- arranging the columns into rows. Then query the cross tab as the data source for the report.
 
Hi there. I am not familiar with crosstab queries. Can you please be a bit more specific?

thanks!
 
Please forgive me I read your post a little fast- I thought you were converting rows into columns- that's what a crosstab query does. If you ever get curious there is a wizard for it when you click the new button to make a new query. As for converting columns into rows (which is what I was thinking of) I don't know of an easy way to do it. How many rows are you returning with the query now? And what kind of criteria are you using?
 
Hi Pezamystik.

I have solved the problem now, although it was a little long winded. I created a query that did a dcount statement for each field to extract the number of <3 records for each field. A 2nd query added them all up and divided them by the total # of records X total # of fields.

cheers

TheBlade
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top