Results 1 to 5 of 5
  1. #1
    Bentley is offline Advanced Beginner
    Windows 7 64bit Access 2010 32bit
    Join Date
    Jun 2016
    Posts
    50

    Dividing two fields by row in a query for a percentage

    Hello,



    I am creating a query that requires dividing two fields that are not number or currency based. I have set up counts for each field, however, I do not know the expression to achieve the percentage when trying to divide the counts from the two fields by row.

    Any suggestions?

    Bentley

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,549
    in the query: Pct: [field1]/[field2]
    format the cell or report box for percent.

  3. #3
    Bentley is offline Advanced Beginner
    Windows 7 64bit Access 2010 32bit
    Join Date
    Jun 2016
    Posts
    50
    I understand that part. Where the issue lies is counting non text fields, I have two fields that need counts then divide those numbers to get the percentage. I have names of workers and want to divide the type of task performed by the count of passed.

  4. #4
    John_G is offline VIP
    Windows 7 32bit Access 2010 32bit
    Join Date
    Oct 2011
    Location
    Ottawa, ON (area)
    Posts
    2,615
    What are the expressions you have used to get the counts, and do you have aliases for them?

    Are you using a totals query?

  5. #5
    Bentley is offline Advanced Beginner
    Windows 7 64bit Access 2010 32bit
    Join Date
    Jun 2016
    Posts
    50
    I used a duplicate of each field (for the counts). I switched to a totals and changed the total to expression. This seemed to fix it.

    Thanks,

    Ben

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 2
    Last Post: 02-11-2013, 01:26 PM
  2. Replies: 10
    Last Post: 10-19-2012, 05:10 AM
  3. Replies: 1
    Last Post: 10-09-2012, 09:08 AM
  4. Add fields and find percentage
    By gurp99 in forum Queries
    Replies: 1
    Last Post: 08-09-2010, 03:57 PM
  5. Help dividing two fields in a query
    By aronnov in forum Access
    Replies: 2
    Last Post: 04-29-2010, 12:34 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums