android - Query error in SQLite -


this question has answer here:

i've tried code update values in column sync 0...
how can solve issue?

public boolean updatesync() {     sqlitedatabase db=this.getwritabledatabase();      db.rawquery("update patients set sync = '0'",null);      return true; } 

this code not working. need change entire column value of sync 0. how can that? i've found code working when searching, it's not working me. how can solve that?

please help.

use execsql() instead of rawquery().

rawquery() compiles sql not execute until returned cursor moved. execsql() both compiles , executes sql.


Comments

Popular posts from this blog

asynchronous - C# WinSCP .NET assembly: How to upload multiple files asynchronously -

aws api gateway - SerializationException in posting new Records via Dynamodb Proxy Service in API -

asp.net - Problems sending emails from forum -