Re: Calculating percentages from COUNT?

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance



Thanks Marshall,

I don't really understand you (please forgive my newbie stumblings)

Do you mean do the total count in another query and then use that field in my original query?

Thanks,

Jason


Marshall Barton wrote:
Jay wrote:

I have a very simple Totals query which counts the number of enquiries for each customer, grouping by the customer field and counting the customerID field.

I want to be able to give the count as a percentage of the total number of enquiries. How do I do this?


Use a subquery to calculate the total count. set your
percent column to something like:

Count(*) / (SELECT Count(*) FROM table)

.



Relevant Pages

  • Re: Help with Crosstab Report
    ... The table that this query is run on gets populated using ADO - I have ... noticed that the Customer field is being padded with a space at the ... > If I remove the WHERE clause then the query returns the expected results ...
    (microsoft.public.access.reports)
  • Re: Help with Crosstab Report
    ... > The table that this query is run on gets populated using ADO - I have ... > noticed that the Customer field is being padded with a space at the ... >> If I remove the WHERE clause then the query returns the expected results ...
    (microsoft.public.access.reports)
  • RE: IIF STATEMENT
    ... just filter them out in your query. ... checkbox and IS NULL/IS NOT NULL for nulls in your WHERE clause. ... > have a customer field, and a check box indicating if a payment is promised. ... company A has promised to pay $100 on 06/01/05 and company B ...
    (microsoft.public.access.queries)
  • Show First 6 Characters
    ... I would like to show the first 6 characters of my customer field in my ... query, can anyone help ... ie Customer: Joe Bloggs ...
    (microsoft.public.access.queries)
  • Show first 6 characters
    ... I would like to show the first 6 characters of my customer field in my ... query, can anyone help ... ie Customer: Joe Bloggs ...
    (microsoft.public.access.queries)