Входные параметры
Параметр | Тип | Описание |
---|---|---|
CLASSID |
INTEGER |
|
GRADEBASISID |
INTEGER |
|
BASISVALUE |
NUMERIC(9,2) |
|
Выходные параметры
(Нет выходных параметров)
Описание
(Нет описания для процедуры LAB_GRADE_BASIS_EDIT)
Определение
CREATE PROCEDURE LAB_GRADE_BASIS_EDIT(
CLASSID INTEGER,
GRADEBASISID INTEGER,
BASISVALUE NUMERIC(9,2))
AS
begin
if (:classid is not null and :basisvalue is not null and :basisvalue <> 0) then begin
update gradebasisclass
set basisvalue = :basisvalue
where classid = :classid
and gradebasisid = :gradebasisid;
if (row_count = 0) then
insert into gradebasisclass(gradebasisid, classid, basisvalue)
values (:gradebasisid, :classid, :basisvalue);
end
else begin
delete from gradebasisclass
where classid = :classid and gradebasisid = :gradebasisid;
end
end