Hello. I have some embedded (single) quotation marks in my data source that I am reading char by char and stringing together to create a suitable DoCmd such as below. Problem is that these embedded quote's cause a problem with the quote's necessary for the command itself. Is there an escape sequence or something I can use. I need to preserve them in the data
DoCmd.RunSQL "insert into tableName(field1, field2) values('var1','var2')"
For example, if var1 = "ST DAVID'S PLACE" I end up with
DoCmd.RunSQL "insert into tableName(field1, field2) values('ST DAVID'S PLACE','var2')"
ie too many quotes !!
DoCmd.RunSQL "insert into tableName(field1, field2) values('var1','var2')"
For example, if var1 = "ST DAVID'S PLACE" I end up with
DoCmd.RunSQL "insert into tableName(field1, field2) values('ST DAVID'S PLACE','var2')"
ie too many quotes !!