Thanks a lot, Bruno.

That really helps, but since my legacy DBs are too much and too
complex (MSSQL Server are only readable to me), I decide to create my
own connections and queries to my MSSQL Server.
Thanks again.

On Jan 18, 3:57 pm, Bruno Rocha <rochacbr...@gmail.com> wrote:
> You need to map the existent table and set migrate=False, also you will
> need to specify which field is the 'id' or primary keys, and for all fields
> you need to tell the datatype.
>
> msdb.define_table(
>                             'test',
>                             FIeld('cod', 'id'),
>                             Field('field1', "datatype"),
>                             Field('field2', "datatype"),
>                             migrate=False
>                            )
>
> look 
> here:http://web2py.com/books/default/chapter/29/6#Legacy-databases-and-key...
>
> --
>
> Bruno Rocha
> [http://rochacbruno.com.br]

Reply via email to