连接指定表的指定字符串字段的stored procedure




 OBJECT_ID()   
      strcat
GO

  strcat
    @cTable NVarChar(),
    @cField NVarChar(),
    @cRet NVarChar() OutPut
 Encryption

    DECLARE @cSQLText NVARCHAR()

    EXEC master..xp_sprintf @cSQLText Output,



,  @cField, @cTable

     @cRet = 
    EXEC sp_executesql @cSQLText, N, @cRet Output

     @cRet = STUFF(@cRet, , , )
GO

DECLARE @str NVARCHAR()
 @str = 
EXEC strcat , , @str OUTPUT
PRINT @str

  strcat
Go
阅读更多
想对作者说点什么?

博主推荐

换一批

没有更多推荐了,返回首页