Выпускная квалификационная работа бакалавра
Download 1.05 Mb. Pdf ko'rish
|
Text KarpovaEA
36 Приложение E. Реализация триггера AnalysisTrigger. (обязательное) create or replace trigger AnalysisTrigger BEFORE INSERT ON RECEPTION FOR EACH ROW DECLARE cursor AnalCursor is select Analysis.id as analysis_id from Analysis INNER JOIN Spetialization ON Spetialization.ID = Analysis.SPETIALIZATION_ID INNER JOIN Doctor ON Doctor.SPETIALIZATION_ID = Spetialization.ID where Doctor.ID = :new.doctor_id; BEGIN FOR anal_rec in AnalCursor LOOP insert into analpat(id, analysis_id, patient_id) values (analpat_seq.nextval, anal_rec.analysis_id, :new.patient_id); END LOOP; END; Document Outline
Download 1.05 Mb. Do'stlaringiz bilan baham: |
Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling
ma'muriyatiga murojaat qiling