我的应用程序中有一个空闲数据库。如何删除任何行?我的数据库代码如下:
mydb=Nickname.this.openOrCreateDatabase("private", 0, null);
mydb.execSQL("CREATE TABLE IF NOT EXISTS numbers(nickname varchar,number INT(13))");
有谁知道这怎么可能?
mydb=Clear.this.openOrCreateDatabase("private", 0, null);
mydb.execSQL("CREATE TABLE IF NOT EXISTS numbers(_id INTEGER PRIMARY KEY,nickname varchar,number INT(13))");
mydb.execSQL("DELETE FROM numbers WHERE id='=?' AND number='"+num+"'");
//num is string which contains which number i wish to delete