Slow in opening project

Posts   
 
    
Barry
User
Posts: 232
Joined: 17-Aug-2005
# Posted on: 27-Aug-2005 03:59:11   

My database has over 600 tables, and I just added around 10 tables to the project, everytime I open the project from desginer, it requires over 3 minutes to load it, the cpu usage is 100% used by designer, any ways to load the project faster?

Paul.Lewis
User
Posts: 147
Joined: 22-Aug-2005
# Posted on: 27-Aug-2005 04:42:42   

Barry wrote:

My database has over 600 tables, and I just added around 10 tables to the project, everytime I open the project from desginer, it requires over 3 minutes to load it, the cpu usage is 100% used by designer, any ways to load the project faster?

Barry,

600 tables is a HUGE database. I don't envy you keeping track of that many tables!

When you ask the Designer to interogate your database it goes out and reads the entire schema and saves all of the schema information in the project file; not just the entities you add for use. This allows you to add entities, view, stored procedures (at a later date) without re-interrogating the database.

Since all of the schema information is saved in the project file for all 600 entities you can understand that it takes some time to load.

You can prove/disprove this by creating a project on a smaller database (<100 entities) and comparing project load time. You should see a big difference.

Paul

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39618
Joined: 17-Aug-2003
# Posted on: 27-Aug-2005 10:17:37   

600 tables shouldn't take 3 minutes. I've a 700 table project here which loads in 20 seconds. The main issue is stored procedures. Do you have a lot of stored procedures in your catalog? If so, create a separate project for your stored procedures and refresh the catalog again without retrieving hte procedures on your current project. It then should load faster.

Frans Bouma | Lead developer LLBLGen Pro
Barry
User
Posts: 232
Joined: 17-Aug-2005
# Posted on: 29-Aug-2005 03:48:18   

I run SQL Profiler to trace the activities on SQL Server when I open my project, it does not have any activities on SQL Server, so I think the designer do not interogate my database and refresh the schema when I open my existing project.

I only included tables in my project, it does not contain any views, stored procedures, and custom properties.

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39618
Joined: 17-Aug-2003
# Posted on: 29-Aug-2005 10:38:43   

Barry wrote:

I run SQL Profiler to trace the activities on SQL Server when I open my project, it does not have any activities on SQL Server, so I think the designer do not interogate my database and refresh the schema when I open my existing project.

Once a project is created, no database activity is performed so loading a project won't make the designer connect to the db.

I only included tables in my project, it does not contain any views, stored procedures, and custom properties.

Hmm. Well, the designer deserializes, binary, the complete object graph, which contains project elements and catalog elements. If that's slow, the main cause is often a lot of elements in the catalog, e.g. thousands of procs, thousands of tables etc. Even if you map just 10 entities, if you have 1000 procs and 1000 tables, loading it will be slow.

Like I said, it doesn't have to be slow, if you want me to have a look, please mail me the .lgp file: support AT llblgen.com (you can zip the .lgp file).

Frans Bouma | Lead developer LLBLGen Pro