Results 1 to 2 of 2
  1. #1
    tim_tims33 is offline Advanced Beginner
    Windows 7 64bit Access 2013
    Join Date
    Dec 2011
    Posts
    62

    Why doesn't this DCount() work?

    Hi,

    Trying to apply a simple Dcount() to a table to return the number of records WHERE....
    (i) The priority Level is High
    (ii) The issue is resolved.

    Each time i keep getting 0. Why is this?

    Here is my table... in the attachment



    ...and here is my DCount() expression...

    =DCount("Fix_ID","Fix_List",([PriorityLevel]="High") And ([Resolved]="True"))
    Attached Thumbnails Attached Thumbnails ScreenShot.jpg  

  2. #2
    orange's Avatar
    orange is offline Moderator
    Windows XP Access 2003
    Join Date
    Sep 2009
    Location
    Ottawa, Ontario, Canada; West Palm Beach FL
    Posts
    16,726
    Date is a reserved word in Access.
    Do not use a naming convention that allows embedded spaces in field or object names.
    Do use special characters "/" in field or object names --- will require special handling throughout your application
    and will lead to syntax errors.

    Untested but I'd try

    =DCount("Fix_ID","Fix_List","PriorityLevel='High' And Resolved=True")

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

Similar Threads

  1. Replies: 5
    Last Post: 04-14-2014, 12:37 PM
  2. Just doesn't seem to work!
    By txmmoore in forum Reports
    Replies: 9
    Last Post: 01-16-2014, 11:39 AM
  3. Can't get DCount statement to work
    By jhko in forum Programming
    Replies: 8
    Last Post: 02-10-2013, 05:50 AM
  4. App doesn't work with runtime
    By bubba55 in forum Access
    Replies: 0
    Last Post: 09-21-2011, 08:33 AM
  5. Query doesn't work the day after
    By sithis876 in forum Queries
    Replies: 1
    Last Post: 07-13-2010, 07:11 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