Table -> View - What happens in Designer?

Posts   
 
    
Marcus avatar
Marcus
User
Posts: 747
Joined: 23-Apr-2004
# Posted on: 17-Oct-2006 09:53:46   

Good morning Frans!

I have come upon a performance issue with updates on some denormalised tables in our SQL Server database. I need to remove a couple of tables and replace with views of the same name and column list. (These tables are never updated via LLBLGen, they are essentially read only.)

I am confident that this change will be transparent to my stored procedures, but I am concerned about what will happen in the designer when I do a refresh...

Will the designer be clever enough to know that the table has been replaced by a view and link up the corresponding (existing) entities and their relations. Or will it see them as new objects and remove the existing table based entities?

Marcus

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39588
Joined: 17-Aug-2003
# Posted on: 17-Oct-2006 10:07:47   

It won't switch from table to view or vice versa, it will try to find the table in the set of tables or the view in the set of views. There's though a feature which allows you to manually select the new targets for orphaned entities. Set in the preferences the setting 'ManuallySelectRenamedTargetsAfterRefresh' to true. This will bring up a dialog after the refresh which allows you to select the new targets for the entities which are orphaned because the table they're mapped on wasn't found. simple_smile

Frans Bouma | Lead developer LLBLGen Pro
Marcus avatar
Marcus
User
Posts: 747
Joined: 23-Apr-2004
# Posted on: 17-Oct-2006 10:14:39   

Otis wrote:

It won't switch from table to view or vice versa, it will try to find the table in the set of tables or the view in the set of views. There's though a feature which allows you to manually select the new targets for orphaned entities. Set in the preferences the setting 'ManuallySelectRenamedTargetsAfterRefresh' to true. This will bring up a dialog after the refresh which allows you to select the new targets for the entities which are orphaned because the table they're mapped on wasn't found. simple_smile

Frans you don't need any more praise... wink so I'll just say that's perfect!