新聞中心
這里有您想知道的互聯(lián)網(wǎng)營銷解決方案
Oracle存儲過程的創(chuàng)建
本人是Oracle 的熱捧者,以下的相關內容主要是我個人對于Oracle存儲過程的一個總結,其中包括儲存過程的創(chuàng)建,以及變量賦值的實際應用,以下就是文章的具體內容的描述,希望你會有所收獲。

金沙ssl適用于網(wǎng)站、小程序/APP、API接口等需要進行數(shù)據(jù)傳輸應用場景,ssl證書未來市場廣闊!成為成都創(chuàng)新互聯(lián)的ssl證書銷售渠道,可以享受市場價格4-6折優(yōu)惠!如果有意向歡迎電話聯(lián)系或者加微信:18982081108(備注:SSL證書合作)期待與您的合作!
1、創(chuàng)建存儲過程
- create or replace procedure test
(var_name_1 in type,var_name_2 out type) as
聲明變量(變量名 變量類型)
- begin
Oracle存儲過程的執(zhí)行體
- end test;
打印出輸入的時間信息
- E.g:
- create or replace procedure test(workDate in Date) is
- begin
- dbms_output.putline('The input date is:'
||to_date(workDate,'yyyy-mm-dd'));- end test;
2、變量賦值
變量名 := 值;
- E.g:
- create or replace procedure test(workDate in Date) is
- x number(4,2);
- begin
- x := 1;
- end test;
3、判斷語句
if 比較式 then begin end; end if;
- E.g
- create or replace procedure test(x in number) is
- begin
- if x >0 then
- begin
- x := 0 - x;
- end;
- end if;
- if x = 0 then
- begin
- x: = 1;
- end;
- end if;
- end test;
上述的相關內容就是對Oracle存儲過程總結的描述,希望會給你帶來一些幫助在此方面。
當前題目:Oracle存儲過程的創(chuàng)建
文章起源:http://m.fisionsoft.com.cn/article/cossjjj.html


咨詢
建站咨詢
