Results 1 to 6 of 6
  1. #1
    colleenvr is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Aug 2014
    Posts
    3

    Reports: Feilds vs Expressions

    I have generated a receipt in a report that includes the Fields "TotalDonated" and "Deduction" (listed as field in the Control Source rather then an expression). A Third field is a Calculated field that gives the number I need. TotalDonated-Deduction. No Prob.



    I have a problem when there is no data listed in Deduction. In report view it skips over people who do no have the "deduction" field list. How do I get around this?

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,624
    What do you mean by 'skips over' - the calculated field doesn't show anything? The issue is that Deduction is Null. Arithmetic with Null results in Null. Need to handle possible Null.

    [TotalDonated]-Nz([Deduction],0)
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    colleenvr is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Aug 2014
    Posts
    3
    Thanks for the formula. I have inserted and it does not mess up anything so that's good, but I still have the same "Skipping" problem

    Every record(name) has a "TotalDonated" associated with it but not every name as a "Deduction". Names that has no deduction but still a TotalDonated do not get produced in the report (they are skipped over). The problem comes when a record does not have a "Deduction" value. Should I be thinking along the lines of IFMissing......

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,624
    I expect the issue is with the query, probably INNER JOIN should be an OUTER (LEFT or RIGHT) JOIN.

    Really need to know more about data structure. Post the query SQL statement for analysis. Or provide the db. Follow instructions at bottom of my post.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  5. #5
    colleenvr is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Aug 2014
    Posts
    3
    Quote Originally Posted by June7 View Post
    I expect the issue is with the query, probably INNER JOIN should be an OUTER (LEFT or RIGHT) JOIN.

    Really need to know more about data structure. Post the query SQL statement for analysis. Or provide the db. Follow instructions at bottom of my post.
    ___________________

    I think in know what i need.... could you provide an expression for the following statements. [Field amount], but if it's blank (meaning no data) then 0?

  6. #6
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,624
    Nz([Field amount],0)
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

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

Similar Threads

  1. Replies: 2
    Last Post: 03-04-2014, 06:46 AM
  2. Sum of Two Feilds of Two Queries in Seperate Query
    By shekar_genius in forum Queries
    Replies: 3
    Last Post: 03-13-2013, 08:27 AM
  3. Replies: 12
    Last Post: 12-14-2012, 06:25 PM
  4. Replies: 15
    Last Post: 08-30-2012, 04:16 PM
  5. Need to map excel feilds to access database ASAP (will pay $ for help)
    By Steven Thibault in forum Import/Export Data
    Replies: 22
    Last Post: 12-27-2009, 09:37 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