Results 1 to 3 of 3
  1. #1
    jrg24 is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Apr 2014
    Posts
    17

    Totals on Union Query and Crosstab Query Do not match


    I ran a union query to compile a list of costs. I then ran a crosstab query on this union query. I used the "Totals" function in Access to check the totals of both queries to see if they match. The do not. The union query total is less than the crosstab but some how the crosstab query result matches what I know to be on the source data. The union query converts all amounts to currency. Does anyone know why this would be?

  2. #2
    rpeare is offline VIP
    Windows XP Access 2003
    Join Date
    Jul 2011
    Posts
    5,442
    I seriously doubt the conversion to currency is the issue. If you're using ccur(<value>) you shouldn't have an issue, if you're using format(<value>, "Currency") you should still be fine though it may be treating the value like a string after the conversion (I haven't done any real testing to see if it's similar to format(<value>, "Short Date") where the <value> would be treated like a string after the conversion rather than a date).

    Perhaps post your SQL statements or create a sample database that has enough fake information in it to re-create the problem.

  3. #3
    jrg24 is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Apr 2014
    Posts
    17
    Quote Originally Posted by rpeare View Post
    I seriously doubt the conversion to currency is the issue. If you're using ccur(<value>) you shouldn't have an issue, if you're using format(<value>, "Currency") you should still be fine though it may be treating the value like a string after the conversion (I haven't done any real testing to see if it's similar to format(<value>, "Short Date") where the <value> would be treated like a string after the conversion rather than a date).

    Perhaps post your SQL statements or create a sample database that has enough fake information in it to re-create the problem.
    I appreciate the reply. I have redesigned my queries and the problem does not seen to be an issue any more. All values were converted via CCur.

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

Similar Threads

  1. Union query to join two crosstab queries
    By racefan91 in forum Queries
    Replies: 5
    Last Post: 09-26-2013, 10:24 AM
  2. Report totals don't match
    By RayMilhon in forum Reports
    Replies: 7
    Last Post: 11-30-2012, 10:44 AM
  3. Replies: 8
    Last Post: 10-22-2012, 07:43 PM
  4. Union Query of 2 Crosstab
    By shawnjerome in forum Queries
    Replies: 1
    Last Post: 04-05-2012, 01:05 PM
  5. Union Crosstab
    By dssrun in forum Queries
    Replies: 2
    Last Post: 11-14-2011, 10:28 AM

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