• how to specify dlookup domain in expression builde (97)

    Home » Forums » AskWoody support » Productivity software by function » MS Access and database help » how to specify dlookup domain in expression builde (97)

    Author
    Topic
    #362267

    how to specify dlookup domain in expression builder
    how would you write the DOMAIN argument of the dlookup function when you are in the expression builder?

    Viewing 0 reply threads
    Author
    Replies
    • #549765

      Highlight the phrase and type in the correct argument.

      • #568409

        Actually something like this isn

        • #568410

          well here

          • #568446

            I suspect it should be more like
            DLookUp(“refNum”,”NewQuery”,”[refNum][NewQuery]![ReferenceNumber]”)

            Using will most likely just give you the first refNum in the table each time though!

            Peter

        • #568491

          It won’t work in the criteria because it doesn’t know what the value of [NewQuery]![ReferenceNumber] is. You use doman aggregates like that to create a calculated field in a query, not to act as criteria.

          What you can do is use a dlookup in a calculated field (drop the NewQuery! part of it and include the inside the quotes, then use an ampersand between that and the field reference). Then in the criteria line under that expression, put Is Not Null as the criteria. That will give you the records where the dlookup result returns a value that does not match the referencenumber field. Unfortunately, I can’t say that the dlookup makes sense to me, since it’s going to return the first value it finds that isn’t equal to ReferenceNumber, and I’m not sure what that gets you. shrug

    Viewing 0 reply threads
    Reply To: how to specify dlookup domain in expression builde (97)

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

    Your information: