Named parameters are easier to edit, change, or omit than ? params.
stmt.text = 'INSERT INTO scores( contestant, score, correct, incorrect ) '+
'VALUES (@contestant,@score,@correct,@incorrect );';
stmt.parameters['@contestant'] = rowItem.contestant;
stmt.parameters['@score'] = rowItem.score;
stmt.parameters['@correct'] = rowItem.correct;
stmt.parameters['@incorrect'] = rowItem.incorrect;
The looping function setParams seems to hate it if any of the ?'s are changed
around. The code
should scaffold up to allow for this level of flexibility. Not all params need
to be sent on an insert.
Original issue reported on code.google.com by JeffreyT...@gmail.com on 17 Mar 2009 at 5:22
Original issue reported on code.google.com by
JeffreyT...@gmail.com
on 17 Mar 2009 at 5:22