Oracle Database 26ai will be available on generic Linux platforms in January and soon on AIX and Windows
Purpose
Internal support utilities for Data Guard Logical Standby Databases
AUTHID
DEFINER
Dependencies
SELECT name FROM dba_dependencies WHERE referenced_name = 'DBMS_INTERNAL_LOGSTDBY' UNION
SELECT referenced_name FROM dba_dependencies WHERE name = 'DBMS_INTERNAL_LOGSTDBY'
ORDER BY 1;
dbms_internal_logstdby.enable_logical_replication(repl_state IN BOOLEAN);
DECLARE
retVal BOOLEAN := dbms_internal_logstdby.disable_logical_replication;
BEGIN
IF retVal THEN
dbms_output.put_line('TRUE');
ELSE
dbms_output.put_line('FALSE');
END IF;
END;
/ TRUE
DECLARE
retVal BOOLEAN := dbms_internal_logstdby.disable_logical_replication;
BEGIN
IF retVal THEN
dbms_output.put_line('TRUE');
ELSE
dbms_output.put_line('FALSE');
END IF;
END;
/ TRUE
DECLARE
retVal BOOLEAN := dbms_internal_logstdby.disable_logical_replication;
BEGIN
IF retVal THEN
dbms_output.put_line('TRUE');
ELSE
dbms_output.put_line('FALSE');
END IF;
END;
/ FALSE
dbms_internal_logstdby.is_lsdby_supportable(
owner IN VARCHAR2,
table_name IN VARCHAR2)
RETURN BOOLEAN;
BEGIN
IF dbms_internal_logstdby.is_lsby_supportable(USER, 'OBJ$') THEN
dbms_output.put_line('Logical Standby Supportable');
ELSE
dbms_output.put_line('Not Logical Standby Supportable');
END IF;
END;
/ Not Logical Standby Supportable
BEGIN
IF dbms_internal_logstdby.is_pdb_root THEN
dbms_output.put_line('Current container is CDB$ROOT');
ELSE
dbms_output.put_line('Current container is ' || SYS_CONTEXT('USERENV','CON_NAME'));
END IF;
END;
/ Current container is CDB$ROOT
PL/SQL procedure successfully completed.
ALTER SESSION SET CONTAINER = PDBDEV;
BEGIN
IF dbms_internal_logstdby.is_pdb_root THEN
dbms_output.put_line('Current container is CDB$ROOT');
ELSE
dbms_output.put_line('Current container is ' || SYS_CONTEXT('USERENV','CON_NAME'));
END IF;
END;
/
PL/SQL procedure successfully completed.
-- unfortunately another example of Oracle doing EXCEPTION WHEN OTHERS THEN NULL