sqlite3_stmt *updateStmt = nil;
if (updateStmt == nil)
{
const char *sql = " update PPM set amount = ? ";
if (sqlite3_prepare_v2(appDelegate.PPMdatabase, sql, -1,&updateStmt, NULL)!= SQLITE_OK)
{
NSAssert (0,@"Error while creating update statement. '%s'",sqlite3_errmsg(appDelegate.PPMdatabase));
}
}
sqlite3_bind_double (updateStmt,1, Val);
if (SQLITE_DONE != sqlite3_step(updateStmt))
{
NSAssert(0,@"Error while updating.'%s'",sqlite3_errmsg(appDelegate.PPMdatabase));
}
sqlite3_reset(updateStmt);
I get error: error while updating.unkown error