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.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 Table

Author  Topic 

BankOfficerHere
Posting Yak Master

124 Posts

Posted - 2008-08-25 : 04:47:07
I'm not sure if I'm correct. Every time you change something on the table. Like changing one from nvarchar to int. It won't automatically change the views related to the table.

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2008-08-25 : 05:14:11
yup. you need views to be refreshed after modifying base tables.
Go to Top of Page

BankOfficerHere
Posting Yak Master

124 Posts

Posted - 2008-08-25 : 05:17:29
yes I did do that but still it didn't change. Is there something wrong?
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2008-08-25 : 05:23:30
how did you know it didnt changed? you checked the definition?
Go to Top of Page

BankOfficerHere
Posting Yak Master

124 Posts

Posted - 2008-08-25 : 05:25:28
how can i check the definition? i'm just checking it using the front end.
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2008-08-25 : 05:31:28
sp_help viewname
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2008-08-25 : 05:32:57
Also you could refresh views explicitly using

sp_refreshview yourviewname
Go to Top of Page

BankOfficerHere
Posting Yak Master

124 Posts

Posted - 2008-08-25 : 05:37:30
how do i know if it's correctly changed?
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2008-08-25 : 06:08:43
check the definition with sp_help viewname and see if columns data type has changed from nvarchar to int.
Go to Top of Page
   

- Advertisement -