I've tried the following: 

def download(): 
    print "\ndb.tables:", db.tables
    print "\ndb.tables fields:", db['t_image'].fields
    return response.download(request,db)

It does show that t_image is part of the db definition, and that all the 
fields that should be there are present.


On Saturday, October 18, 2014 11:01:25 AM UTC-5, Leonel Câmara wrote:
>
> I think I figured it out. The problem is that the table t_image isn't 
> defined in the download function. Because it's only defined when you 
> instantiate an Image.
>
> Consider making a @staticmethod define_tables in Image that will define 
> the table and call it in the models.
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to