mercredi 22 avril 2015

getting value from sqltable into string

i NEED fetch the data from the database and then i need to compare it with other string i am not able to assign the value to an string

NEED TO FETCH THE 5555 AND STRORE INTO ANY STRING OR INTEGER

HOW TO INSERT THE FETCHED VALUE INTO STRING

SQLiteDatabase db =openOrCreateDatabase("mydb",MODE_PRIVATE,null); db.execSQL("CREATE TABLE IF NOT EXIST DATA(ID NUMBER,PASS NUMBER);"); db.execSQL("INSERT INTO DATA VALUES(1,5555);");

db.execSQL("SELECT PASS FROM DATA WHERE ID=1;");

Aucun commentaire:

Enregistrer un commentaire