Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

' in query

I'm importing several names from one program to another (but this problem came to me several times in the past), and the software from where i'm importing the clients names have the character '
for instance
M. J'Anne
Victor D'art
...
When i try to filter the data in the database, like for instance:
recordset.filter="name='M. J'Anne'"
I get an error.
if i do the same when trying to open the recordset, like for instance:
recordset.open("Select * from table where name='M. J'Anne'")
i also get an error
Is there anyway to overcome this problem

my thanks in advance

Comments

  • zaib_awanzaib_awan Member Posts: 9
    : I'm importing several names from one program to another (but this problem came to me several times in the past), and the software from where i'm importing the clients names have the character '
    : for instance
    : M. J'Anne
    : Victor D'art
    : ...
    : When i try to filter the data in the database, like for instance:
    : recordset.filter="name='M. J'Anne'"
    : I get an error.
    : if i do the same when trying to open the recordset, like for instance:
    : recordset.open("Select * from table where name='M. J'Anne'")
    : i also get an error
    : Is there anyway to overcome this problem
    :
    : my thanks in advance
    :

    Remove the single quote " ' " in Name then it will work.
    Single Qoute use as Start of String or End of String.

Sign In or Register to comment.