On Sep29, 9:25am, rb <rbspg...@gmail.com> wrote:
> It is my understanding that when a request comes in to web2py the
> first thing that is done is to execute all of the model files (in
> filename alphabetical order). Is there some way to pass in, via the
> request, a parameter that can be used to select which model code is
> run?
>
> If I have a total of 93 tables but need only 4 to 6 of them at a time,
> I would like to avoid the setup time for all 93 of the tables in the
> model files.
>
> ---
> Rb

First of all, you can try to comment out all those tables other than
the 4 to 6 of them, and see whether your app runs significantly
faster. If it doesn't, perhaps you don't need this tweak. Generally
speaking, web2py's table definition is fast enough.

However if you wish to try, I think this could work, but I did not try
it. You can divide your app into many controllers, each defines and
uses its 4 to 6 tables. Mmm, the idea doesn't sound good because it
violates MVC but, if you want to.

---
Iceberg
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To post to this group, send email to web2py@googlegroups.com
To unsubscribe from this group, send email to 
web2py+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to