将XML变量从一个SP传递到另一个SP [英] passing an XML variable from one SP to Another
本文介绍了将XML变量从一个SP传递到另一个SP的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在尝试使用局部变量将值从一个Sp传递到另一个SP.
Hi ,
I am trying to pass value from one Sp to another SP USING A Local variable.
create proc pp
as
declare @aa xml
begin
set @aa= select phone no from table1;
exec stordproc2(@aa)
end
但这是行不通的.嵌套的SP不接受它.你能告诉我为什么吗?
预先感谢您的答复.
But it is not working. The nested SP is not accepting it. Can you plz tell why ?
Advance Thanks For reply.
推荐答案
谢谢您的提问.
Thank you for your question.
create proc pp
as
declare @aa xml
begin
set @aa= select phone no from table1;
SELECT @aa=[phone no] AS PhoneNo FROM table1;
EXEC stordproc2(@aa)
end
谢谢,
马蒙
Thanks,
Mamun
这篇关于将XML变量从一个SP传递到另一个SP的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文