Loading variable containing a single quote as field in a table
Hi community users,
I found a lot of useful information concerning quotation and escape sequences, but nothing about my quotation problem.
I've a variable containing a text starting with a single quote (chr(39)).
I'm trying to use this variable (within $()) as literal in a Load statement, but as literals should come in single quotes it doesn't work.
Here is my code:
My variable vFile contains a single quote:
The QV parser inserts an Escape sequence trying to solve the problem.
The error comes with following debug information, the literal is starting with a triple single quote:
According to previous information, I would assume that the second and third quote would resolve as Escape sequence, but that doesn't work. My guess is doesn't work because it's at the beginning of the literal.
My simple solution is to replace the single quote Chr(39) by quotation mark Chr(96), that works.
However my style is 'perfect and simple' solutions: so I'm still looking for a better way to solve this issue.