[storm] Storm : Multiple fields request
Jamu Kakar
jkakar at canonical.com
Wed Nov 12 15:23:46 GMT 2008
Hi Boris,
Boris Blondin wrote:
> > sl = store.find(cls,And(*
> expressions))
> That's I'm searching for, and can we do this with "Like" instead of "And" ?
Yes. You can do something like this:
where = []
where.append(Like(Employee.name, "%foo%"))
where.append(Employee.department_id == 45)
if some_condition:
where.append(Employee.start_date > date)
result = store.find(Employee, *where)
Hope this helps,
J.
More information about the storm
mailing list