Percentage of total

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

How would I add another field to this query to calculate the percentage of
each doctype out of total docs?

TIA

SELECT qryPOExtended.DocType, tblDocType.Description,
DocCount(qryPOExtended.DocType) AS CountOfDocType
FROM tblDocType INNER JOIN qryPOExtended ON tblDocType.DocType =
qryPOExtended.DocType
WHERE (((qryPOExtended.PurGroupArea)="OPS Buying") AND
((qryPOExtended.Month) Between [Month From] And [Month To]))
GROUP BY qryPOExtended.DocType, tblDocType.Description;
 
Hi,


Can't you divide by DCount( ... ) or by (SELECT COUNT(*) FROM ... )
.. DCount will only work with Access+Jet.


Hoping it may help,
Vanderghast, Access MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top