On Feb 8, 5:29 pm, mdipierro <mdipie...@cs.depaul.edu> wrote:
> can you show the model?

http://trac.sahanapy.org/browser/models/05_or.py

F

> On Feb 8, 3:24 pm, sunneach <nvd...@gmail.com> wrote:
>
>
>
> > There are two tables:
>
> > or_organisation (id, name, sector_id, ...)
> > and
> > or_sector(id, name, ...)
>
> > And the sector_id is pointing to or_sector.id through the "reusable"
> > field concept.
>
> > It is all fine when I pull the or_organisation records and then use
> > method represent to fill in the or_sector.name to display.
>
> > But if we want the MySQL (or any other engine) to get the right
> > related or_sector.name to
>
> > a) order it via           ... ORDER BY or_sector.name DESC       and
> > b) search it via             WHERE or_sector.LIKE '%context%
>
> > the DAL 'left' construct does not work because the type of reusable
> > field is 'string' and not numeric:
>
> >          left=or_sector.on(or_sector.id = or_organisation.sector_id)
>
> > What's more,  it is having, say, u'|1|' which can be converted to 1
> > via specific CAST and TRIM.
>
> > Is there any way to do that for table.on method?
> > OR how do we pull joins otherwise?

-- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To post to this group, send email to web...@googlegroups.com.
To unsubscribe from this group, send email to 
web2py+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en.

Reply via email to