android - greenDAO: compare two properties with each other -
i sure should simple can't seem find solution.
say have table 5 fields (id, colour, size, scanned, expected)
how rows expected greater scanned?
i have tried
mydao.property.expected.gt(mydao.property.scanned).list()
but returns 0 rows. using log_sql boolean can see looking property field, not value of field.
d/greendao: values query: [0, de.greenrobot.dao.property@33ecce97]
greendao's querybuilder api not support (yet). have use raw query.
it this:
query myquery = mydao.querybuilder().where(new stringcondition( property.expected.columnname + " > " + property.scanned.columnname)).build();
ps.: created feature request if want track future greendao version.
Comments
Post a Comment