PL/SQL Flashcards
Basic LOOP
LOOP
EXIT WHEN
END LOOP
For LOOP
FOR cont IN 1..100
LOOP
END LOOP
While LOOP
WHILE
LOOP
END LOOP
Compound queries, SET operators
UNION
UNION ALL
INTERSECT
MINUS
JOIN tables
INNER
OUTER
SQLERRM, come si usa?
Nelle eccezioni per stampare il messaggio di errore
Qual’è la differenza tra INSTR e SUBSTR?
INSTR estrae l’indice di inizio della stringa ricercata
SUBSTR estrae la stringa
Semijoin
Where exists
Come gestire gli errori in pl/sql
DECLARE ... BEGIN ... EXCEPTION WHEN exception1 THEN ... WHEN exception2 THEN ... WHEN others THEN ... END;
Cosa sono i Constraints
This is the most common Oracle Interview Questions asked in an interview. Constraints are the rules defined over data. Named constraint for a primary key can be added in two ways: 1. During table creation: CREATE TABLE Employees ( Eid int NOT NULL, Name varchar(255) NOT NULL, Salary number(8), Age int, CONSTRAINT PK_ID PRIMARY KEY (Eid) );
- In the Alter statement
ALTER TABLE Employees
ADD CONSTRAINT PK_ID PRIMARY KEY (Eid);
Null in equality expression
Si usa IS NULL e non
= NULL
Nested table
Specifico data type che contiene record di una tabella
VARRAY
Varray
Operatore q[]
Q[]
Tipi di istruzioni SQL
The five types of SQL statements are:
Data Definition Language (DDL): CREATE, DROP, RENAME, ALTER, TRUNCATE
Data Manipulation Language (DML): INSERT, DELETE, UPDATE, MERGE
Data Control Language (DCL): GRANT, REVOKE
Data Retrieval: SELECT
Transaction Control Statements: COMMIT, SAVEPOINT, ROLLBACK