Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
alecl
Starting Member
13 Posts |
Posted - 2002-04-10 : 11:06:35
|
| I noticed that if I have a view that does a "select * from assets" for instance and I change the # of columns in assets, it ends up not catching the change. Worse is that if I do a join and the columns change, the joined column ends up being null. All of this is fixed by simply opening the view and saving it again.IMO, it would have seemed logical to automatically recompile related views whenever a change to a table that it uses is made. Any reason that SQL Server doesn't do that? We've decided to explicitly spell out the columns used in the view to at least keep it stable, but I'm not that happy with this. |
|
|
dsdeming
479 Posts |
Posted - 2002-04-10 : 13:42:13
|
| Sometimes I think it would be nice of SQL Server would automatically recompile dependent objects, but it doesn't really bother me that it doesn't. I believe SQL Server converts 'select *' to 'select columnlist' internally to build it's query plans anyway. I usually try to avoid 'select *' as much as possible because I'm trying to minimize network traffic. |
 |
|
|
AjarnMark
SQL Slashing Gunting Master
3246 Posts |
Posted - 2002-04-10 : 14:54:44
|
| I usually just avoid using views...------------------------GENERAL-ly speaking... |
 |
|
|
|
|
|