Posts

pdb quota exceeded

 SELECT owner, segment_name, segment_type, bytes FROM dba_segments WHERE tablespace_name = 'your_tablespace_name' ORDER BY bytes DESC; select tablespace_name,username,bytes/1024/1024,max_bytes/1024/1024 from dba_ts_quotas where username='DBACLASS'; SELECT owner, sum(bytes)/1024/1024/1024 as GB FROM dba_segments GROUP BY owner ORDER BY GB DESC SELECT owner, sum(bytes)/1024/1024/1024 as GB FROM dba_segments GROUP BY owner ORDER BY GB DESC; How to determine index size ======================== Size of INDEX select segment_name,sum(bytes)/1024/1024/1024 as "SIZE in GB" from user_segments where segment_name='INDEX_NAME' group by segment_name; OR select owner,segment_name,sum(bytes)/1024/1024/1024 as "SIZE in GB" from dba_segments where owner='SCHEMA_NAME' and segment_name='INDEX_NAME' group by owner,segment_name; List of Size of all INDEXES of a USER =============================== select segment_name,sum(bytes)/1024/1024/1024 as ...

create table and insert laks of records using loop statement

  CREATE TABLE employees (     emp_id      NUMBER PRIMARY KEY,     first_name  VARCHAR2(50),     last_name   VARCHAR2(50),     email       VARCHAR2(100),     hire_date   DATE,     salary      NUMBER(10, 2) ); INSERT INTO employees (emp_id, first_name, last_name, email, hire_date, salary) VALUES (1, 'John', 'Doe', 'john.doe@example.com', TO_DATE('2023-01-15', 'YYYY-MM-DD'), 55000); INSERT INTO employees (emp_id, first_name, last_name, email, hire_date, salary) VALUES (2, 'Jane', 'Smith', 'jane.smith@example.com', TO_DATE('2023-02-20', 'YYYY-MM-DD'), 60000); DECLARE     v_max_id NUMBER; BEGIN     -- Find the current max emp_id to avoid duplicates     SELECT NVL(MAX(emp_id), 0) INTO v_max_id FROM employees;     FOR i IN 1..100000 LOOP         INSERT INTO employees (emp_id, first_name, last_nam...

Goldengate interview questions

  Oracle Golden Gate is a robust real-time data integration and replication solution, offering high availability, data integration, change data capture, and data replication capabilities across heterogeneous IT environments. The 19c version emphasizes extreme performance, simplified configuration, and enhanced integration with Oracle Database, while also extending support for cloud environments and ensuring advanced security. Additionally, Oracle provides complementary tools like Oracle Golden Gate Veridata for high-speed data comparison and verification between databases. With its versatility and capabilities, Oracle Golden Gate plays a crucial role in ensuring real-time data consistency and availability in complex enterprise systems.   1. What exactly is Oracle GoldenGate? Ans: Oracle Golden Gate is a data replication and integration solution that enables the real-time movement and synchronization of data between different databases, whether they are Oracle databases o...