Hola muchacho,
this how your SQL string will look like:
Code: Select all
INSERT into original (title, date_rec, comments) VALUES (wkTitle, wkRecDate, wkComments);
I'm sure that is not what you inteded, right?
AND you need to put single quotes around the values, otherwise strange things might happen, as you experienced here
Using my little functions, which will save a lot of typing, not oly with database stuff, and the neccessity to count all single/double quotes:
Code: Select all
function q tString
return QUOTE & tString & QUOTE
end q
function q2
return "'" & tString & "'"
end q2
<our script should look like:
Code: Select all
...
put "INSERT into original (title, date_rec, comments) VALUES (" & q2(wkTitle) & ", " & q2(wkRecDate) & ", " & q2(wkComments);" into tSQL
## If in doubt ALWAYS -> answer tSQL
## to have the "slap on the forehead" moment :-D
revExecuteSQL tDatabaseID, tSQL
...
Best
Klaus