android - SQL-statement for ordering -
i order database - doesn't work
is
order <field> asc
the statement android?
you can't "order" database. however, can order query results, appropriate query overload.
public cursor query (string table, string[] columns, string selection, string[] selectionargs, string groupby, string having, string orderby)
for example:
db.query("sometable", new string[] { "columna", "columnb" }, "where columnc = ?", new string[] { "columnc_condition" }, "columnb", null, "columna");
translates
select columna, columnb sometable columnc = "columnc_condition" group columnb order columna
Comments
Post a Comment