然后加载SchemaExplorer组件,并导入SchemaExplorer命名空间,看这里是不是和asp.net很像
<%@ Assembly Name="SchemaExplorer" %>
<%@ Import Namespace="SchemaExplorer" %>接下来声明变量,因为要从数据库表中读取框架所以 Type 属性为SchemaExplorer.TableSchema
<%@ Property Name="SourceTable" Type="SchemaExplorer.TableSchema" Category="Context" Description="Table that the stored procedures should be based on." %>
下面就要写实际将要输出代码部分的模板了。
先写存储过程的第一行 ,<%%>内为引用前面声明变量名,代表表名
CREATE PROCEDURE dbo.Update<%=SourceTable.Name %>