query calling function

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • prasad joshi
    New Member
    • Aug 2012
    • 30

    query calling function

    hello....

    i have heared that we can call a function by using access query

    i dont know how to do this

    can anybody give me example........ ..
  • twinnyfo
    Recognized Expert Moderator Specialist
    • Nov 2011
    • 3662

    #2
    prasad,

    You simply add the function to the query as one of the paramaters. Like so:

    Code:
    SELCET Field1, Date() AS CurrentDate FROM Table1;
    You can even use functions within your criteria as well:

    Code:
    "SELCET Field1, Field2 FROM Table1 WHERE Field2 =  #" & Date() & "#;"
    Hope this helps!

    Comment

    • prasad joshi
      New Member
      • Aug 2012
      • 30

      #3
      i want complex functions.....

      i know this one .......

      Comment

      • twinnyfo
        Recognized Expert Moderator Specialist
        • Nov 2011
        • 3662

        #4
        It is no different. Just use the same syntax and arguments required by the function......

        Do you have an example that you would like to use?

        Comment

        • TheSmileyCoder
          Recognized Expert Moderator Top Contributor
          • Dec 2009
          • 2322

          #5
          You could take a look at this video:
          How to use a Custom Function in MS Access

          Comment

          Working...