Hi Marcello.

if your table has an auto-increment integer field you can do:

db.define_table('another_name',Field('the-auto-inc-field','id'), ...)

if not then sorry, no one has contributed the keyed table support for
mysql, see:
http://web2py.com/book/default/chapter/06#Legacy-Databases-and-Keyed-Tables

Denes

On Dec 31, 8:17 am, Marcello Parra <[email protected]> wrote:
> Hello,
>
> I have a legacy database, and want to access it with web2py.
> One table is called "another_name" in the database (mysql).
>
> But I want to use it in web2py as:
>
> db.define_table('person', Field('name'))
>
> I read docs, but could not figure this out....
>
> Thanks for any help...
>
> Marcello

Reply via email to