Sample Questions Best site for GRE, LSAT, SAT, GMAT, TOEFL, CCNA, CCSA and interview sample questions  

Technical Sample Questions : C |  C++ |  Oracle |  Java | Unix |  Operating Systems |  Data Structure

Oracle Sample Questions ›› Oracle SQL

Technical Sample Questions

Oracle Sample Questions : Oracle SQL

  1. What are the Large object types suported by Oracle?

    Answer: Blob and Clob.

  2. Difference between a "where" clause and a "having" clause.

    Answer: Having clause is used only with group functions whereas Where is not used with.

  3. What's the difference between a primary key and a unique key?

    Answer: Both primary key and unique enforce uniqueness of the column on which they are defined.But by default primary key creates a clustered index on the column, where are unique creates a nonclustered index by default.Another major difference is that, primary key doesn't allow NULLs, but unique key allows one NULL only.

  4. What are cursors? Explain different types of cursors.What are the disadvantages of cursors? How can you avoid cursors?

    Answer: Cursors allow row-by-row prcessing of the resultsets.Types of cursors: Static, Dynamic, Forward-only, Keyset-driven.See books online for more information.Disadvantages of cursors: Each time you fetch a row from the cursor, it results in a network roundtrip, where as a normal SELECT query makes only one rowundtrip, however large the resultset is.Cursors are also costly because they require more resources and temporary storage (results in more IO operations).Furthere, there are restrictions on the SELECT statements that can be used with some types of cursors.Most of the times, set based operations can be used instead of cursors.

  5. What are triggers? How to invoke a trigger on demand?

    Answer: Triggers are special kind of stored procedures that get executed automatically when an INSERT, UPDATE or DELETE operation takes place on a table.Triggers can't be invoked on demand.They get triggered only when an associated action (INSERT, UPDATE, DELETE) happens on the table on which they are defined.Triggers are generally used to implement business rules, auditing.Triggers can also be used to extend the referential integrity checks, but wherever possible, use constraints for this purpose, instead of triggers, as constraints are much faster.

  6. What is a join and explain different types of joins.

    Answer: Joins are used in queries to explain how different tables are related.Joins also let you select data from a table depending upon data from another table.Types of joins: INNER JOINs, OUTER JOINs, CROSS JOINs.OUTER JOINs are further classified as LEFT OUTER JOINS, RIGHT OUTER JOINS and FULL OUTER JOINS.

  7. What is a self join?

    Answer: Self join is just like any other join, except that two instances of the same table will be joined in the query.

  8. How can I eliminate duplicates values in a table?

    Answer: SQL> DELETE FROM table_name A WHERE ROWID > (SELECT min(rowid) FROM table_name B WHERE A.key_values = B.key_values);

  9. How can one examine the exact content of a database column?

    Answer: SELECT DUMP(col1)

    FROM tab1

    WHERE cond1 = val1;


    Typ=96 Len=4: 65,66,67,32

    For this example the type is 96, indicating CHAR, and the last byte in the column is 32, which is the ASCII code for a space.This tells us that this column is blank-padded.

  10. How can I change my Oracle password?

    Answer: From SQL*Plus type: ALTER USER username IDENTIFIED BY new_password

« Previous || Next »

Oracle SQL Sample Question Number: 1-10| 11-20| 21-28
Sample Test Questions
GRE Sample Questions
CAT Sample Questions
GMAT Sample Questions
TOEFL Sample Questions
ACT Sample Questions
SAT Sample Questions
LSAT Sample Questions
PSAT Sample Questions
MCAT Sample Questions
PMP Sample Questions
GED Sample Questions
ECDL Sample Questions
DMV Sample Questions
CCNA Sample Questions
MCSE Sample Questions
Network+ Sample Questions
A+ Sample Questions
Technical Sample Questions
WASL Sample Questions
CISA Sample Questions

Other Sample Questions
Sample Interview Questions
Sample Teacher Interview Questions
Sample Citizenship Questions
Accuplacer Sample Questions
Science Bowl sample Questions
Driving Test Sample Questions
Sample Survey Questions Sample Essay Questions
Sample Behavioral Interview Questions

Copyright © 2004-2013, Best BSQ. All Rights Reserved.