InterviewSolution
This section includes InterviewSolutions, each offering curated multiple-choice questions to sharpen your knowledge and support exam preparation. Choose a topic below to get started.
| 1. |
Explain self joins in oracle? |
|
Answer» A self join means in a table each row is joined to other ROWS in the table and also to itself Here, the standard JOIN command is used in which both the tables in the join are the same tables. ExampleSELECT T2.name FROM category T1 JOIN category T2 ON T2.parent = T1.id |
|
| 2. |
What is Oracle join syntax? |
|
Answer» EXAMPLE Here is the syntax:- SELECT columns FROM table1 INNER JOIN table2 ON table1.column = table2.column; An Inner join is ALSO called a SIMPLE join, and it is the MOSTLY used join. |
|
| 3. |
Please explain oracle left join with an example? |
|
Answer» Left join returns all the RECORDS from the left-hand SIDE of the table which is specified in the ON condition, only those records from the right table where the join condition is met. Examplesyntax:- SELECT columns FROM TABLE1 LEFT JOIN table2 ON table1.column = table2.column; |
|
| 4. |
Please explain joins in oracle? |
|
Answer» When the data required by the user is in more than one table, then JOIN comes into the picture. ORACLE Join is used to combine the rows from more than one tables. Join also retrieves data from MULTIPLE tables and creates a new table. |
|
| 5. |
What is the dynamic SQL in Oracle? |
|
Answer» Dynamic SQL is the PROGRAMMING methods in which the SQL STATEMENTS are constructed at the run time. Dynamic SQL is USED when there is a requirement of the DDL(database DEFINITION language) statements while writing the programs or when the user is not aware of the compilation time of the SQL statement. |
|
| 6. |
Please explain drop constraint Oracle? |
|
Answer» DROP constraint is used for removing the constraints from the table. Syntax:- ALTER TABLE table_name DROP CONSTRAINT constraint_name ExampleFor example:- if the table NAME is INTERVIEW. QUESTIONS and the constraint name is TEST_ CONST ALTER TABLE INTERVIEW. QUESTIONS DROP CONSTRAINT TEST_ CONST |
|
| 7. |
What are the various constraints used in Oracle? |
|
Answer» Once the table is created, then the user can add any value in the table, but the values have to be VALIDATED. In this case, the CONSTRAINTS act as a validator which checks the data validity. There are five TYPES of constraints:-
|
|
| 8. |
What is translate in Oracle? |
|
Answer» The translate FUNCTION replaces the characters in a string with the new set of characters one by one. For example:- the first character in the string is replaced by the first character of the original string and so on. The translate function always RETURNS a string value. ExampleSyntax:- TRANSLATE( STRING1, string_to_replace, replacement_string ) String1:-the string which has to be replaced string_to_replace:-the string that has to be SEARCHED in the string 1 replacement_string:-the new string with which string1 will be replaced. |
|
| 9. |
How to execute the package in Oracle? |
| Answer» | |
| 10. |
What are packages in pl SQL and also explain its advantages? |
| Answer» | |
| 11. |
Please explain compound trigger in Oracle? |
|
Answer» The compound trigger was in introduced in Oracle 11g. This single trigger on a table enables the user to specify the actions for each of the four timing points:
In other words, Compound trigger MERGES all the four triggering EVENTS into the single piece of CODE, and as a result, the performance of the DATABASE server is improved during the bulk operations. The Compound trigger is only for the DML triggers. |
|
| 12. |
Write a trigger example in Oracle? |
| Answer» | |
| 13. |
What is a trigger and what are its types in Oracle? |
|
Answer» The trigger is the PROCEDURE which is IMPLICITLY executed by the Oracle SERVER when the INSERT, UPDATE, DELETE statement is executed against the associated table in the Oracle database.
Based on the EVENT these are the TYPES of trigger:-
|
|
| 14. |
What is the difference between primary key and unique key and foreign key in Oracle? |
||||||||||||||||
Answer»
|
|||||||||||||||||
| 15. |
Explain the difference between replace() and translate() functions in Oracle? |
||||||||||||
Answer»
|
|||||||||||||
| 16. |
What is the difference between substr and instr function in Oracle? |
||||||||||||
Answer»
|
|||||||||||||
| 17. |
How to convert raw data type into text in Oracle? Explain |
| Answer» | |
| 18. |
Please explain oracle data types with examples? |
Answer»
|
|
| 19. |
What do you mean by CDB and PDB in Oracle 12c? |
|
Answer» ORACLE 12c created the change in the architecture of the ORACLE DATABASE. In this VERSION CAME with the concept of the Container Database (CDB) and the Pluggable Database (PDB)
This is the favorite interviewer question in Oracle interview questions for experienced. |
|
| 20. |
Explain the difference between SAP and Oracle? |
||||||||||||
Answer»
|
|||||||||||||
| 21. |
Explain Oracle insert into command? |
|
Answer» An INSERT statement is USED in the ORACLE database to insert the single record or the multiple records in a table. This particular ORACLE INTERVIEW question explains the importance of keys in the database. ExampleSYNTAX:- INSERT INTO table (column1, column2, ... column_n ) VALUES (expression1, expression2, ... expression_n ); 11. Write a syntax for update query in Oracle?An UPDATE statement is used to update the records that already exist in the table. ExampleSYNTAX:- UPDATE table SET column1 = expression1, column2 = expression2, ... column_n = expression_n [WHERE conditions]; |
|
| 22. |
Explain the difference between delete and truncate? |
||||||||||||
Answer»
|
|||||||||||||
| 23. |
What is PL SQL and why it is used for? |
|
Answer» PL/SQL is the language which is USED to write the codes in the database. For Example - PL/SQL is used to write the ORACLE database.PL/SQL is basically to combine the SQL and the procedural feature of the programming language. This language was developed to enhance the CHARACTERISTICS of the SQL language.
Some of the features of the PL/SQL are:-
|
|
| 24. |
Explain the truncate in Oracle? |
|
Answer» The TRUNCATE STATEMENT removes all the RECORDS from the table in the ORACLE database. If once the TRUNCATE statement truncate the table then the data cannot be recovered back. ExampleSyntax:- TRUNCATE TABLE table_name |
|
| 25. |
Explain the difference between SQL and Oracle? |
||||||||||||
Answer»
|
|||||||||||||
| 26. |
Explain the features of Oracle? |
|
Answer»
Here are some of the features of the ORACLE:-
|
|
| 27. |
Who developed Oracle & when? |
|
Answer» ORACLE was developed by Lawrence Ellison and his co-workers BOB Miner and ED Oates in the year 1977. The first version ORACLEv2 was released in the year 1979 which was the |
|
| 28. |
What is Oracle latest version? |
|
Answer» The LATEST version of Oracle DATABASE is 18c. This version got RELEASED on 16TH February 2018. |
|
| 29. |
What is an Oracle and why it is used? |
|
Answer» Oracle is fundamentally a relational database management system. By using ORACLE, the user can directly access the objects through the Structured QUERY Language(SQL). Oracle is DESIGNED to support multiple data models. Oracle runs on Windows, UNIX, Linux, and Mac OS.Oracle is written in Assembly language, C & C++.
Because of the FOLLOWING reasons Oracle is the most used database software.
|
|
| 30. |
What is the new features in Oracle 12c? |
|
Answer» Here is the list of Oracle12c new features:-
|
|