Hi Folks
I am having a problem with the following ADO/DAO routines, if an address field contains double quotes (") it runs into errors, there are single quotes as well in the data I am dealing with, so is there another way with which it would be able to deal with double, single quotes and whatever.
Thank for your help
Brenda
---
I am having a problem with the following ADO/DAO routines, if an address field contains double quotes (") it runs into errors, there are single quotes as well in the data I am dealing with, so is there another way with which it would be able to deal with double, single quotes and whatever.
Thank for your help
Brenda
---
Code:
---
sqlADORs = "SELECT id,name,address FROM remote_table"
Set ADORs = cPostgreSQL.Execute(sqlADORs, , adOpenForwardOnly) 'Fetching data from remote source
If (Not ADORs.EOF And Not ADORs.BOF) Then 'Inserting into local access table
Do Until ADORs.EOF
db.Execute "INSERT INTO local_table (id, name, address " & _
"VALUES (""" & ADORs!ID & """,""" & ADORs!name & """,""" & ADORs!Address & " "")"
ADORs.MoveNext
Loop
End If
---[Code]---