誰かがこれで私を助けてくれたら、感謝します。OSBにストアドプロシージャを持つDBアダプタ
私はOSBでDBアダプタを使用してDBからレコードを選択すると、そのために私は以下のようであるOracleのストアドプロシージャを書かれている: - このストアドプロシージャは、そのことをやっている何
create or replace
PROCEDURE TRY_POC(ERROR_STATUS IN varchar2,TYPE_ERROR IN varchar2,ERROR_TIMESTAMP IN varchar2,p_cur out sys_refcursor) IS
BEGIN
open p_cur for
select * from CommonLogTable where STATUS=ERROR_STATUS
and ERROR_TYPE=TYPE_ERROR
and
to_date(
(
substr(Error_Timestamp,9,2)||'-'||
substr(Error_Timestamp,6,2)||'-'||
substr(Error_Timestamp,1,4)||' '||
substr(Error_Timestamp,12,2)||':'||
substr(Error_Timestamp,15,2)||':'||
substr(Error_Timestamp,18,2)
),'DD-MM-YYYY HH24:MI:SS') < to_date(to_char(current_timestamp,'DD-MM-YYYY HH24:MI:SS'),'DD-MM-YYYY HH24:MI:SS')
AND to_date(
(
substr(Error_Timestamp,9,2)||'-'||
substr(Error_Timestamp,6,2)||'-'||
substr(error_timestamp,1,4)||' '||
substr(Error_Timestamp,12,2)||':'||
substr(Error_Timestamp,15,2)||':'||
substr(Error_Timestamp,18,2)
),'DD-MM-YYYY HH24:MI:SS') >= to_date(to_char(current_timestamp-(5 * (1/24/60)),'DD-MM-YYYY HH24:MI:SS'),'DD-MM-
YYYY HH24:MI:SS');
end TRY_POC;
Status、Error_Type、Error_Timestamp(実行時に渡される)に基づいてCommonLoTableからteレコードを取得しています。
現在のタイムスタンプ=現在のタイムスタンプ-5 エラーのタイムスタンプ形式は次のとおりです2016-08-13T16:30:00のように。
実行時にすべてのError_Type、StatusおよびError_Timestampの値を渡したいとします。実行時にError_Bimestampの値をOSBから渡すことができません。アドバンス
でおかげ