lundi 14 mars 2016

Query for retrieve data from sqlite db with where clause using cursor

I need to get data from table in android.My actual query will be like this:

How to write query to get particular id from table in android

 String city=Hyderabad;

Cursor c=db.query("Select cityid from mastercity where cityname=""+city");

but it is showning error "no such colomn hyderabad";

Aucun commentaire:

Enregistrer un commentaire