Oracle-Procedures 是否会逐步执行所有订单?
嘿嘿,
我正在尝试设置一个过程,例如:
Create or Replace Procedure MyProcedure1(
x in number default 1,
y in number default 1
)
AS
Begin
If x = 1 then
MyProcedure2;
EndIf;
If y = 1 then
MyProcedure3
EndIf;
End MyProcedure1;
MyProcedure3 必须在 MyProcedure2 完全完成后完成,因为它需要由 MyProcedure2 设置的一些值(其中包含一些函数)。 那么Oracle是否会先完全运行MyProcedure2,然后再继续运行MyProcedure1呢?
Heyho,
I'm trying to set a Procedure like:
Create or Replace Procedure MyProcedure1(
x in number default 1,
y in number default 1
)
AS
Begin
If x = 1 then
MyProcedure2;
EndIf;
If y = 1 then
MyProcedure3
EndIf;
End MyProcedure1;
MyProcedure3 must be done after MyProcedure2 is completely done, because it needs some values which are set by MyProcedure2 (which has some functions included).
So does Oracle first runs MyProcedure2 completely before it continues running MyProcedure1?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
是的,MyProcedure2 将在控制权返回到 MyProcedure1 之前运行完成,然后 MyProcedure1 可以继续运行 MyProcedure3。同样,MyProcedure2 调用的任何函数都将在 MyProcedure2 返回之前运行完成。
Yes, MyProcedure2 will run to completion before control returns to MyProcedure1, which can then go on to run MyProcedure3. Similarly, any functions called by MyProcedure2 will run to completion before MyProcedure2 returns.