I am so sorry I made an error in my statement on the original question.
Text1 is a paragraph field on the VB6 form. It sometimes contains quotation marks within the paragraph. Quotation marks are also found in the Narrative field in the database. I am doing a comparison with the SQL statement to see if anything from the form(Text1) exists in the database(Narrative) When executing the sql command thats when I get the error.
How do I resolve this problem? Sorry for the poor handling of my question. Please feel free to ask for any other clarification but I hope that clarifys it.
I believe the quotation marks that are causing the error look like this in the narrative:
Bobby when to his friend's house
OR
He said it was "unsuitable"
I just tested my issue and its definitely scenarios where the paragraph in Text1 has an apostrophe.
ie. The dog ran to Barry's house
OR
The 'dog' has some issues
Both of these produce errors
I don't believe either of your answers will work. You see I'm trying to see if this narrative from Text1 exists in the database so if I replace the apostrophe in Text1 with another character, then it won't properly locate the paragraph since the value has essentially changed. Ugh!
by golly jee whiz. I should have just shut up and tried the solution. Yes. Martin was right. change aikmarks solution to 39!
Open in new window