Results 1 to 2 of 2
  1. #1
    haydenbl is offline Novice
    Windows 7 32bit Access 2010 32bit
    Join Date
    Jul 2013
    Posts
    11

    Defaults in CrossTab query.

    I have a very simple crosstab query.

    TRANSFORM Count(QryWaiverWPlan.MEME_CK) AS CountOfMEME_CK
    SELECT QryWaiverWPlan.SBAD_COUNTY, QryWaiverWPlan.UniqueSS, QryWaiverWPlan.[PD WL], QryWaiverWPlan.[ICF/MR], QryWaiverWPlan.[ICF/MR Visit], QryWaiverWPlan.[DD WL], QryWaiverWPlan.Capacity, Count(QryWaiverWPlan.MEME_CK) AS [Total Of MEME_CK]
    FROM QryWaiverWPlan INNER JOIN Waivers ON QryWaiverWPlan.Wiaver_Population = Waivers.Wiaver_Population


    WHERE (((Waivers.Capacity_Tool) Is Not Null))
    GROUP BY QryWaiverWPlan.SBAD_COUNTY, QryWaiverWPlan.UniqueSS, QryWaiverWPlan.[PD WL], QryWaiverWPlan.[ICF/MR], QryWaiverWPlan.[ICF/MR Visit], QryWaiverWPlan.[DD WL], QryWaiverWPlan.Capacity
    PIVOT Waivers.Capacity_Tool;

    What I need is to have Count(QryWaiverWPlan.MEME_CK) have a default of zero. When I take this query into a report and try to do some calculations, I get errors "#Type!".

    I have tried the Nz command and no luck, and I have tried using Val on the fields that I am calculating.
    Any help is greatly appreciated.

  2. #2
    June7's Avatar
    June7 is online now VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    48,835
    You tried the Nz where? Post the attempted expression.
    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. Change table field defaults
    By paddymx in forum Programming
    Replies: 11
    Last Post: 12-14-2013, 03:38 PM
  2. attachment defaults
    By chiefmsb in forum Access
    Replies: 0
    Last Post: 07-13-2011, 06:38 AM
  3. Combo Box defaults to Blank
    By jimmonator in forum Forms
    Replies: 13
    Last Post: 05-02-2011, 01:28 PM
  4. Defaults Values Missing After DB Move
    By cbuechler in forum Database Design
    Replies: 2
    Last Post: 02-15-2011, 08:33 AM
  5. Replies: 1
    Last Post: 07-30-2010, 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
  •  
Tech Forums: Microsoft Office Forums