Undefined function 'Nz' in expression

Discussion in 'Microsoft Access Queries' started by Daniel Melero, Nov 17, 2003.

  1. Hi, I'm getting that error message when I am executing a
    query.

    SQLquery = "SELECT tbl_call_log.Shipper, Nz([tbl_locn].
    [District]) AS District, tbl_call_log.Dest_Unit, "
    SQLquery = SQLquery & "tbl_call_log.ID, Nz
    ([tbl_call_log].[SCAC]) AS SCAC,
    tbl_call_log.Late_Ctgy_Maj, "
    SQLquery = SQLquery & "tbl_call_log.Late_Ctgy_Sub,
    tbl_call_log.Delay_Unit, tbl_call_log.Orig_Appt_Dt, "
    SQLquery = SQLquery & "tbl_call_log.Booking_Number,
    tbl_call_log.Orig_Appt_Tm, tbl_call_log.Contact_Orig, "
    SQLquery = SQLquery & "tbl_call_log.Rev_Appt_Dt,
    tbl_call_log.Rev_Appt_Tm, tbl_call_log.Cust_Rev_Appt_Dt,
    tbl_call_log.Cust_Rev_Appt_Tm, tbl_call_log.Act_Del_Dt,
    tbl_call_log.Act_Del_Tm "
    SQLquery = SQLquery & " FROM tbl_locn INNER JOIN
    tbl_call_log ON tbl_locn.Dest_Unit =
    tbl_call_log.Dest_Unit"
    SQLquery = SQLquery & " GROUP BY tbl_call_log.Shipper,
    Nz([tbl_locn].[District]), tbl_call_log.Dest_Unit, "
    SQLquery = SQLquery & "tbl_call_log.ID, Nz
    ([tbl_call_log].[SCAC]), tbl_call_log.Late_Ctgy_Maj,
    tbl_call_log.Late_Ctgy_Sub, "
    SQLquery = SQLquery & "tbl_call_log.Delay_Unit,
    tbl_call_log.Orig_Appt_Dt, tbl_call_log.Booking_Number,
    tbl_call_log.Orig_Appt_Tm, "
    SQLquery = SQLquery & "tbl_call_log.Contact_Orig,
    tbl_call_log.Rev_Appt_Dt, tbl_call_log.Rev_Appt_Tm,
    tbl_call_log.Cust_Rev_Appt_Dt, "
    SQLquery = SQLquery & "tbl_call_log.Cust_Rev_Appt_Tm,
    tbl_call_log.Act_Del_Dt, tbl_call_log.Act_Del_Tm"
    SQLquery = SQLquery & HavingString
    SQLquery = SQLquery & " ORDER BY tbl_call_log.Shipper,
    tbl_call_log.Dest_Unit, tbl_call_log.Orig_Appt_Dt,
    tbl_call_log.Booking_Number;"

    Set rs = db.OpenRecordset(SQLquery, dbOpenDynaset)


    Can someone help? Thanks in advance.
     
    Daniel Melero, Nov 17, 2003
    #1
    1. Advertisements

  2. Daniel Melero

    John Vinson Guest

    On Mon, 17 Nov 2003 15:55:15 -0800, "Daniel Melero"
    <> wrote:

    >Hi, I'm getting that error message when I am executing a
    >query.


    This appears to be the very common References bug. Open any
    module in design view, or open the VBA editor by typing
    Ctrl-G. Select Tools... References from the menu. One of the
    ..DLL files required by Access will probably be marked
    MISSING. Uncheck it, recheck it, close and open Access.

    If none are MISSING, check any reference; close and open
    Access; then uncheck it again. This will force Access to
    relink the libraries.

    John W. Vinson[MVP]
    Come for live chats every Tuesday and Thursday
    http://go.compuserve.com/msdevapps?loc=us&access=public
     
    John Vinson, Nov 18, 2003
    #2
  3. Thanks. It worked. Do you know why the Links get lost? or
    what causes them to lose the links?
    >-----Original Message-----
    >On Mon, 17 Nov 2003 15:55:15 -0800, "Daniel Melero"
    ><> wrote:
    >
    >>Hi, I'm getting that error message when I am executing a
    >>query.

    >
    >This appears to be the very common References bug. Open

    any
    >module in design view, or open the VBA editor by typing
    >Ctrl-G. Select Tools... References from the menu. One of

    the
    >..DLL files required by Access will probably be marked
    >MISSING. Uncheck it, recheck it, close and open Access.
    >
    >If none are MISSING, check any reference; close and open
    >Access; then uncheck it again. This will force Access to
    >relink the libraries.
    >
    > John W. Vinson[MVP]
    > Come for live chats every Tuesday and Thursday
    >http://go.compuserve.com/msdevapps?loc=us&access=public
    >.
    >
     
    Daniel Melero, Nov 18, 2003
    #3
  4. Daniel Melero

    John Vinson Guest

    On Tue, 18 Nov 2003 08:43:20 -0800, "Daniel Melero"
    <> wrote:

    >Thanks. It worked. Do you know why the Links get lost? or
    >what causes them to lose the links?


    I sure wish I did; I'd sell the fix to Microsoft and retire on the
    proceeds.

    Apparently it's just part of "DLL Hell" - the complexity of the
    Windows registry and file linkage. Sometimes installing a completely
    unrelated program can cause this problem to arise.

    John W. Vinson[MVP]
    Come for live chats every Tuesday and Thursday
    http://go.compuserve.com/msdevapps?loc=us&access=public
     
    John Vinson, Nov 18, 2003
    #4

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Eric J Owens

    Undefined Function 'Replace' in Expression

    Eric J Owens, Jul 11, 2003, in forum: Microsoft Access Queries
    Replies:
    3
    Views:
    11,300
    Ken Snell
    Jul 14, 2003
  2. budiono

    Undefined function 'Date' in expression

    budiono, Jul 22, 2003, in forum: Microsoft Access Queries
    Replies:
    1
    Views:
    14,646
    John Spencer (MVP)
    Jul 22, 2003
  3. bigknowz

    Undefined function 'DDE' in expression

    bigknowz, Jul 24, 2003, in forum: Microsoft Access Queries
    Replies:
    0
    Views:
    544
    bigknowz
    Jul 24, 2003
  4. Keith

    "undefined function 'Right' in expression"

    Keith, Jul 24, 2003, in forum: Microsoft Access Queries
    Replies:
    2
    Views:
    6,320
    Armen Stein
    Jul 25, 2003
  5. vcapy

    Undefined function 'Date' in Expression

    vcapy, Aug 19, 2003, in forum: Microsoft Access Queries
    Replies:
    2
    Views:
    433
    Douglas J. Steele
    Aug 19, 2003
Loading...

Share This Page