DECLARE
seq_exists_ NUMBER;
sql_stmt_ VARCHAR2(2000);
CURSOR check_exists IS
SELECT 1
FROM all_objects
WHERE object_name = 'METADATA_ID_SEQ'
AND object_type = 'SEQUENCE';
BEGIN
OPEN check_exists;
FETCH check_exists INTO seq_exists_;
IF (check_exists%NOTFOUND) THEN
seq_exists_ := 0;
END IF;
CLOSE check_exists;
IF (seq_exists_ = 0) THEN
Database_SYS.Create_Sequence('METADATA_ID_SEQ', 'MINVALUE 1 START WITH 1 INCREMENT BY 1');
END IF;
END;
/
top of page
Related Posts
See All[FndWindowRegistration("YVVDA_COMPANY_ADDR", "YvvdaCompanyAddr", FndWindowRegistrationFlags.HomePage)] [FndDynamicTabPage("frmCompanyAddr...
40
Example 1: SELECT DISTINCT LISTAGG(t.commission_receiver, ';') WITHIN GROUP (ORDER BY t.commission_receiver) FROM...
20
FUNCTION Strip_Ora_Error ( sqlerrm_ IN VARCHAR2, sqlcode_ IN NUMBER DEFAULT NULL, strip_ora_only_ IN BOOLEAN DEFAULT...
10
bottom of page
Comments