在存储过程中使用SET语句。 [英] Using SET statement in stored proc.

查看:313
本文介绍了在存储过程中使用SET语句。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好我在存储过程中使用以下语句。

SET @ A = @ B + @ C- @ D

但它没有返回任何价值......

我该怎么办?写上面的陈述...

Hi I am using the following statement in stored proc.
SET @A=@B+@C-@D
But it doesn''t return any value...
how should I write the above statement...

推荐答案

这对我来说似乎没问题。你在其他变量中有什么价值?是否为Null?
That seems fine to me. What values do you have in the other variables? Are any Null?


其他变量中的值不为NULL我已经检查了这一点通过打印每个值....
The values in other variables are not NULL I have checked this By printing each and every value....


那个'很好,但它并没有给我太多的帮助。


如何设置一个使用该语句的测试存储过程,还要打印所有值。这样你就可以在存储过程和结果中发布,我可以从中确定出现了什么。
That''s good, but it doesn''t give me much to work with.

How about you set up a test Stored Procedure which uses that statement, but also PRINTs all the values. That way you can post in the Stored Procedure as well as the results, and I may be able to determine from that what is going amiss.


这篇关于在存储过程中使用SET语句。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆