Web2py defaults to using an 'id' field of type sequence. 

In the online book they have a section called 'Legacy Databases and Keyed 
Tables<http://web2py.com/book/default/chapter/06#Legacy-Databases-and-Keyed-Tables>
'
Here they identify a method of setting a different field to be you primary 
key... so for you I believe you would have:


db.define_table('test',
 Field('test_id', id),
 Field('name'), 
migrate=False, fake_migrate=True) 

Hope this helps,

Reply via email to