Hey guys. My apologies in advance if this is a slightly mundane question.
I'm running this code from a scripting language bound to SQLite:
%r = db.query("SELECT * FROM userTable", 0);
%i = 0;
db.query("BEGIN TRANSACTION", 0);
while (%i < db.numRows(%r))
{
%username = db.getColumn(%r, name);
db.query("UPDATE userTable SET playedInfIds='' WHERE name LIKE
'?'", 0, %username);
%i ++;
}
db.query("END TRANSACTION", 0);
This query takes about 5 seconds to process - which seems like a long
time. userTable has 3000 entries, and the name column is TEXT PRIMARY
KEY NOT NULL UNIQUE.
Is there anything obvious I'm doing wrong? I know using LIKE is not
ideal, but the scripting language does not guarantee case so it is
necessary here.
Thanks,
Ian
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users