"Jim Steil" <[EMAIL PROTECTED]> writes:

> f = Formula.select()
> f = f.filter(Formula.q.name.startswith(searchText.encode('utf8')))
> f = f.filter(Formula.q.formulatedBy==18)
>
> And I get the following on the last statement.
>
> AttributeError: Formula instance has no attribute 'formulatedBy'
>
> Can someone tell me what is causing this error and how I can reference this
> field in my filter?
>
> Again, I appreciate any info you can give me.

Try:

f = f.filter(Formula.q.formulatedByID==18)


The Formula.q.formulatedBy is an instance of the other class and not the
integer with the corresponding id.

-- 
Jorge Godoy      <[EMAIL PROTECTED]>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to