Q:

How to pass two parameters in android sqlite

How to pass two parameters in android sqlite query statement?
My query looks like this, but I am getting error. If I use one where condition its working fine, but I want to use two condition.
db.query(true, DB_TABLE, new String[] {KEY_ROWID,Source,
                        Dest}, DestStn + "=" + t ,Source + "=" +tt,null,
                        null, null, null, null);

A:

you sould replace to "KEY_ROWID = ? AND Source = ?",
         new String[] { t, tt }
Complete query:
db.query(DATABASE_TABLE, new String [] {KEY_ROWID, Source,Dest}, "Source = ? AND DestStn = ?",
     new String[] { tt, t },
     null,
     null,
     null); 

A:

you can use db.rawQuery(Your_Query);
i think in your case 
String query = "Select * from "+DB_TABLE+ "Where" +DestStn + "=" + t +"and"+Source + "=" +tt
db.rawQuery(query);

