Skip to main content

Oracle SQL Interview Questions Series 1 [Basic]

Oracle SQL Interview Questions Series - 1

Oracle SQL Interview Questions covered in Eduflee, so complete all the series to get placed into the IT company.

At present Structured Query Language is very important to enter into the Software company.

After completing all the Interview series, you can crack many interviews with 100% assurance from my experience.

Oracle Sql Interview Questions Part 1


Basic Questions for SQL interview

  • Schema => User
  • Records => Rows
  • Fields => Columns
  • Result set => Output
1, What are the Schema Objects in Oracle SQL ?
    Table, View, Materialized view, Sequence, Synonyms, Index are the schema objects in SQL.

    Table => Basic Unit of Storage [Rows and Columns]
    View => Logical Representation of subject of records, It does not contains any data. So here data is logical.
    Materialized View =>  It contains the data, it is also called as Snapshot. It contains data physically.
    Sequence => It is a Numeric Value Generator
    Synonyms => used to provide alternate name to any object
    Index => It is used to retrieve the data easily by creating index and tuning the particular SQL query. 
    
2, What is Dual Table ?
    Dual Table is similar to a dummy table, which is used to process our own data
    
3, What is the data type used in Dual table ?
    It contain s VARCHAR2 data type in dual table.

4, SELECT * FROM dual; ?
    The above query will gives the output as "X"

5. Why Comment is used for ?
  • Comment is used as Back up
  • It is user friendly for developers, so if any changes done means with the help of 
6. Difference between Writing Order and Execution Order in Oracle SQL ? 

                                                

Writing Order

Execution Order

The writing Order is starts from 


SELECT

FROM

WHERE

GROUP BY

HAVING

ORDER

The Execution Order is starts from:-


FROM

WHERE

GROUP BY

HAVING

SELECT

ORDER


7) How to check whether the table is belongs to that owner or schema ?

By Using user_tables or all_tables , is used to check whether that table is present in that schema or not.

8) What is the mean by 'i', 'g', 'c' in Oracle version ?
   i, g, c are versions which are used in oracle, and it means that 'i' denotes the internet, 'g' denotes the grid computing and 'c' is for cloud computing.

Examples: Some of the Oracle versions are 8i, 10G, and 12C.

9) When and by whom was oracle founded ?
In the year 1977, oracle was founded by Larry Ellison, Bob Miner and Ed Oates.

10) Output for this Query : SELECT NULL + 22 FROM dual;
Answer : NULL, When Null is used with any other operator, it will shows the output as NULL.

11) Output for the below Query :
Answer : 
    SELECT COUNT(NULL) FROM dual;
    output: 0 "zero"

    SELECT COUNT(1) FROM dual;
    output: 1

    SELECT COUNT(100) FROM dual;
    output: 1

    SELECT COUNT(NULL) + 50 FROM dual;
    output: 50 

12) Difference between DBMS and RDBMS ?
    DBMS => Database management System
    It is used to access only single user. And there is no relationship between one to another or one to many data. And this DBMS is less security level when compared to RDBMS.

    RDBMS => Relational Database Management System.
    It is used to access multiple users at a time and the data related to one to one and one to many relationship model. And this RDBMS is maintained by tables [rows and columns]. It comes with high security level.

13) Where data are stored in Database ?
    Tablespace and Datafiles.
    In table space data are stored logically and in data files data are stored as a physical files.

14) How to find current date and current time using SQL ?
Sql interview questions basics


Sql Interview Questions

15) How to get the unique records in a particular column in a simple way using SQL ?

    SELECT  DISTINCT column_name FROM dual;

There are many ways to get the duplicates and distinct is one of the way to get the duplicate records.



Image Credits : Canva







Comments

Popular posts from this blog

Regular Expression in Oracle SQL

Regular Expression in Oracle SQL Regular Expression in Oracle SQL is a pattern matching technique to retrieve sort of data based on the conditions given in Oracle database. Pattern Matching is similar to functions like, replace, substring and in string which are previously seen topics. At the end of this article there will be certain task to practice for this Regular Expressions. It is very important to be very clear about this topic, this are very helpful for many interview Questions. Using regular expressions with Oracle Database: Overview Regular Expression is one of the easiest way to learn with clear understanding if one are familiar with the below Basic string matching patterns, Quantifiers, Meta characters, Functions etc. Note : The above points should understand clearly means it will be very easy to write a query. Basic String Matching with Regular Expressions | Either or  () Group \ Escape ^ Start $ Stop Literals of regular expression in oracle sql [ a b c ] a, b, c [...

Class 2 Statements in Oracle DDL

Statements in Oracle Statements in Oracle is very much important topic to understand rest other topics better, so there will be lot of important interview questions will be there in this chapter. This statements in Oracle is also called as Subset of oracle statements. Before entering in to the statements in oracle, everyone should know the basic understanding about Data types in Oracle  with that clear content will be much used to understand this subset concept will be easy to learn. Overview of Statements in Oracle At the end of this chapter you will get clear Understanding about the statements of oracle With the help of this statements, you can easily create database objects like Tables Able to create tables, columns, filling the data and merging and other privileges related parts will be seen here. DDL, DML , DCL , TCL are explained very well in this post.     POINTS TO REMEMBER: Always use underscore while naming any table or columns. Example: Instead of using custom...