CREATE TRIGGER delete_instance_logs BEFORE DELETE ON "DB"."ODCS"."DPU_INSTANCE" REFERENCING old AS o
{
DELETE FROM "DB"."ODCS"."LOGGING"
WHERE dpu = o.id;
DELETE FROM "DB"."ODCS"."EXEC_RECORD"
WHERE dpu_id = o.id;
DELETE FROM "DB"."ODCS"."EXEC_CONTEXT_DPU"
WHERE dpu_instance_id = o.id;
}
SQLState: 42S02
Message: SQ090: Bad table DB.ODCS.PPL_NODE in trigger delete_node_fix definition
-- workaround for bug in virtuoso's implementation of cascades on delete
-- see https://github.com/openlink/virtuoso-opensource/issues/56
CREATE TRIGGER delete_node_fix BEFORE DELETE ON "DB"."ODCS"."PPL_NODE" REFERENCING old AS n
{
DELETE FROM ppl_edge
WHERE node_from_id = n.id
OR node_to_id = n.id;
}
SQLState: 42S02
Message: SQ090: Bad table DB.ODCS.EXEC_PIPELINE in trigger update_last_change definition
CREATE TRIGGER update_last_change AFTER UPDATE ON "DB"."ODCS"."EXEC_PIPELINE" REFERENCING new AS n
{
SET triggers OFF;
UPDATE "DB"."ODCS"."EXEC_PIPELINE"
SET
t_last_change=now()
WHERE id = n.id;
}
Problem:
SQLState: 42S02 Message: SQ090: Bad table DB.ODCS.DPU_INSTANCE in trigger delete_instance_logs definition
-- TRIGGERS ######################################################
-- BEGIN VIRTUOSO ONLY
CREATE TRIGGER delete_instance_logs BEFORE DELETE ON "DB"."ODCS"."DPU_INSTANCE" REFERENCING old AS o { DELETE FROM "DB"."ODCS"."LOGGING" WHERE dpu = o.id;
}
SQLState: 42S02 Message: SQ090: Bad table DB.ODCS.PPL_NODE in trigger delete_node_fix definition
-- workaround for bug in virtuoso's implementation of cascades on delete -- see https://github.com/openlink/virtuoso-opensource/issues/56 CREATE TRIGGER delete_node_fix BEFORE DELETE ON "DB"."ODCS"."PPL_NODE" REFERENCING old AS n { DELETE FROM ppl_edge WHERE node_from_id = n.id OR node_to_id = n.id; }
SQLState: 42S02 Message: SQ090: Bad table DB.ODCS.EXEC_PIPELINE in trigger update_last_change definition
CREATE TRIGGER update_last_change AFTER UPDATE ON "DB"."ODCS"."EXEC_PIPELINE" REFERENCING new AS n { SET triggers OFF; UPDATE "DB"."ODCS"."EXEC_PIPELINE" SET t_last_change=now() WHERE id = n.id; }