SQL Server Transact Basic to Expert - Query to refresh a View Definition as module

This blog show how to query and refresh a view definition using the query analyer and its not only used for Views but also can be used for Stored procedures, functions etc

Syntax:

EXEC sys.sp_refreshsqlmodule  @name =  'Schema.ViewName'


Example:

EXEC sys.sp_refreshsqlmodule  @name =  'dbo.vemptable'