Ok. Got it.
Now, if only I can get that multiple rows update working on my code, it
would be perfect.

Thanks a lot,
Chris

On Tue, Feb 9, 2016 at 12:07 PM, Clemens Ladisch <clemens at ladisch.de> wrote:

> Chris Prakoso wrote:
> >         public bool UpdateData(string tableName,
> Dictionary<string,object> fields, List<string> whereKeys)
> >         {
> >             ...
> >                     using (SQLiteTransaction transaction =
> conn.BeginTransaction())
> >                     {
> >                         ...
> >                         rowsUpdated = cmd.ExecuteNonQuery();
> >                         transaction.Commit();
>
> Using one transaction for each statement is slow.
> (Re-opening the database doesn't help either.)
>
> You should use a single transaction around all update statements.
>
>
> Regards,
> Clemens
> _______________________________________________
> sqlite-users mailing list
> sqlite-users at mailinglists.sqlite.org
> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
>

Reply via email to