• Problem with queries (Access 2K)

    Author
    Topic
    #380453

    Hi All

    I’ve substantially amended this post.

    I’d be greatful if someone would look at the queries I have attached.
    QryBookedDates, when opened, as expected, requests a Room Name parameter. When supplied, another parameter is required -available.id- which I am at a loss to explain. When the Msg is cancelled, the query then returns the correct records.
    When the qryFreeDates is run, again as expected, the Room Name parameter is requested. On supplying this a Msg box is displayed:

    The attached screen shot has an error which has been rectified. In qryBookedDates I had omitted a second field -Room Name- which obtains its parameter value from a combo on a form.
    The table -Available- stores all possible dates and room combinations. Essentially what I’m trying to do is to subtract the dates for a given room from all possible dates for that room.
    Can anybody spot the error in my method or shed light on the query messages?

    I know I’m close to a solution but this has been driving me batty!

    Cheers

    Rob

    Viewing 0 reply threads
    Author
    Replies
    • #637182

      Can you repost this with the errors you know you have fixed removed, because what you have posted is confusing.
      QryBooked Dates shows a roomnumber parameter against a date field, but this comes from a form, so I can’t see why it prompts for anything.

      Another error is visible. “IsNull” has quotes around it. this means that the query is looking for the string isnull rather than records where the field is null. Remove “isNull” and just type Null. Access will correct the syntax.

    Viewing 0 reply threads
    Reply To: Problem with queries (Access 2K)

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: