Results 1 to 3 of 3
  1. #1
    WiReLaD is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Nov 2012
    Posts
    12

    Angry Query Criteria error

    I have a query field which I have named Indate:

    After which I have then continued the line as follows: Indate: IIf([ExpireDate]>Date(),"Live","Expired")

    ExpireDate is a populated cell thats calculated by way of adding years from a test date textbox. eg, I enter a test date 01/01/2013 and ExpireDate populates by adding 5 years = 01/01/2018

    This works fine.

    My problem comes - When I run the query, I only want to see anything with "Live" status

    I've tried all the normal criteria: options) "Live" or Like "Live" or "*live*" etc...



    The problem is, when I enter this into the criteria line, the query then doesn't seem to see the field ExpireDate: and asks me to enter the parameter value for ExireDate.

    Any help is much appreciated
    Thanks
    Mike

  2. #2
    alansidman's Avatar
    alansidman is offline Indifferent
    Windows 7 32bit Access 2010 32bit
    Join Date
    Apr 2010
    Location
    Steamboat Springs
    Posts
    2,538
    ExpireDate is a populated cell thats calculated by way of adding years from a test date textbox. eg, I enter a test date 01/01/2013 and ExpireDate populates by adding 5 years = 01/01/2018
    Is this expression in your query? I don't understand what you are referring to by a cell. That is a spreadsheet term and is meaningless in Access. Are you referring to a field in a table or query or are you referring to a control in a form?

    Usually you will get a parameter request as indicated when Access cannot identify a field in the table or query. Have you double checked your spelling to ensure it is exactly the same in your expression as in your field. No leading or trailing spaces? Spelled correctly?

  3. #3
    WiReLaD is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Nov 2012
    Posts
    12
    Its alright, its fixed.

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

Similar Threads

  1. Replies: 5
    Last Post: 09-20-2012, 03:27 PM
  2. Query Criteria Error
    By birth19 in forum Queries
    Replies: 2
    Last Post: 09-16-2012, 01:20 AM
  3. Replies: 5
    Last Post: 08-02-2012, 09:44 AM
  4. Replies: 1
    Last Post: 05-11-2012, 10:59 AM
  5. Query Criteria Causing Data Mismatch Error
    By jrubenol in forum Queries
    Replies: 2
    Last Post: 09-14-2011, 09:34 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