阅读背景:

如何使用游标在不同的数据库中创建过程

来源:互联网 

So I'm trying to make procedures in different databases. I'm not supposed to know the name of databases. I've tried to make nesting cursors, the first one to get databases' names in dynamic way and the other one to create/alter the procedures; I used EXISTS for creating a procedures and NOT EXISTS for altering them. But somehow database sticks in 'master' and it never loops over the other ones. I know there's a problem with my inner nesting cursor, though i have no idea what this is. here's my coding:So I'm trying to make procedures in different d




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: