vendredi 2 janvier 2015

Error in update: "logic error or missing database" sqlitepcl

I can not get two updates in the same transaction.


The first is performed but the second error.


When making the second update I get the error: "logic error or missing database"


The following example:



string sql = "UPDATE PARAMETROFILIAL SET VALOR = ?, DESCRICAO = ? WHERE IDPARAMETROFILIAL = ?";
using (SQConnectionDatabase sqCon = new SQConnectionDatabase(MobileContext.Instance.databasePath))
{
sqCon.BeginTransaction();
int result = sqCon.Execute(sql, "X1", "X1", 1);
result = sqCon.Execute(sql, "X2", "X2", 2);
sqCon.Commit();
}


Can you help?


Aucun commentaire:

Enregistrer un commentaire