Добавлена проверка ID_APP_TASK

main
Ernest Litvinenko 2024-07-05 01:09:35 +03:00
parent 826327ade0
commit 57f1ce50dc
1 changed files with 13 additions and 1 deletions

View File

@ -155,7 +155,19 @@ begin
NEW_APP_NOTE_STATUS = cast(:EXEC_BLOCK_32_NEG_1_OUT_VAL as D_INTEGER);
else
if (:EXEC_BLOCK_32_NEG_1_OUT_KEY = 'ID_APP_TASK') then
begin
if (exists(select 1
from APP_TASK T
where T.ID_APP_TASK = cast(:EXEC_BLOCK_32_NEG_1_OUT_VAL as D_BIGINT))) then
NEW_APP_NOTE_ID_APP_TASK = cast(:EXEC_BLOCK_32_NEG_1_OUT_VAL as D_BIGINT);
else
begin
output = -3;/*Не найден APP_TASK*/
suspend;
exit;
end
end
end