and by migrate .... Massimo means (correct me if needed)  DAL will not
generate an "ALTER TABLE" kind of SQL command, will not alter target data
structure.
If DAL maps correctly to some _part_ of the target table (you only need to
define / describe in DAL what you will access) you are ok (as long as target
somehow exposes an "ID" field to web2py).

On Thu, May 7, 2009 at 8:28 AM, mdipierro <[email protected]> wrote:

>
> On May 7, 6:22 am, "Sebastian E. Ovide" <[email protected]>
> wrote:
> > Hi All
> >
> > accordingly with some recent thread, web2py has some problems acceding
> > tables that differs from the models defined in db.py
>
> That is not quite correct. web2py just does not like if you create a
> table from web2py and then you change the table outside web2py or it
> you delete metadata information in databases/*.table
>
> >  my app needs to read a DB used by another application (that is not
> web2py)
> > and create a report based on its data. What would it be the cleanest way
> to
> > connect to another DB if the current DAL doesn't support it (yet) ?
>
> No problem. Just do:
>
> db.define_table(.....,migrate=False)
>
> The only limitation is that since you did not create these tables with
> web2py you will not be able to migrate them from web2py (unless you
> create the .table files).
>
> Massimo
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py Web Framework" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to