I added a new column to a view in Microsoft SQL Server Management Studio. The data area for the modified view displayed the new column. However when I tried to run a query (e.g. SELECT * FROM uvMyNewView) against that view, it wouldn't display the new column.
I found the solution on the mssqltips website.
exec sp_refreshview [uvMyNewView]
go
select * from [uvMyNewView]
go
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With