I have a select like this:  

  progs_running = list(ProgRun.select(AND(ProgRun.q.progressID == '3',
                                                  ProgRun.q.pingTime > cutoff),
                                                  orderBy=ProgRun.q.theCompany))

where theCompany is a foreign key. 

What I'd really like to do though is order it by the company name, which is stored in the table that the foreign key theCompany connects to.

So something like orderBy=ProgRun.q.theCompany.companyName

but unfortunately that doesn't work.

Is there a simple way to do this with sqlObject?

Thanks