Correct Answer: - Rename : It is a permanent name provided to a table or column - Alias : It is a temporary name provided to a table or column which gets over after the execution of SQL statement
Correct Answer: Control File is used for: - Database recovery - Whenever an instance of an ORACLE database begins, its control file is used to identify the database and redo log files that must be opened for database operation to go ahead
Correct Answer: - When two processes are waiting to update the rows of a table which are locked by another process, the situation is called a deadlock - The reasons for it to happen are: * lack of proper row lock commands * Poor design of front-end application - It reduces the performance of the server severely - These locks get automatically released automatically when a commit/rollback operation is performed or any process is killed externally
Correct Answer: A synonym can be called as an alias for a table, view, sequence or program unit It is basically of two types: - Private - Only the owner can access it - Public - Can be accessed by any database user
7. What is a sub query? What are its various types?
Correct Answer: - Sub Query also termed as Nested Query or Inner Query is used to get data from multiple tables - A sub query is added in the where clause of the main query There can be two types of subqueries: a) Correlated sub query : - It can reference column in a table listed in the from list of the outer query but is not as independent as a query b) Non-Correlated sub query : - Results of this sub query are submitted to the main query or parent query - It is independent like a query
8. What are the varoius components of physical database structure of Oracle database?
Correct Answer: - The process of having a copy of redo log files is called mirroring - It is done by creating group of log files together This ensures that LGWR automatically writes them to all the members of the current on-line redo log group - In case a group fails, the database automatically switches over to the next group It diminishes the performance
10. Explain the difference between trigger and stored procedure.
Correct Answer: - A stored procedure can accept parameters while a trigger cannot - A trigger can?t return any value while stored procedures can - A trigger is executed automatically on some event while a stored procedure needs to be explicitly called - Triggers are used for insertions, update and deletions on tables while stored procedures are often using independently in the database - A trigger cannot be written in a stored procedure However, the reverse is not possible