Binding with UPDATE
Deane Venske
dean at eduss.com
Thu Oct 16 09:35:56 CDT 2003
Hi Guys,
I just wanted to get some clarification on binding with UPDATES.
From what I've gathered in my testing when updating you can only use
bound values for the actual SET and not for WHERE expressions.
For Example :
recordsAffected = db.SqlExecute("UPDATE work SET workTitle = :1, classID
= :2, noQuestions = :3, dateDue = :4 WHERE workID = " + workDetails(4),
workDetails) ---> Works fine.
recordsAffected = db.SqlExecute("UPDATE work SET workTitle = :1, classID
= :2, noQuestions = :3, dateDue = :4 WHERE workID = :5", workDetails)
---> Doesn't work.
Are there reasons behind this? It would be great if we could use bound
values even in our WHERE statements. I only recently started using
binding and wish I had started with it a long time ago. It really makes
coding quicker and easier... almost as quick and easy as PHP queries :P
But that's a limit of RB not Valentina.
Deane
More information about the Valentina
mailing list