Results 1 to 4 of 4
  1. #1
    Join Date
    May 2003
    Location
    Dallas
    Posts
    817
    Provided Answers: 5

    Unanswered: string functions not working in sql statements

    This only happens on machines using a runtime access engine

    if I use a string function ie:
    SELECT tblEmployee.Number, [FName] & " " & Left([lname],1) AS Name FROM tblEmployee

    AS A RECORDSOURCE FOR A COMBO BOX

    the box is null

    I have seen this behavior only on some machines using the runtime version

    Is there a dll that I may be missing or not registering in the install of our applications that may cause this - coincidentally these same machines bomb out when using the 'format" function as well in the sql statements.
    Last edited by axsprog; 04-15-08 at 19:15.
    Dale Houston, TX

  2. #2
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    Sounds like a references problem to me... but I don't know exactly what could make it fail on only some computers.

    Are you sure you have the runtime Access correctly installed on the machines that are failing? You could try re-installing it on a failing machine.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  3. #3
    Join Date
    May 2005
    Location
    Nevada, USA
    Posts
    2,888
    Provided Answers: 6
    It does sound like a reference problem, particularly since it only fails on some computers. Try this:

    http://www.accessmvp.com/djsteele/Ac...nceErrors.html

    Also, I'd avoid the use of "Name" as a field name:

    http://support.microsoft.com/default...b;EN-US;209187
    Paul

  4. #4
    Join Date
    May 2003
    Location
    Dallas
    Posts
    817
    Provided Answers: 5
    The reference that would cause a "normal" problem would be the dao library which if that were missing the same functions would fail in VBA code as well - and they do not.

    It only fails in the sql statements on machines with the runtime - and not all machines.

    I am really baffled by this.
    Dale Houston, TX

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •