sql - Android SQLITE does not execute queries with arguments -
i fail queries arguments, doing wrong?
i need following query:
cursor = bd.rawquery("select * user user.name=?", new string[]{"%"+nombre+"%"});
i tried following , fail:
cursor = bd.rawquery("select * user name=?", new string[]{"%"+nombre+"%"}); cursor = bd.rawquery("select * user user.name=?", new string[]{nombre});
this works:
cursor = bd.rawquery("select * user ", null);
thanks help
please try this, list out users name foo
.
cursor = bd.rawquery("select * user name = ?", new string[] {"foo"});
or
cursor = bd.rawquery("select * user name ?", new string[] {"foo"});
Comments
Post a Comment