Oracle DBA interview question

Page 1

Training Devision of 10daneces

Oracle DBA Interview question

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 1


Training Devision of 10daneces Question 1. What Is The Difference Between Rman And A Traditional Hotbackup? Answer : RMAN is faster, can do incremental (changes only) backups, and does not place tablespaces into hotbackup mode. Question 2. What Are Bind Variables And Why Are They Important? Answer : With bind variables in SQL, Oracle can cache related queries a single time in the SQL cache (area). This avoids a hard parse each time, which saves on various locking and latching resources we use to check objects existence and so on. BONUS: For rarely run queries, especially BATCH queries, we explicitely DO NOT want to use bind variables, as they hide information from the Cost Based Opitmizer. Question 3. In Pl/sql, What Is Bulk Binding, And When/how Would It Help Performance? Answer : Oracle's SQL and PL/SQL engines are separate parts of the kernel which require context switching, like between unix processes. This is slow, and uses up resources. If we loop on an SQL statement, we are implicitely flipping between these two engines. We can minimize this by loading our data into an array, and using PL/SQL bulk binding operation to do it all in one go. Question 4. Why Is Sql*loader Direct Path So Fast? Answer : SQL*Loader with direct path option can load data ABOVE the high water mark of a table, and DIRECTLY into the datafiles, without going through the SQL engine at all. This avoids all the locking, latching, and so on, and doesn't impact the db (except possibly the I/O subsystem) at all. Question 5. What Are The Tradeoffs Between Many Vs Few Indexes? When Would You Want To Have Many, And When Would It Be Better To Have Fewer? Answer : Fewer indexes on a table mean faster inserts/updates. More indexes mean faster, more specific WHERE clauses possibly without index merges.

Question 6. What Is The Difference Between Raid 5 And Raid 10? Which Is Better For Oracle? Answer : RAID 5 is striping with an extra disk for parity. If we lose a disk we can reconstruct from that parity disk. RAID 10 is mirroring pairs of disks, and then striping across those sets. RAID 5 was created when disks were expensive. Its purpose was to provide RAID on the cheap. If a disk fails, the IO subsystem will perform VERY slowly during the rebuild process. What's more your liklihood of failure increases dramatically during this period, with all the added weight of the rebuild. Even when it is operating normally RAID 5 is slow for everything but reading. Given that and knowing databases (especially Oracle's redo logs) continue to experience write activity all the time, we should avoid RAID5 in all but the rare database that is MOSTLY read activity. Don't put redologs on RAID5. RAID10 is just all around goodness. If you lose one disk in a set of 10 for example, you could lose any one of eight other disks and have no troubles. What's more rebuilding does not impact performance at all since you're simply making a mirror copy. Lastly RAID10 perform exceedingly well in all types of databases.

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 2


Training Devision of 10daneces Question 7. When Using Oracle Export/import What Character Set Concerns Might Come Up? How Do You Handle Them? Answer : Be sure to set NLS_LANG for example to "AMERCIAN_AMERICA.WE8ISO8859P1". If your source database is US7ASCII, beware of 8-bit characters. Also be wary of multi-byte characters sets as those may require extra attention. Also watch export/import for messages about any "character set conversions" which may occur. Question 8. How Do You Use Automatic Pga Memory Management With Oracle 9i And Above? Answer : Set the WORKAREA_SIZE_POLICY parameter to AUTO and set PGA_AGGREGATE_TARGET. Question 9. Explain Two Easy Sql Optimizations? Answer : EXISTS can be better than IN under various conditions. UNION ALL is faster than UNION (not sorting). Question 10. Name Three Sql Operations That Perform A Sort? Answer : CREATE INDEX. DISTINCT. GROUP BY. ORDER BY. INTERSECT. MINUS. UNION. UNINDEXED TABLE JOIN. Question 11. What Is The Difference Between Truncate And Delete? Why Is One Faster? Can We Rollback Both? How Would A Full Table Scan Behave After? Answer : Truncate is nearly instantaenous, cannot be rolled back, and is fast because Oracle simply resets the HWM. When a full table scan is performed on a table, such as for a sort operation, Oracle reads to the HWM. So if you delete every single solitary row in 10 million row table so it is now empty, sorting on that table of 0 rows would still be extremely slow. Question 12. What Is The Difference Between A Materialized View (snapshot) Fast Refresh Versus Complete Refresh? When Is One Better, And When The Other? Answer : Fast refresh maintains a change log table, which records change vectors, not unlike how the redo logs work. There is overhead to this, as with a table that has a LOT of indexes on it, and inserts and updates will be slower. However if you are performing refreshes often, like every few minutes, you want to do fast refresh so you don't have to full-tablescan the source table. Complete refresh is good if you're going to refresh once a day. Does a full table scan on the source table, and recreats the snapshot/mview. Also inserts/updates on the source table are NOT impacted on tables where complete refresh snapshots have been created. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 3


Training Devision of 10daneces Question 13. What Does The No Logging Option Do? Why Would We Use It? Why Would We Be Careful Of Using It? Answer : It disables the logging of changes to the redologs. It does not disable ALL LOGGING, however as Oracle continues to use a base of changes, for recovery if you pull the plug on the box, for instance. However it will cause problems if you are using standby database. Use it to speed up operations, like an index rebuild, or partition maintenance operations. Question 14. Explain The Difference Between A Function, Procedure And Package? Answer : A function and procedure are the same in that they are intended to be a collection of PL/SQL code that carries a single task. While a procedure does not have to return any values to the calling application, a function will return a single value. A package on the other hand is a collection of functions and procedures that are grouped together based on their commonality to a business function or application. Question 15. Explain The Use Of Table Functions? Answer : Table functions are designed to return a set of rows through PL/SQL logic but are intended to be used as a normal table or view in a SQL statement. They are also used to pipeline information in an ETL process. Question 16. Name Three Advisory Statistics You Can Collect? Answer : Buffer Cache Advice, Segment Level Statistics, & Timed Statistics. Question 17. Where In The Oracle Directory Tree Structure Are Audit Traces Placed? Answer : In unix $ORACLE_HOME/rdbms/audit, in Windows the event viewer. Question 18. Explain Materialized Views And How They Are Used? Answer : Materialized views are objects that are reduced sets of information that have been summarized, grouped, or aggregated from base tables. They are typically used in data warehouse or decision support systems. Question 19. When A User Process Fails, What Background Process Cleans Up After It? Answer : PMON. Question 20. What Background Process Refreshes Materialized Views? Answer : The Job Queue Processes. Question 21. How Would You Determine What Sessions Are Connected And What Resources They Are Waiting For? Answer : Use of V$SESSION and V$SESSION_WAIT. Question 22. Describe What Redo Logs Are? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 4


Training Devision of 10daneces Answer : Redo logs are logical and physical structures that are designed to hold all the changes made to a database and are intended to aid in the recovery of a database. Question 23. How Would You Force A Log Switch? Answer : ALTER SYSTEM SWITCH LOGFILE. Question 24. Give Two Methods You Could Use To Determine What Ddl Changes Have Been Made? Answer : You could use Logminer or Streams. Question 25. What Does Coalescing A Tablespace Do? Answer : Coalescing is only valid for dictionary-managed tablespaces and de-fragments space by combining neighboring free extents into large single extents. Question 26. What Is The Difference Between A Temporary Tablespace And A Permanent Tablespace? Answer : A temporary tablespace is used for temporary objects such as sort structures while permanent tablespaces are used to store those objects meant to be used as the true objects of the database. Question 27. Name A Tablespace Automatically Created When You Create A Database? Answer : The SYSTEM tablespace. Question 28. When Creating A User, What Permissions Must You Grant To Allow Them To Connect To The Database? Answer : Grant the CONNECT to the user. Question 29. How Do You Add A Data File To A Tablespace? Answer : ALTER TABLESPACE <tablespace_name> ADD DATAFILE <datafile_name> SIZE <size>. Question 30. How Do You Resize A Data File? Answer : ALTER DATABASE DATAFILE <datafile_name> RESIZE <new_size>. Question 31. What View Would You Use To Look At The Size Of A Data File? Answer : DBA_DATA_FILES. Question 32. What View Would You Use To Determine Free Space In A Tablespace? Answer : DBA_FREE_SPACE. Question 33. How Would You Determine Who Has Added A Row To A Table? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 5


Training Devision of 10daneces Turn on fine grain auditing for the table. Question 34. How Can You Rebuild An Index? Answer : ALTER INDEX <index_name> REBUILD. Question 35. Explain What Partitioning Is And What Its Benefit Is? Answer : Partitioning is a method of taking large tables and indexes and splitting them into smaller, more manageable pieces. Question 36. You Have Just Compiled A Pl/sql Package But Got Errors, How Would You View The Errors? Answer : SHOW ERRORS. Question 37. How Can You Gather Statistics On A Table? Answer : The ANALYZE command. Question 38. How Can You Enable A Trace For A Session? Answer : Use the DBMS_SESSION.SET_SQL_TRACE or Use ALTER SESSION SET SQL_TRACE = TRUE. Question 39. What Is The Difference Between The Sql*loader And Import Utilities? Answer : These two Oracle utilities are used for loading data into the database. The difference is that the import utility relies on the data being produced by another Oracle utility EXPORT while the SQL*Loader utility allows data to be loaded that has been produced by other utilities from different data sources just so long as it conforms to ASCII formatted or delimited files. Question 40. Name Two Files Used For Network Connection To A Database? Answer : TNSNAMES.ORA and SQLNET.ORA. Question 41. How Do You List The Files In An Unix Directory While Also Showing Hidden Files? Answer : ls -ltra. Question 42. How Do You Execute A Unix Command In The Background? Answer : Use the "&". Question 43. What Unix Command Will Control The Default File Permissions When Files Are Created? Answer : Umask. Question 44. Explain The Read, Write, And Execute Permissions On A Unix Directory? Answer : Read allows you to see and list the directory contents. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 6


Training Devision of 10daneces Write allows you to create, edit and delete files and subdirectories in the directory. Execute gives you the previous read/write permissions plus allows you to change into the directory and execute programs or shells from the directory. Question 45. What Is The Difference Between A Soft Link And A Hard Link? Answer : A symbolic (soft) linked file and the targeted file can be located on the same or different file system while for a hard link they must be located on the same file system. Question 46. Give The Command To Display Space Usage On The Unix File System? Answer : df -lk. Question 47. Explain Iostat, Vmstat And Netstat? Answer : Iostat: reports on terminal, disk and tape I/O activity. Vmstat: reports on virtual memory statistics for processes, disk, tape and CPU activity. Netstat: reports on the contents of network data structures. Question 48. How Would You Change All Occurrences Of A Value Using Vi? Answer : Use :%s/<old>/<new>/g. Question 49. Give Two Unix Kernel Parameters That Effect An Oracle Install? Answer : SHMMAX & SHMMNI. Question 50. Briefly, How Do You Install Oracle Software On Unix? Answer : Basically, set up disks, kernel parameters, and run orainst. Question 51. What Information Is Stored In Control File? Answer : Oracle Database must have at least one control file. It's a binary file contains some of the following information: The database name and unique ID. The timestamp of database creation. The names and locations of associated datafiles and redo log files. Tablespace information. Datafile offline ranges. Archived log information and history. Backup set and backup piece information. Backup datafile and redo log information. Datafile copy information. Log records: sequence numbers, SCN range in each log. RMAN Catalog. Database block corruption information. The location of the control files is specified through the control_files init param: SYS@DB1_SID SQL>show parameter control_file; NAME TYPE VALUE. control_file_record_keep_time integer 7 .

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 7


Training Devision of 10daneces control_files string /u01/app/oracle/oradata/DB1_SID. /control01.ctl, /u01/app/oracl. e/flash_recovery_area/DB1_SID/c. ontrol02.ctl.

Question 52. When You Start An Oracle Db Which File Is Accessed First? Answer : Oracle first opens and reads the initialization parameter file (init.ora) [oracle@hostname ~]$ ls -la $ORACLE_HOME/dbs/initDB1_SID.ora -rw-r--r-- 1 oracle oinstall 1023 May 10 19:27 /u01/app/oracle/product/ 11.2.0/dbs/initDB1_SID.ora. Question 53. What Is The Job Of Smon And Pmon Processes? Answer : SMON : System Monitor Process - Performs recovery after instance failure, monitors temporary segments and extents; cleans temp segments, coalesces free space (mandatory process for DB and starts by default). PMON : Process Monitor - Recovers failed process resources. In Shared Server architecture, monitors and retarts any failed dispatcher or server proceses (mandatory process for DB and starts by default). [oracle@hostname ~]$ ps -ef |grep -e pmon -e smon |grep -v grep oracle 6755 1 0 12:59 ? 00:00:05 ora_pmon_DB1_SID oracle 6779 1 0 12:59 ? 00:00:06 ora_smon_DB1_SID.

Question 54. What Is Instance Recovery? Answer : While Oracle instance fails, Oracle performs an Instance Recovery when the associated database is being re-started. Instance recovery occurs in two steps: Cache recovery: Changes being made to a database are recorded in the database buffer cache. These changes are also recorded in online redo log files simultaneously. When there are enough data in the database buffer cache,they are written to data files. If an Oracle instance fails before the data in the database buffer cache are written to data files, Oracle uses the data recorded in the online redo log files to recover the lost data when the associated database is re-started.This process is called cache recovery. Transaction recovery: When a transaction modifies data in a database, the before image of the modified data is stored in an undo segment.The data stored in the undo segment is used to restore the original values in case a transaction is rolled back. At the time of an instance failure, the database may have uncommitted transactions. It is possible that changes made by these uncommitted transactions have gotten saved in data files. To maintain read consistency, Oracle rolls back all uncommitted transactions when the associated database is re-started.Oracle uses the undo data stored in undo segments to accomplish this.This process is called transaction recovery. Question 55. How Do You Control Number Of Datafiles One Can Have In An Oracle Database? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 8


Training Devision of 10daneces Answer : The db_files parameter is a "soft limit " parameter that controls the maximum number of physical OS files that can map to an Oracle instance. The maxdatafiles parameter is a different - "hard limit" parameter. When issuing a "create database" command, the value specified for maxdatafiles is stored in Oracle control files and default value is 32. The maximum number of database files can be set with the init parameter db_files. Question 56. How Many Maximum Datafiles Can There Be In Oracle Database? Answer : Regardless of the setting of this paramter, maximum per database: 65533 (May be less on some operating systems) Maximum number of datafiles per tablespace: OS dependent = usually 1022 Limited also by size of database blocks and by the DB_FILES initialization parameter for a particular instance Bigfile tablespaces can contain only one file, but that file can have up to 4G blocks. Question 57. What Is A Tablespace? Answer : A tablespace is a logical storage unit within an Oracle database.Tablespace is not visible in the file system of the machine on which the database resides.A tablespace, in turn, consists of at least one datafile which, in turn, are physically located in the file system of the server. A datafile belongs to exactly one tablespace. Each table, index and so on that is stored in an Oracle database belongs to a tablespace.The tablespace builds the bridge between the Oracle database and the filesystem in which the table's or index' data is stored. There are three types of tablespaces in Oracle: Permanent tablespaces. Undo tablespaces. Temporary tablespaces. Question 58. What Is The Purpose Of Redo Log Files? Answer : Before Oracle changes data in a datafile it writes these changes to the redo log. If something happens to one of the datafiles, a backed up datafile can be restored and the redo, that was written since, replied, which brings the datafile to the state it had before it became unavailable. Question 59. Which Default Database Roles Are Created When You Create A Database? Answer : CONNECT , RESOURCE and DBA are three default roles. The DBA_ROLES data dictionary view can be used to list all roles of a database and the authentication used for each role. The following query lists all the roles in the database: SELECT * FROM DBA_ROLES; ROLE PASSWORD CONNECT NO RESOURCE NO DBA NO SECURITY_ADMIN YES.

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 9


Training Devision of 10daneces Question 60. What Is A Checkpoint? Answer : A checkpoint occurs when the DBWR (database writer) process writes all modified buffers in the SGA buffer cache to the database data files. Data file headers are also updated with the latest checkpoint SCN, even if the file had no changed blocks. Checkpoints occur AFTER (not during) every redo log switch and also at intervals specified by initialization parameters. Set parameter LOG_CHECKPOINTS_TO_ALERT=TRUE to observe checkpoint start and end times in the database alert log. Checkpoints can be forced with the ALTER SYSTEM CHECKPOINT; command. SCN can refer to: System Change Number - A number, internal to Oracle that is incremented over time as change vectors are generated, applied, and written to the Redo log. System Commit Number - A number, internal to Oracle that is incremented with each database COMMIT. Question 61. Which Process Reads Data From Datafiles? Answer : Server Process - There is no background process which reads data from datafile or database buffer. Oracle creates server processes to handle requests from connected user processes. A server process communicates with the user process and interacts with Oracle to carry out requests from the associated user process. For example, if a user queries some data not already in the database buffers of the SGA, then the associated server process reads the proper data blocks from the datafiles into the SGA. Oracle can be configured to vary the number of user processes for each server process. In a dedicated server configuration, a server process handles requests for a single user process.A shared server configuration lets many user processes share a small number of server processes, minimizing the number of server processes and maximizing the use of available system resources. Question 62. Which Process Writes Data In Datafiles? Answer : Database Writer background process DBWn (20 possible) writes dirty buffers from the buffer cache to the data files.In other words, this process writes modified blocks permanently to disk. Question 63. Can You Make A Datafile Auto Extendible. If Yes, How? Answer : YES. A Datafile can be auto extendible. Here's how to enable auto extend on a Datafile: SQL>alter database datafile '/u01/app/oracle/product/10.2.0/oradata/DBSID/EXAMPLE01.DBF' autoextend on. Question 64. What Is A Shared Pool? Answer : The shared pool portion of the SGA contains the library cache, the dictionary cache, buffers for parallel execution messages, and control structures. The total size of the shared pool is determined by the initialization parameter SHARED_POOL_SIZE.

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 10


Training Devision of 10daneces The default value of this parameter is 8MB on 32-bit platforms and 64MB on 64-bit platforms. Increasing the value of this parameter increases the amount of memory reserved for the shared pool. Question 65. What Is Kept In The Database Buffer Cache? Answer : The database buffer cache is the portion of the SGA that holds copies of data blocks read from datafiles. All user processes concurrently connected to the instance share access to the database buffer cache. Question 66. What Is Difference Between Pfile And Spfile? Answer : A PFILE is a static, text file located in $ORACLE_HOME/dbs - UNIX. An SPFILE (Server Parameter File) is a persistent server-side binary file that can only be modified with the "ALTER SYSTEM SET" command. Question 67. What Is Pga_aggregate_target Parameter? Answer : PGA_AGGREGATE_TARGET: specifies the target aggregate PGA memory available to all server processes attached to the instance. Question 68. Large Pool Is Used For What? Answer : The large pool is an optional memory area and provides large memory allocations for: Session memory for the shared server and the Oracle XA interface (used where transactions interact with more than one database). I/O server processes, buffer area. Oracle backup and restore operations (RMAN). User Global Area (UGA) for shared servers. Question 69. What Is Pctfree And Pctused Setting? Answer : PCTFREE: is a block storage parameter used to specify how much space should be left in a database block for future updates. For example, for PCTFREE=10, Oracle will keep on adding new rows to a block until it is 90% full. This leaves 10% for future updates (row expansion). When using Oracle Advanced Compression, Oracle will trigger block compression when the PCTFREE is reached. This eliminates holes created by row deletions and maximizes contiguous free space in blocks. See the PCTFREE setting for a table: SQL> SELECT pct_free FROM user_tables WHERE table_name = 'EMP'; PCT_FREE ---------10

PCTUSED:is a block storage parameter used to specify when Oracle should consider a database block to be empty enough to be added to the freelist. Oracle will only insert new rows in blocks that is enqueued on the freelist. For example, if PCTUSED=40, Oracle will not add new rows to the block unless sufficient rows are deleted from the block so that it falls below 40% empty. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 11


Training Devision of 10daneces Question 70. What Is Row Migration And Row Chaining? Answer : Row Migration: Row Migration refers to rows that were moved to another blocks due to an update making them too large to fit into their original blocks. Oracle will leave a forwarding pointer in the original block so indexes will still be able to "find" the row. Note that Oracle does not discriminate between chained and migrated rows, even though they have different causes. A chained row is a row that is too large to fit into a single database data block. For example, if you use a 4KB blocksize for your database, and you need to insert a row of 8KB into it, Oracle will use 3 blocks and store the row in pieces. Some conditions that will cause row chaining are: Tables whose row size exceeds the blocksize. Tables with long and long raw columns are prone to having chained rows. ables with more then 255 columns will have chained rows as Oracle break wide tables up into pieces. Detecting row chaining: This query will show how many chained (and migrated) rows each table has: SQL>SELECT owner, table_name, chain_cnt FROM dba_tables WHERE chain_cnt > 0; To see which rows are chained: SQL>ANALYZE TABLE tablename LIST CHAINED ROWS; This will put the rows into the INVALID_ROWS table which is created by the utlvalid.sql script (located in $ORACLE_HOME/rdbms/admin). Question 71. What Is A Locally Managed Tablespace? Answer : Locally Managed Tablespace is a tablespace that record extent allocation in the tablespace header. Each tablespace manages it's own free and used space within a bitmap structure stored in one of the tablespace's data files. Advantages of Locally Managed Tablespaces: Eliminates the need for recursive SQL operations against the data dictionary (UET$ and FET$ tables). Reduce contention on data dictionary tables (single ST enqueue). Locally managed tablespaces eliminate the need to periodically coalesce free space (automatically tracks adjacent free space). Changes to the extent bitmaps do not generate rollback information. Question 72. Can You Audit Select Statements? Answer : YES. But beware, you will need a storage mechanism to hold your SQL SELECT audits, a high data volume that can exceed the size of your whole database, everyday. SQL SELECT auditing can be accomplished in several ways: Oracle audit table command: audit SELECT table by FRED by access. Oracle Fined-grained Auditing.

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 12


Training Devision of 10daneces In a busy database, the volume of the SELECT audit trail could easily exceed the size of the database every data. Plus, all data in the audit trail must also be audited to see who has selected data from the audit trail. Question 73. What Does Dbms_fga Package Do? Answer : The DBMS_FGA package provides fine-grained security functions. DBMS_FGA is a PL/SQL package used to define Fine Grain Auditing on objects. DBMS_FGA Package Subprograms: ADD_POLICY Procedure - Creates an audit policy using the supplied predicate as the audit condition. DISABLE_POLICY Procedure - Disables an audit policy. DROP_POLICY Procedure - Drops an audit policy. ENABLE_POLICY Procedure - Enables an audit policy. Question 74. What Is Cost Based Optimization? Answer : The Oracle Cost Based Optimizer (CBO) is a SQL Query optimizer that uses data statistics to identify the query plan with lowest cost before execution. The cost is based on the number of rows in a table, index efficiency, etc. All applications should be converted to use the Cost Based Optimizer as the Rule Based Optimizer is not be supported in Oracle 10g and above releases. Question 75. How Often You Should Collect Statistics For A Table? Answer : Analyse if it's necessary: Refresh STALE statistics before the batch processes run but only for tables involved in batch run. Don't do it if you don't have to. Oracle databse has default, scheduled job "gather_stats_job" that analyses stats on a daily basis during the maintenance window time. Question 76. Can You Make Collection Of Statistics For Tables Automatically? Answer : YES. Oracle databse has default, scheduled job "gather_stats_job" that analyses stats on a daily basis during the maintenance window time. There are two scheduled activities related to the collection of Oracle "statistics": AWR statistics: Oracle has an automatic method to collect AWR "snapshots" of data that is used to create elapsed-time performance reports. Optimizer statistics: Oracle has an automatic job to collect statistics to help the optimizer make intelligent decisions about the best access method to fetch the desired rows. This job can be disabled with this command: exec dbms_scheduler.disable(’SYS.GATHER_STATS_JOB’); Oracle collects optimizer statistics for SQL via the default of autostats_target = auto. Question 77. On Which Columns You Should Create Indexes? Answer : In general, you should create an index on a column in any of the following situations: The column is queried frequently. A referential integrity constraint exists on the column. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 13


Training Devision of 10daneces A UNIQUE key integrity constraint exists on the column. The following list gives guidelines in choosing columns to index: You should create indexes on columns that are used frequently in WHERE clauses. Are used frequently to join tables. Are used frequently in ORDER BY clauses. On columns that have few of the same values or unique values in the table. Question 78. What Type Of Indexes Are Available In Oracle? Answer : There are many index types within Oracle: B*Tree Indexes - common indexes in Oracle. They are similar construct to a binary tree, they provide fast access by key, to an individual row or range of rows, normally requiring very few reads to find the correct row. The B*Tree index has several subtypes: Index Organised Tables - A table stored in a B*Tree structure B*Tree Cluster Indexes - They are used to index the cluster keys Reverse Key Indexes - The bytes in the key are reversed. This is used to stop sequential keys being on the same block like 999001, 999002, 999003 would be reversed to 100999, 200999, 300999 thus these would be located on different blocks. Descending Indexes - They allow data to be sorted from big to small (descending) instead of small to big (ascending). Bitmap Indexes - With a bitmap index , a single index entry uses a bitmap to point to many rows simultaneously, they are used with low data that is mostly read-only. Schould be avoided in OLTP systems. Function Based Indexes - These are B*Tree or bitmap indexes that store the computed result of a function on a row(s) (for example sorted results)- not the column data itself. Application Domain Indexes - These are indexes you build and store yuorself, either in Oracle or outside of Oracle interMedia Text Indexes - This is a specialised index built into Oracle to allow for keyword searching of large bodies of text. Question 79. What Is B-tree Index? Answer : A B-Tree index is a data structure in the form of a tree, but it is a tree of database blocks, not rows. Question 80. A Table Is Having Few Rows, Should You Create Indexes On This Table? Answer : Small tables do not require indexes; if a query is taking too long, then the table might have grown from small to large. You can create an index on any column; however, if the column is not used in any of these situations, creating an index on the column does not increase performance and the index takes up resources unnecessarily. Question 81. A Column Is Having Many Repeated Values Which Type Of Index You Should Create On This Column, If You Have To? Answer : For example, assume there is a motor vehicle database with numerous low-cardinality columns such as car_color, car_make, car_model, and car_year. Each column contains

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 14


Training Devision of 10daneces less than 100 distinct values by themselves, and a b-tree index would be fairly useless in a database of 20 million vehicles. Question 82. When Should You Rebuilt Indexes? Answer : In 90% cases - NEVER. When the data in index is sparse (lots of holes in index, due to deletes or updates) and your query is usually range based. Also index blevel is one of the key indicators of performance of sql queries doing Index range scans. Question 83. Can You Built Indexes Online? Answer : YES. You can create and rebuild indexes online. This enables you to update base tables at the same time you are building or rebuilding indexes on that table. You can perform DML operations while the index build is taking place, but DDL operations are not allowed. Parallel execution is not supported when creating or rebuilding an index online. The following statements illustrate online index build operations: CREATE INDEX emp_name ON emp (mgr, emp1, emp2, emp3) ONLINE. Question 84. Can You See Execution Plan Of A Statement? Answer : YES. In many ways, for example from GUI based tools like TOAD, Oracle SQL Developer. Configuring AUTOTRACE, a SQL*Plus facility AUTOTRACE is a facility within SQL*Plus to show us the explain plan of the queries we've executed, and the resources they used. Once the PLAN_TABLE has been installed in the database, You can control the report by setting the AUTOTRACE system variable. SET AUTOTRACE OFF - No AUTOTRACE report is generated. This is the default. SET AUTOTRACE ON EXPLAIN - The AUTOTRACE report shows only the optimizer execution path. SET AUTOTRACE ON STATISTICS - The AUTOTRACE report shows only the SQL statement execution statistics. SET AUTOTRACE ON - The AUTOTRACE report includes both the optimizer execution path and the SQL statement execution statistics. SET AUTOTRACE TRACEONLY - Like SET AUTOTRACE ON, but suppresses the printing of the user's query output, if any. Question 85. What Is Db Buffer Cache Advisor? Answer : The Buffer Cache Advisor provides advice on how to size the Database Buffer Cache to obtain optimal cache hit ratios. Member of Performance Advisors --> Memory Advisor pack. Question 86. What Is Statspack Tool? Answer : STATSPACK: is a performance diagnosis tool provided by Oracle starting from Oracle 8i and above.STATSPACK is a diagnosis tool for instance-wide performance problems it also supports application tuning activities by providing data which identifies high-load SQL statements. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 15


Training Devision of 10daneces Although AWR and ADDM (introduced in Oracle 10g) provide better statistics than STATSPACK, users that are not licensed to use the Enterprise Manager Diagnostic Pack should continue to use statspack. Question 87. Can You Change Shared_pool_size Online? Answer : YES. That's possible. SQL>alter system set shared_pool_size=500M scope=both; System altered. It's a lot quicker to bounce the instance when changing this. Question 88. Can You Assign Priority To Users? Answer : YES. This is achievable with Oracle Resource Manager. DBMS_RESOURCE_MANAGER is the packcage to administer the Database Resource Manager. The DBMS_RESOURCE_MANAGER package maintains plans, consumer groups, and plan directives. It also provides semantics so that you may group together changes to the plan schema. Question 89. What Is The Difference Between Delete And Truncate Statements? Answer : DELETE: command is used to remove rows from a table. A WHERE clause can be used to only remove some rows. If no WHERE condition is specified, all rows will be removed. After performing a DELETE operation you need to COMMIT or ROLLBACK the transaction to make the change permanent or to undo it. DELETE will cause all DELETE triggers on the table to fire. TRUNCATE: removes all rows from a table. A WHERE clause is not permited. The operation cannot be rolled back and no triggers will be fired. As such, TRUCATE is faster and doesn't use as much undo space as a DELETE. Question 90. What Is The Difference Between Direct Path And Conventional Path Loading? Answer : A conventional path load executes SQL INSERT statements to populate tables in an Oracle database. A direct path load eliminates much of the Oracle database overhead by formatting Oracle data blocks and writing the data blocks directly to the database files. Question 91. What Is A Global Index And Local Index? Answer : Local Index :each partition of a local index is associated with exactly one partition of the table. Global Index :global index is associated with multiple partitions of the table. Oracle offers two types of global partitioned index: Global Range Partitioned Indexes. Global Hash Partitioned Indexes. Question 92. What Is The Difference Between Range Partitioning And Hash Partitioning? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 16


Training Devision of 10daneces Answer : Range Partitioning maps data to partitions based on a range of column values (e.g. a date column) Hash Partitioning maps data to partitions based on a hashing algorithm, evenly distributing data between the partitions. Question 93. What Is Difference Between Multithreaded/shared Server And Dedicated Server? Answer : Oracle Database creates server processes to handle the requests of user processes connected to an instance. A server process can be either of the following: A dedicated server process, which services only one user process. A shared server process, which can service multiple user processes. Your database is always enabled to allow dedicated server processes, but you must specifically configure and enable shared server by setting one or more initialization parameters. Question 94. Can You Import Objects From Oracle Ver. 7.3 To 9i? Answer : Different versions of the import utility are upwards compatible. This means that one can take an export file created from an old export version, and import it using a later version of the import utility. Oracle also ships some previous catexpX.sql scripts that can be executed as user SYS enabling older imp/exp versions to work (for backwards compatibility). For example, one can run $ORACLE_HOME/rdbms/admin/catexp7.sql on an Oracle 8 database to allow the Oracle 7.3 exp/imp utilities to run against an Oracle 8 database. Question 95. How Do You Move Tables From One Tablespace To Another Tablespace? Answer : There are several methods to do this; export the table, drop the table, create the table definition in the new tablespace, and then import the data (imp ignore=y). Create a new table in the new tablespace with the CREATE TABLE statement AS SELECT all from source table command. CREATE TABLE temp_name TABLESPACE new_tablespace AS SELECT * FROM source_table; Then drop the original table and rename the temporary table as the original: DROP TABLE real_table; RENAME temp_name TO real_table.

Question 96. What Are The Components Of Physical Database Structure Of Oracle Database? Answer : Oracle database is comprised of three types of files. One or more datafiles, two are more redo log files, and one or more control files.

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 17


Training Devision of 10daneces Question 97. What Are The Components Of Logical Database Structure Of Oracle Database? Answer : There are tablespaces and database's schema objects. Question 98. What Is A Tablespace? Answer : A database is divided into Logical Storage Unit called tablespaces. A tablespace is used to grouped related logical structures together. Question 99. What Is System Tablespace And When Is It Created? Answer : Every Oracle database contains a tablespace named SYSTEM, which is automatically created when the database is created. The SYSTEM tablespace always contains the data dictionary tables for the entire database. Question 100. Explain The Relationship Among Database, Tablespace And Data File? Answer : Each databases logically divided into one or more tablespaces one or more data files are explicitly created for each tablespace. Question 101. What Is Schema? Answer : A schema is collection of database objects of a user. Question 102. What Are Schema Objects? Answer : Schema objects are the logical structures that directly refer to the database's data. Schema objects include tables, views, sequences, synonyms, indexes, clusters, database triggers, procedures, functions packages and database links. Question 103. Can A Tablespace Hold Objects From Different Schemes? Answer : Yes. Question 104. What Is Oracle Table? Answer : A table is the basic unit of data storage in an Oracle database. The tables of a database hold all of the user accessible data. Table data is stored in rows and columns. Question 105. What Is An Oracle View? Answer : view is a virtual table. Every view has a query attached to it. (The query is a SELECT statement that identifies the columns and rows of the table(s) the view uses). Question 106. What Is Partial Backup ? Answer : A Partial Backup is any operating system backup short of a full backup, taken while the database is open or shut down. Question 107. What Is Mirrored On-line Redo Log ? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 18


Training Devision of 10daneces A mirrored on-line redo log consists of copies of on-line redo log files physically located on separate disks, changes made to one member of the group are made to all members. Question 108. What Is Full Backup ? Answer : A full backup is an operating system backup of all data files, on-line redo log files and control file that constitute ORACLE database and the parameter. Question 109. Can A View Based On Another View ? Answer : Yes. Question 110. Can A Tablespace Hold Objects From Different Schemes ? Answer : Yes. Question 111. Can Objects Of The Same Schema Reside In Different Tablespaces? Answer : Yes. Question 112. What Is The Use Of Control File ? Answer : When an instance of an ORACLE database is started, its control file is used to identify the database and redo log files that must be opened for database operation to proceed. It is also used in database recovery. Question 113. Do View Contain Data ? Answer : Views do not contain or store data. Question 114. What Are The Referential Actions Supported By Foreign Key Integrity Constraint ? Answer : UPDATE and DELETE Restrict - A referential integrity rule that disallows the update or deletion of referenced data. DELETE Cascade - When a referenced row is deleted all associated dependent rows are deleted. Question 115. What Are The Type Of Synonyms? Answer : There are two types of Synonyms Private and Public. Question 116. What Is A Redo Log ? Answer : The set of Redo Log files YSDATE,UID,USER or USERENV SQL functions, or the pseudo columns LEVEL or ROWNUM. Question 117. What Is An Index Segment ? Answer : Each Index has an Index segment that stores all of its data. Question 118. Explain The Relationship Among Database, Tablespace And Data File? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 19


Training Devision of 10daneces Each databases logically divided into one or more tablespaces one or more data files are explicitly created for each tablespace. Question 119. What Are The Different Type Of Segments ? Answer : Data Segment, Index Segment, Rollback Segment and Temporary Segment. Question 120. What Are Clusters ? Answer : Clusters are groups of one or more tables physically stores together to share common columns and are often used together. Question 121. What Is An Integrity Constrains ? Answer : An integrity constraint is a declarative way to define a business rule for a column of a table. Question 122. What Is An Index ? Answer : An Index is an optional structure associated with a table to have direct access to rows, which can be created to increase the performance of data retrieval. Index can be created on one or more columns of a table. Question 123. What Is An Extent ? Answer : An Extent is a specific number of contiguous data blocks, obtained in a single allocation, and used to store a specific type of information. Question 124. What Is A View ? Answer : A view is a virtual table. Every view has a Query attached to it. (The Query is a SELECT statement that identifies the columns and rows of the table(s) the view uses). Question 125. What Is Table ? Answer : A table is the basic unit of data storage in an ORACLE database. The tables of a database hold all of the user accessible data. Table data is stored in rows and columns. Question 126. Can A View Based On Another View? Answer : Yes. Question 127. What Are The Advantages Of Views? Answer : Provide an additional level of table security, by restricting access to a predetermined set of rows and columns of a table. Hide data complexity. Simplify commands for the user. Present the data in a different perspective from that of the base table. Store complex queries. Question 128. What Is An Oracle Sequence? Answer : A sequence generates a serial list of unique numbers for numerical columns of a database's tables. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 20


Training Devision of 10daneces Question 129. What Is A Synonym? Answer : A synonym is an alias for a table, view, sequence or program unit. Question 130. What Are The Types Of Synonyms? Answer : There are two types of synonyms private and public. Question 131. What Is A Private Synonym? Answer : Only its owner can access a private synonym. Question 132. What Is A Public Synonym? Answer : Any database user can access a public synonym. Question 133. What Are Synonyms Used For? Answer : Mask the real name and owner of an object. Provide public access to an object. Provide location transparency for tables, views or program units of a remote database. Simplify the SQL statements for database users. Question 134. What Is An Oracle Index? Answer : An index is an optional structure associated with a table to have direct access to rows, which can be created to increase the performance of data retrieval. Index can be created on one or more columns of a table. Question 135. How Are The Index Updates? Answer : Indexes are automatically maintained and used by Oracle. Changes to table data are automatically incorporated into all relevant indexes. Question 136. What Is Rollback Segment ? Answer : A Database contains one or more Rollback Segments to temporarily store "undo" information. Question 137. What Are The Characteristics Of Data Files ? Answer : A data file can be associated with only one database. Once created a data file can't change size. One or more data files form a logical unit of database storage called a tablespace. Question 138. How To Define Data Block Size ? Answer : A data block size is specified for each ORACLE database when the database is created. A database users and allocated free database space in ORACLE datablocks. Block size is specified in INIT.ORA file and can't be changed latter. Question 139. What Is Difference Between Unique Constraint And Primary Key Constraint ? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 21


Training Devision of 10daneces A column defined as UNIQUE can contain Nulls while a column defined as PRIMARY KEY can't contain Nulls. Question 140. What Is Index Cluster ? Answer : A Cluster with an index on the Cluster Key. Question 141. When Does A Transaction End ? Answer : When it is committed or Rollbacked. Question 142. What Is The Effect Of Setting The Value "choose" For Optimizer_goal, Parameter Of The Alter Session Command ? Answer : The Optimizer chooses Cost_based approach and optimizes with the goal of best throughput if statistics for atleast one of the tables accessed by the SQL statement exist in the data dictionary. Otherwise the OPTIMIZER chooses RULE_based approach. Question 143. What Is Cost-based Approach To Optimization ? Answer : Considering available access paths and determining the most efficient execution plan based on statistics in the data dictionary for the tables accessed by the statement and their associated clusters and indexes. Question 144. What Does Commit Do ? Answer : COMMIT makes permanent the changes resulting from all SQL statements in the transaction. The changes made by the SQL statements of a transaction become visible to other user sessions transactions that start only after transaction is committed. Question 145. What Is Read-only Transaction ? Answer : A Read-Only transaction ensures that the results of each query executed in the transaction are consistant with respect to the same point in time. Question 146. What Is A Deadlock ? Answer : Two processes wating to update the rows of a table which are locked by the other process then deadlock arises. In a database environment this will often happen because of not issuing proper row lock commands. Poor design of front-end application may cause this situation and the performance of server will reduce drastically. These locks will be released automatically when a commit/rollback operation performed or any one of this processes being killed externally. Question 147. What Is A Schema ? Answer : The set of objects owned by user account is called the schema. Question 148. What Is A Cluster Key ? Answer : The related columns of the tables are called the cluster key. The cluster key is indexed using a cluster index and its value is stored only once for multiple tables in the cluster. Question 149. What Is Parallel Server ? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 22


Training Devision of 10daneces Multiple instances accessing the same database (Only In Multi-CPU environments). Question 150. What Is Clusters ? Answer : Group of tables physically stored together because they share common columns and are often used together is called Cluster. Question 151. What Is An Index ? How It Is Implemented In Oracle Database ? Answer : An index is a database structure used by the server to have direct access of a row in a table. An index is automatically created when a unique of primary key constraint clause is specified in create table comman (Ver 7.0). Question 152. What Is A Database Instance ? Answer : A database instance (Server) is a set of memory structure and background processes that access a set of database files. The process can be shared by all users. The memory structure that are used to store most queried data from database. This helps up to improve database performance by decreasing the amount of I/O performed against data file. Question 153. What Is The Use Of Analyze Command ? Answer : To perform one of these function on an index,table, or cluster: To collect statistics about object used by the optimizer and store them in the data dictionary. To delete statistics about the object used by object from the data dictionary. To validate the structure of the object. To identify migrated and chained rows of the table or cluster. Question 154. What Is Default Tablespace ? Answer : The Tablespace to contain schema objects created without specifying a tablespace name. Question 155. What Are The System Resources That Can Be Controlled Through Profile ? Answer : The number of concurrent sessions the user can establish the CPU processing time available to the user's session the CPU processing time available to a single call to ORACLE made by a SQL statement the amount of logical I/O available to the user's session the amout of logical I/O available to a single call to ORACLE made by a SQL statement the allowed amount of idle time for the user's session the allowed amount of connect time for the user's session. Question 156. What Is Tablespace Quota ? Answer : The collective amount of disk space available to the objects in a schema on a particular tablespace. Question 157. What Are The Different Levels Of Auditing ? Answer : Statement Auditing, Privilege Auditing and Object Auditing. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 23


Training Devision of 10daneces Question 158. What Is Statement Auditing ? Answer : Statement auditing is the auditing of the powerful system privileges without regard to specifically named objects. Question 159. What Are The Database Administrators Utilities Avaliable ? Answer : SQL * DBA - This allows DBA to monitor and control an ORACLE database. SQL * Loader - It loads data from standard operating system files (Flat files) into ORACLE database tables. Export (EXP) and Import (imp) utilities allow you to move existing data in ORACLE format to and from ORACLE database. Question 160. How Can You Enable Automatic Archiving ? Answer : Shut the database. Backup the database. Modify/Include LOG_ARCHIVE_START_TRUE in init.ora file. Start up the database. Question 161. What Are Roles? How Can We Implement Roles ? Answer : Roles are the easiest way to grant and manage common privileges needed by different groups of database users. Creating roles and assigning provides to roles. Assign each role to group of users. This will simplify the job of assigning privileges to individual users. Question 162. What Are Roles ? Answer : Roles are named groups of related privileges that are granted to users or other roles. Question 163. What Is Privilege Auditing ? Answer : Privilege auditing is the auditing of the use of powerful system privileges without regard to specifically named objects. Question 164. What Is Object Auditing ? Answer : Object auditing is the auditing of accesses to specific schema objects without regard to user. Question 165. What Is A Profile ? Answer : Each database user is assigned a Profile that specifies limitations on various system resources available to the user. Question 166. How Will You Enforce Security Using Stored Procedures? Answer : Don't grant user access directly to tables within the application. Instead grant the ability to access the procedures that access the tables. When procedure executed it will execute the privilege of procedures owner. Users cannot access tables except via the procedure. Question 167. How Does One Get The View Definition Of Fixed Views/tables? Answer : Query v$fixed_view_definition. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 24


Training Devision of 10daneces Example: SELECT * FROM v$fixed_view_definition WHERE view_name= 'V$SESSION';

Question 168. What Are The Dictionary Tables Used To Monitor A Database Spaces ? Answer : DBA_FREE_SPACE. DBA_SEGMENTS. DBA_DATA_FILES. Question 169. What Is User Account In Oracle Database? Answer : An user account is not a physical structure in Database but it is having important relationship to the objects in the database and will be having certain privileges. Question 170. When Will The Data In The Snapshot Log Be Used? Answer : We must be able to create a after row trigger on table (i.e., it should be not be already available) After giving table privileges. We cannot specify snapshot log name because oracle uses the name of the master table in the name of the database objects that support its snapshot log. The master table name should be less than or equal to 23 characters. (The table name created will be MLOGS_tablename, and trigger name will be TLOGS name). Question 171. What Dynamic Data Replication? Answer : Updating or Inserting records in remote database through database triggers. It may fail if remote database is having any problem. Question 172. What Is Two-phase Commit ? Answer : Two-phase commit is mechanism that guarantees a distributed transaction either commits on all involved nodes or rolls back on all involved nodes to maintain data consistency across the global distributed database. It has two phase, a Prepare Phase and a Commit Phase. Question 173. How Can You Enforce Referential Integrity In Snapshots ? Answer : Time the references to occur when master tables are not in use. Peform the reference the manually immdiately locking the master tables. We can join tables in snopshots by creating a complex snapshots that will based on the master tables. Question 174. What Is A Sql * Net? Answer : SQL *NET is ORACLE's mechanism for interfacing with the communication protocols used by the networks that facilitate distributed processing and distributed databases. It is used in Clint-Server and Server-Server communications. Question 175. What Is A Snapshot ? Answer : Snapshots are read-only copies of a master table located on a remote node which is periodically refreshed to reflect changes made to the master table. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 25


Training Devision of 10daneces Question 176. What Is The Mechanism Provided By Oracle For Table Replication ? Answer : Snapshots and SNAPSHOT LOGs. Question 177. What Is Snapshots? Answer : Snapshot is an object used to dynamically replicate data between distribute database at specified time intervals. In ver 7.0 they are read only. Question 178. What Are The Various Type Of Snapshots? Answer : Simple and Complex. Question 179. Describe Two Phases Of Two-phase Commit ? Answer : Prepare phase - The global coordinator (initiating node) ask a participants to prepare (to promise to commit or rollback the transaction, even if there is a failure) Commit - Phase - If all participants respond to the coordinator that they are prepared, the coordinator asks all nodes to commit the transaction, if all participants cannot prepare, the coordinator asks all nodes to roll back the transaction. Question 180. What Is Snapshot Log ? Answer : It is a table that maintains a record of modifications to the master table in a snapshot. It is stored in the same database as master table and is only available for simple snapshots. It should be created before creating snapshots. Question 181. What Are The Benefits Of Distributed Options In Databases? Answer : Database on other servers can be updated and those transactions can be grouped together with others in a logical unit.Database uses a two phase commit. Question 182. What Are The Options Available To Refresh Snapshots ? Answer : COMPLETE : Tables are completely regenerated using the snapshots query and the master tables every time the snapshot referenced. FAST : If simple snapshot used then a snapshot log can be used to send the changes to the snapshot tables. FORCE : Default value. If possible it performs a FAST refresh. Otherwise it will perform a complete refresh. Question 183. What Is A Snapshot Log ? Answer : A snapshot log is a table in the master database that is associated with the master table. ORACLE uses a snapshot log to track the rows that have been updated in the master table. Snapshot logs are used in updating the snapshots based on the master table. Question 184. What Is Distributed Database ? Answer : A distributed database is a network of databases managed by multiple database servers that appears to a user as single logical database. The data of all databases in the distributed database can be simultaneously accessed and modified. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 26


Training Devision of 10daneces Question 185. How Can We Reduce The Network Traffic? Answer : Replication of data in distributed environment. Using snapshots to replicate data. Using remote procedure calls. Question 186. Differentiate Simple And Complex, Snapshots ? Answer : A simple snapshot is based on a query that does not contains GROUP BY clauses, CONNECT BY clauses, JOINs, sub-query or snashot of operations. A complex snapshots contain atleast any one of the above. Question 187. What Are The Built-ins Used For Sending Parameters To Forms? Answer : You can pass parameter values to a form when an application executes the call_form, New_form, Open_form or Run_product. Question 188. Can You Have More Than One Content Canvas View Attached With A Window? Answer : Yes. Each window you create must have atleast one content canvas view assigned to it. You can also create a window that has manipulated content canvas view. At run time only one of the content canvas views assign to a window is displayed at a time. Question 189. Is The After Report Trigger Fired If The Report Execution Fails? Answer : Yes. Question 190. Does A Before Form Trigger Fire When The Parameter Form Is Suppressed? Answer : Yes. Question 191. What Is Sga? Answer : The System Global Area in an Oracle database is the area in memory to facilitate the transfer of information between users. It holds the most recently requested structural information between users. It holds the most recently requested structural information about the database. The structure is database buffers, dictionary cache, redo log buffer and shared pool area. Question 192. What Is Mean By Program Global Area (pga)? Answer : It is area in memory that is used by a single Oracle user process. Question 193. What Is A Data Segment? Answer : Data segment are the physical areas within a database block in which the data associated with tables and clusters are stored. Question 194. What Are The Factors Causing The Reparsing Of Sql Statements In Sga? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 27


Training Devision of 10daneces Due to insufficient shared pool size.Monitor the ratio of the reloads takes place while executing SQL statements. If the ratio is greater than 1 then increase the SHARED_POOL_SIZE. Question 195. What Are Clusters? Answer : Clusters are groups of one or more tables physically stores together to share common columns and are often used together. Question 196. What Is Cluster Key? Answer : The related columns of the tables in a cluster are called the cluster key. Question 197. Do A View Contain Data? Answer : Views do not contain or store data. Question 198. What Are The Dictionary Tables Used To Monitor A Database Space? Answer : DBA_FREE_SPACE. DBA_SEGMENTS. DBA_DATA_FILES. Question 199. Can A Property Clause Itself Be Based On A Property Clause? Answer : Yes. Question 200. If A Parameter Is Used In A Query Without Being Previously Defined, What Diff. Exist Betw. Report 2.0 And 2.5 When The Query Is Applied? Answer : While both reports 2.0 and 2.5 create the parameter, report 2.5 gives a message that a bind parameter has been created. Question 201. What Are The Sql Clauses Supported In The Link Property Sheet? Answer : Where start with having. Question 202. What Is Trigger Associated With The Timer? Answer : When-timer-expired. Question 203. What Are The Trigger Associated With Image Items? Answer : When-image-activated fires when the operators double clicks on an image item whenimage pressed fires when an operator clicks or double clicks on an image item. Question 204. What Are The Different Windows Events Activated At Runtimes? Answer : When_window_activated When_window_closed When_window_deactivated When_window_resized Within this triggers, you can examine the built in system variable system. event_window to determine the name of the window for which the trigger fired. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 28


Training Devision of 10daneces Question 205. When Do You Use Data Parameter Type? Answer : When the value of a data parameter being passed to a called product is always the name of the record group defined in the current form. Data parameters are used to pass data to produts invoked with the run_product built-in subprogram. Question 206. What Is Difference Between Open_form And Call_form? Answer : when one form invokes another form by executing open_form the first form remains displayed, and operators can navigate between the forms as desired. when one form invokes another form by executing call_form, the called form is modal with respect to the calling form. That is, any windows that belong to the calling form are disabled, and operators cannot navigate to them until they first exit the called form. Question 207. What Is New_form Built-in? Answer : When one form invokes another form by executing new_form oracle form exits the first form and releases its memory before loading the new form calling new form completely replace the first with the second. If there are changes pending in the first form, the operator will be prompted to save them before the new form is loaded. Question 208. What Is The "lov Of Validation" Property Of An Item? What Is The Use Of It? Answer : When LOV for Validation is set to True, Oracle Forms compares the current value of the text item to the values in the first column displayed in the LOV. Whenever the validation event occurs. If the value in the text item matches one of the values in the first column of the LOV, validation succeeds, the LOV is not displayed, and processing continues normally. If the value in the text item does not match one of the values in the first column of the LOV, Oracle Forms displays the LOV and uses the text item value as the search criteria to automatically reduce the list. Question 209. What Is The Diff? When Flex Mode Is Mode On And When It Is Off? Answer : When flex mode is on, reports automatically resizes the parent when the child is resized. Question 210. What Is The Diff? When Confine Mode Is On And When It Is Off? Answer : When confine mode is on, an object cannot be moved outside its parent in the layout. Question 211. What Are Visual Attributes? Answer : Visual attributes are the font, color, pattern proprieties that you set for form and menu objects that appear in your application interface. Question 212. Which Of The Two Views Should Objects According To Possession? Answer : view by structure. Question 213. What Are The Vbx Controls? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 29


Training Devision of 10daneces Vbx control provide a simple method of building and enhancing user interfaces. The controls can use to obtain user inputs and display program outputs. vbx control where originally develop as extensions for the ms visual basic environments and include such items as sliders, rides and knobs. Question 214. What Is The Use Of Transactional Triggers? Answer : Using transactional triggers we can control or modify the default functionality of the oracle forms. Question 215. How Do You Create A New Session While Open A New Form? Answer : Using open_form built-in setting the session option Ex. Open_form('Stocks', active, session). when invoke the mulitiple forms with open form and call_form in the same application, state whether the following are true/False Question 216. What Are The Ways To Monitor The Performance Of The Report? Answer : Use reports profile executable statement. Use SQL trace facility. Question 217. If Two Groups Are Not Linked In The Data Model Editor, What Is The Hierarchy Between Them? Answer : Two group that is above are the left most rank higher than the group that is to right or below it. Question 218. An Open Form Can Not Be Execute The Call_form Procedure If You Chain Of Called Forms Has Been Initiated By Another Open Form? Answer : True. Question 219. Explain About Horizontal, Vertical Tool Bar Canvas Views? Answer : Tool bar canvas views are used to create tool bars for individual windows. Horizontal tool bars are display at the top of a window, just under its menu bar. Vertical Tool bars are displayed along the left side of a window. Question 220. What Is The Purpose Of The Product Order Option In The Column Property Sheet? Answer : To specify the order of individual group evaluation in a cross products. Question 221. What Is The Use Of Image_zoom Built-in? Answer : To manipulate images in image items. Question 222. What Is A Timer? Answer : Timer is an "internal time clock" that you can programmatically create to perform an action each time the times. Question 223. What Are The Two Phases Of Block Coordination? Answer : There are two phases of block coordination: The clear phase and. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 30


Training Devision of 10daneces The population phase. During, the clear phase, Oracle Forms navigates internally to the detail block and flushes the obsolete detail records. During the population phase, Oracle Forms issues a SELECT statement to repopulate the detail block with detail records associated with the new master record. These operations are accomplished through the execution of triggers. Question 224. What Are Most Common Types Of Complex Master-detail Relationships? Answer : There are three most common types of complex master-detail relationships: master with dependent details master with independent details detail with two masters Question 225. What Is A Text List? Answer : The text list style list item appears as a rectangular box which displays the fixed number of values. When the text list contains values that can not be displayed, a vertical scroll bar appears, allowing the operator to view and select undisplayed values. Question 226. What Is Term? Answer : The term is terminal definition file that describes the terminal form which you are using r20run. Question 227. What Is Use Of Term? Answer : The term file which key is correspond to which oracle report functions. Question 228. What Is Pop List? Answer : The pop list style list item appears initially as a single field (similar to a text item field). When the operator selects the list icon, a list of available choices appears. Question 229. What Is The Maximum No Of Chars The Parameter Can Store? Answer : The maximum no of chars the parameter can store is only valid for char parameters, which can be upto 64K. No parameters default to 23 Bytes and Date parameter default to 7 Bytes. Question 230. What Are The Default Extensions Of The Files Created By Library Module? Answer : The default file extensions indicate the library module type and storage format.pll pl/sql library module binary. Question 231. What Are The Coordination Properties In A Master-detail Relationship? Answer : The coordination properties are: Deferred. Auto-Query. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 31


Training Devision of 10daneces These Properties determine when the population phase of block coordination should occur. Question 232. How Do You Display Console On A Window? Answer : The console includes the status line and message line, and is displayed at the bottom of the window to which it is assigned.To specify that the console should be displayed, set the console window form property to the name of any window in the form. To include the console, set console window to Null. Question 233. What Are The Different Parameter Types? Answer : Text Parameters and, Data Parameters. Question 234. State Any Two Mouse Events System Variables? Answer : System.mouse_button_pressed, System.mouse_button_shift. Question 235. What Are The Types Of Calculated Columns Available? Answer : Summary, Formula, Placeholder column. Question 236. Explain About Stacked Canvas Views? Answer : Stacked canvas view is displayed in a window on top of, or "stacked" on the content canvas view assigned to that same window. Stacked canvas views obscure some part of the underlying content canvas view, and or often shown and hidden programmatically. Question 237. What Is The Difference Between Show_editor And Edit_textitem? Answer : Show editor is the generic built-in which accepts any editor name and takes some input string and returns modified output string. Whereas the edit_textitem built-in needs the input focus to be in the text item before the built-in is executed. Question 238. What Are The Different File Extensions That Are Created By Oracle Reports? Answer : Rep file and, Rdf file. Question 239. What Is The Basic Data Structure That Is Required For Creating An Lov? Answer : Record Group. Question 240. Does Oracle Write To Data Files In Begin/hot Backup Mode? Answer : Oracle will stop updating file headers, but will continue to write data to the database files even if a tablespace is in backup mode. In backup mode, Oracle will write out complete changed blocks to the redo log files. Normally only deltas (changes) are logged to the redo logs. This is done to enable reconstruction of a block if only half of it Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 32


Training Devision of 10daneces was backed up (split blocks). Because of this, one should notice increased log activity and archiving during on-line backups. Question 241. What Is The Maximum Allowed Length Of Record Group Column? Answer : Record group column names cannot exceed 30 characters. Question 242. Which Parameter Can Be Used To Set Read Level Consistency Across Multiple Queries? Answer : Read only. Question 243. What Are The Different Types Of Record Groups? Answer : Query Record Groups, NonQuery Record Groups, State Record Groups. Question 244. From Which Designation Is It Preferred To Send The Output To The Printed? Answer : Previewer. Question 245. What Are Difference Between Post Database Commit And Postform Commit? Answer : Post-form commit fires once during the post and commit transactions process, after the database commit occurs. The post-form-commit trigger fires after inserts, updates and deletes have been posted to the database but before the transactions have been finalized in the issuing the command. The post-database-commit trigger fires after oracle forms issues the commit to finalized transactions. Question 246. What Are The Different Display Styles Of List Items? Answer : Pop_list, Text_list, Combo box. Question 247. Which Of The Above Methods Is The Faster Method? Answer : performing the calculation in the query is faster. Question 248. With Which Function Of Summary Item Is The Compute At Options Required? Answer : percentage of total functions. Question 249. What Are Parameters? Answer : Parameters provide a simple mechanism for defining and setting the values of inputs that are required by a form at startup. Form parameters are variables of type char, number, date that you define at design time. Question 250. What Are The Three Types Of User Exits Available ? Answer : Oracle Precompiler exits, Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 33


Training Devision of 10daneces Oracle call interface, NonOracle user exits. Question 251. How Many Windows In A Form Can Have Console? Answer : Only one window in a form can display the console, and you cannot change the console assignment at runtime. Question 252. What Is An Administrative (privileged) User? Answer : Oracle DBAs and operators typically use administrative accounts to manage the database and database instance. An administrative account is a user that is granted SYSOPER or SYSDBA privileges. SYSDBA and SYSOPER allow access to a database instance even if it is not running. Control of these privileges is managed outside of the database via password files and special operating system groups. This password file is created with the orapwd utility. Question 253. What Are The Two Repeating Frame Always Associated With Matrix Object? Answer : One down repeating frame below one across repeating frame. Question 254. What Are The Master-detail Triggers? Answer : On-Check_delete_master, On_clear_details, On_populate_details. Question 255. Is It Possible To Modify An External Query In A Report Which Contains It? Answer : No. Question 256. Does A Grouping Done For Objects In The Layout Editor Affect The Grouping Done In The Data Model Editor? Answer : No. Question 257. How Does One Add Users To A Password File? Answer : One can select from the SYS.V_$PWFILE_USERS view to see which users are listed in the password file. New users can be added to the password file by granting them SYSDBA or SYSOPER privileges, or by using the orapwd utility. GRANT SYSDBA TO scott; Question 258. If A Break Order Is Set On A Column Would It Affect Columns Which Are Under The Column? Answer : No. Question 259. Do User Parameters Appear In The Data Modal Editor In 2.5? Answer : No. Question 260. Can You Pass Data Parameters To Forms? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 34


Training Devision of 10daneces Answer : No. Question 261. Is It Possible To Link Two Groups Inside A Cross Products After The Cross Products Group Has Been Created? Answer : No. Question 262. What Are The Different Modals Of Windows? Answer : Modalless windows, Modal windows. Question 263. What Are Modal Windows? Answer : Modal windows are usually used as dialogs, and have restricted functionality compared to modalless windows. On some platforms for example operators cannot resize, scroll or iconify a modal window. Question 264. What Are The Different Default Triggers Created When Master Deletes Property Is Set To Non-isolated? Answer : Master Deletes Property Resulting Triggers ---------------------------------------------------------Non-Isolated(the default) On-Check-Delete-Master, On-Clear-Details, On-Populate-Details. Question 265. What Are The Different Default Triggers Created When Master Deletes Property Is Set To Isolated? Answer : Master Deletes Property Resulting Triggers ----------------------------------------------------------Isolated On-Clear-Details, On-Populate-Details. Question 266. What Are The Different Default Triggers Created When Master Deletes Property Is Set To Cascade? Answer : Master Deletes Property Resulting Triggers ---------------------------------------------------------Cascading On-Clear-Details, On-Populate-Details, Pre-delete. Question 267. What Are The Difference Between Lov & List Item? Answer : Lov is a property where as list item is an item. A list item can have only one column, lov can have one or more columns. Question 268. What Is The Advantage Of The Library? Answer : Libraries provide a convenient means of storing client-side program units and sharing them among multiple applications. Once you create a library, you can attach it to any other form, menu, or library modules. When you can call library program units from Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 35


Training Devision of 10daneces triggers menu items commands and user named routine, you write in the modules to which you have attach the library. When a library attaches another library, program units in the first library can reference program units in the attached library. Library support dynamic loading-that is library program units are loaded into an application only when needed. This can significantly reduce the run-time memory requirements of applications. Question 269. What Is Lexical Reference? How Can It Be Created? Answer : Lexical reference is place_holder for text that can be embedded in a sql statements. A lexical reference can be created using & before the column or parameter name. Question 270. What Is System.coordination_operation? Answer : It represents the coordination causing event that occur on the master block in masterdetail relation. Question 271. What Is Synchronize? Answer : It is a terminal screen with the internal state of the form. It updates the screen display to reflect the information that oracle forms has in its internal representation of the screen. Question 272. What Use Of Command Line Parameter Cmd File? Answer : It is a command line argument that allows you to specify a file that contain a set of arguments for r20run. Question 273. What Is A Text_io Package? Answer : It allows you to read and write information to a file in the file system. Question 274. What Is Forms_ddl? Answer : Issues dynamic Sql statements at run time, including server side pl/SQl and DDL Question 275. How Is Link Tool Operation Different Between Reports 2 & 2.5? Answer : In Reports 2.0 the link tool has to be selected and then two fields to be linked are selected and the link is automatically created. In Reports 2.5 the first field is selected and the link tool is then used to link the first field to the second field. Question 276. How Do You Reference A Parameter? Answer : In Pl/Sql, You can reference and set the values of form parameters using bind variables syntax. Ex. PARAMETER name = '' or :block.item = PARAMETER Parameter name. Question 277. What Is The Difference Between Object Embedding & Linking In Oracle Forms? Answer : In Oracle forms, Embedded objects become part of the form module, and linked objects are references from a form module to a linked source file. Question 278. Name Of The Functions Used To Get/set Canvas Properties? Answer : Get_view_property, Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 36


Training Devision of 10daneces Set_view_property. Question 279. What Are The Built-in's That Are Used For Setting The Lov Properties At Runtime? Answer : get_lov_property, set_lov_property. Question 280. What Are The Built-in's Used For Processing Rows? Answer : Get_group_row_count(function), Get_group_selection_count(function), Get_group_selection(function), Reset_group_selection(procedure), Set_group_selection(procedure), Unset_group_selection(procedure). Question 281. What Are Built-in's Used For Processing Rows? Answer : GET_GROUP_ROW_COUNT(function), GET_GROUP_SELECTION_COUNT(function), GET_GROUP_SELECTION(function), RESET_GROUP_SELECTION(procedure), SET_GROUP_SELECTION(procedure), UNSET_GROUP_SELECTION(procedure). Question 282. What Are The Built-in Used For Getting Cell Values? Answer : Get_group_char_cell(function), Get_groupcell(function), Get_group_number_cell(function). Question 283. What Are The Built-in's Used For Getting Cell Values? Answer : GET_GROUP_CHAR_CELL (function), GET_GROUPCELL(function), GET_GROUP_NUMBET_CELL(function). Question 284. Atleast How Many Set Of Data Must A Data Model Have Before A Data Model Can Be Base On It? Answer : Four. Question 285. To Execute Row From Being Displayed That Still Use Column In The Row Which Property Can Be Used? Answer : Format trigger. Question 286. What Are Different Types Of Modules Available In Oracle Form? Answer : Form module - a collection of objects and code routines. Menu modules - a collection of menus and menu item commands that together make up an application menu. library module - a collection of user named procedures, functions and packages that can be called from other modules in the application. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 37


Training Devision of 10daneces Question 287. What Is The Remove On Exit Property? Answer : For a modelless window, it determines whether oracle forms hides the window automatically when the operators navigates to an item in the another window. Question 288. What Is A Difference Between Pre-select And Pre-query? Answer : Fires during the execute query and count query processing after oracle forms constructs the select statement to be issued, but before the statement is actually issued. The prequery trigger fires just before oracle forms issues the select statement to the database after the operator as define the example records by entering the query criteria in enter query mode.Pre-query trigger fires before pre-select trigger. Question 289. What Are Built-in's Associated With Timers? Answer : find_timer, create_timer, delete_timer. Question 290. What Are The Built-in's Used For Finding Object Id Functions? Answer : Find_group(function), Find_column(function). Question 291. What Are The Built-in's Used For Finding Object Id Function? Answer : FIND_GROUP(function), FIND_COLUMN(function). Question 292. Any Attempt To Navigate Programmatically To Disabled Form In A Call_form Stack Is Allowed? Answer : False. Question 293. Use The Add_group_row Procedure To Add A Row To A Static Record Group 1. True Or False? Answer : False. Question 294. How Can A Break Order Be Created On A Column In An Existing Group? What Are The Various Sub Events A Mouse Double Click Event Involves? Answer : By dragging the column outside the group. Question 295. What Is The Use Of Place Holder Column? What Are The Various Sub Events A Mouse Double Click Event Involves? Answer : A placeholder column is used to hold calculated values at a specified place rather than allowing is to appear in the actual row where it has to appear. Question 296. What Is The Use Of Hidden Column? What Are The Various Sub Events A Mouse Double Click Event Involves? Answer : A hidden column is used to when a column has to embed into boilerplate text.

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 38


Training Devision of 10daneces Question 297. What Are The Various Sub Events A Mouse Double Click Event Involves? Answer : Double clicking the mouse consists of the mouse down, mouse up, mouse click, mouse down & mouse up events. Question 298. What Are The Built-in's Used For Creating And Deleting Groups? Answer : CREATE-GROUP (function), CREATE_GROUP_FROM_QUERY(function), DELETE_GROUP(procedure). Question 299. What Are Different Types Of Canvas Views? Answer : Content canvas views, Stacked canvas views, Horizontal toolbar, vertical toolbar. Question 300. What Are The Different Types Of Delete Details We Can Establish In Master-details? Answer : Cascade, Isolate, Non-isolate. Question 301. What Is Relation Between The Window And Canvas Views? Answer : Canvas views are the back ground objects on which you place the interface items (Text items), check boxes, radio groups etc., and boilerplate objects (boxes, lines, images etc.,) that operators interact with us they run your form . Each canvas views displayed in a window. Question 302. What Is A User_exit? Answer : Calls the user exit named in the user_exit_string. Invokes a 3Gl program by name which has been properly linked into your current oracle forms executable. Question 303. How Is It Possible To Select Generate A Select Set For The Query In The Query Property Sheet? Answer : By using the tables/columns button and then specifying the table and the column names. Question 304. How Can Values Be Passed Between Precompiler Exits & Oracle Call Interface? Answer : By using the statement EXECIAFGET & EXECIAFPUT. Question 305. How Can A Square Be Drawn In The Layout Editor Of The Report Writer? Answer : By using the rectangle tool while pressing the (Constraint) key. Question 306. How Can A Text File Be Attached To A Report While Creating In The Report Writer? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 39


Training Devision of 10daneces By using the link file property in the layout boiler plate property sheet. Question 307. How Can I Message To Passed To The User From Reports? Answer : By using SRW.MESSAGE function. Question 308. How Can A Button Be Used In A Report To Give A Drill Down Facility? Answer : By setting the action associated with button to Execute pl/sql option and using the SRW.Run_report function. Question 309. Does One Need To Drop/ Truncate Objects Before Importing? Answer : Before one import rows into already populated tables, one needs to truncate or drop these tables to get rid of the old data. If not, the new data will be appended to the existing tables. One must always DROP existing Sequences before re-importing. If the sequences are not dropped, they will generate numbers inconsistent with the rest of the database. Question 310. What Is Bind Reference And How Can It Be Created? Answer : Bind reference are used to replace the single value in sql, pl/sql statements a bind reference can be created using a (:) before a column or a parameter name. Question 311. Give The Sequence Of Execution Of The Various Report Triggers? Answer : Before form , After form , Before report, Between page, After report. Question 312. Why Is It Preferable To Create A Fewer Number Of Queries In The Data Model? Answer : Because for each query, report has to open a separate cursor and has to rebind, execute and fetch data. Question 313. Where Is The External Query Executed At The Client Or The Server? Answer : At the server. Question 314. Where Is A Procedure Return In An External Pl/sql Library Executed At The Client Or At The Server? Answer : At the client. Question 315. What Is Coordination Event? Answer : Any event that makes a different record in the master block the current record is a coordination causing event. Question 316. What Is The Difference Between Ole Server & Ole Container? Answer : An Ole server application creates ole Objects that are embedded or linked in ole Containers, ex. Ole servers are ms_word & ms_excel. OLE containers provide a place to store, display and manipulate objects that are created by ole server applications. Ex. oracle forms is an example of an ole Container. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 40


Training Devision of 10daneces Question 317. What Is An Object Group? Answer : An object group is a container for a group of objects; you define an object group when you want to package related objects, so that you copy or reference them in other modules. Question 318. What Is An Lov? Answer : An LOV is a scrollable popup window that provides the operator with either a single or multi column selection list. Question 319. At What Point Of Report Execution Is The Before Report Trigger Fired? Answer : After the query is executed but before the report is executed and the records are displayed. Question 320. What Are The Built -in's Used For Modifying A Groups Structure? Answer : ADD-GROUP_COLUMN (function), ADD_GROUP_ROW (procedure), DELETE_GROUP_ROW(procedure). Question 321. What Is An User Exit Used For? Answer : A way in which to pass control (and possibly arguments ) form Oracle report to another Oracle products of 3GL and then return control ( and ) back to Oracle reports. Question 322. What Is The User-named Editor? Answer : A user named editor has the same text editing functionality as the default editor, but, because it is a named object, you can specify editor attributes such as windows display size, position, and title. Question 323. What Is A Static Record Group? Answer : A static record group is not associated with a query, rather, you define its structure and row values at design time, and they remain fixed at runtime. Question 324. What Is A Record Group? Answer : A record group is an internal Oracle Forms that structure that has a column/row framework similar to a database table. However, unlike database tables, record groups are separate objects that belong to the form module which they are defined. Question 325. What Is A Property Clause? Answer : A property clause is a named object that contains a list of properties and their settings. Once you create a property clause you can base other object on it. An object based on a property can inherit the setting of any property in the clause that makes sense for that object. Question 326. What Is A Physical Page ? & What Is A Logical Page ? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 41


Training Devision of 10daneces A physical page is a size of a page. That is output by the printer. The logical page is the size of one page of the actual report as seen in the Previewer. Question 327. What Are The Differences Between Ebu And Rman? Answer : Enterprise Backup Utility (EBU) is a functionally rich, high performance interface for backing up Oracle7 databases. It is sometimes referred to as OEBU for Oracle Enterprise Backup Utility. The Oracle Recovery Manager (RMAN) utility that ships with Oracle8 and above is similar to Oracle7's EBU utility. However, there is no direct upgrade path from EBU to RMAN. Question 328. How Do You Generate File Output From Sql? Answer : By use of the SPOOL command. Question 329. How Do You Prevent Oracle From Giving You Informational Messages During And After A Sql Statement Execution? Answer : The SET options FEEDBACK and VERIFY can be set to OFF. Question 330. How Do You Prevent Output From Coming To The Screen? Answer : The SET option TERMOUT controls output to the screen. Setting TERMOUT OFF turns off screen output. This option can be shortened to TERM. Question 331. What Is Explain Plan And How Is It Used? Answer : The EXPLAIN PLAN command is a tool to tune SQL statements. To use it you must have an explain_table generated in the user you are running the explain plan for. This is created using the utlxplan.sql script. Once the explain plan table exists you run the explain plan command giving as its argument the SQL statement to be explained. The explain_plan table is then queried to see the execution plan of the statement. Explain plans can also be run using tkprof. Question 332. What Is Tkprof And How Is It Used? Answer : The tkprof tool is a tuning tool used to determine cpu and execution times for SQL statements. Question 333. What Is The Default Ordering Of An Order By Clause In A Select Statement? Answer : Ascending. Question 334. What Is A Cartesian Product? Answer : Cartesian product is the result of an unrestricted join of two or more tables. The result set of a three table Cartesian product will have x * y * z number of rows where x, y, z correspond to the number of rows in each table involved in the join. Question 335. What Special Oracle Feature Allows You To Specify How The Cost Based System Treats A Sql Statement? Answer : The COST based system allows the use of HINTs to control the optimizer path selection. If they can give some example hints such as FIRST ROWS, ALL ROWS, USING INDEX, STAR, even better. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 42


Training Devision of 10daneces Question 336. You Want To Group The Following Set Of Select Returns, What Can You Group On? Answer : Max(sum_of_cost), min(sum_of_cost), count(item_no), item_no. The only column that can be grouped on is the "item_no" column, the rest have aggregate functions associated with them. Question 337. What Sqlplus Command Is Used To Format Output From A Select? Answer : This is best done with the COLUMN command. Question 338. How Do You Execute A Host Operating System Command From Within Sql? Answer : By use of the exclamation point "!" (in UNIX and some other OS) or the HOST (HO) command. Question 339. How Can You Call A Pl/sql Procedure From Sql? Answer : By use of the EXECUTE (short form EXEC) command. Question 340. You Want To Include A Carriage Return/linefeed In Your Output From A Sql Script, How Can You Do This? Answer : The best method is to use the CHR() function (CHR(10) is a return/linefeed) and the concatenation function "||". Another method, although it is hard to document and isn't always portable is to use the return/linefeed as a part of a quoted string. Question 341. What Are The Types Of Triggers? Answer : There are 12 types of triggers in PL/SQL that consist of combinations of the BEFORE, AFTER, ROW, TABLE, INSERT, UPDATE, DELETE and ALL key words: BEFORE ALL ROW INSERT, AFTER ALL ROW INSERT, BEFORE INSERT, AFTER INSERT etc. Question 342. How Can You Generate Debugging Output From Pl/sql? Answer : Use the DBMS_OUTPUT package. Another possible method is to just use the SHOW ERROR command, but this only shows errors. The DBMS_OUTPUT package can be used to show intermediate results from loops and the status of variables as the procedure is executed. The new package UTL_FILE can also be used. Question 343. How Can You Find Within A Pl/sql Block, If A Cursor Is Open? Answer : Use the %ISOPEN cursor status variable. Question 344. What Are Sqlcode And Sqlerrm And Why They Are Important For Pl/sql Developers? Answer : SQLCODE returns the value of the error number for the last error encountered. The SQLERRM returns the actual error message for the last error encountered. They Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 43


Training Devision of 10daneces can be used in exception handling to report, or, store in an error log table, the error that occurred in the code. These are especially useful for the WHEN OTHERS exception. Question 345. When Is A Declare Statement Needed ? Answer : The DECLARE statement is used in PL/SQL anonymous blocks such as with stand alone, nonstored PL/SQL procedures. It must come first in a PL/SQL stand alone file if it is used. Question 346. Describe The Use Of Pl/sql Tables ? Answer : PL/SQL tables are scalar arrays that can be referenced by a binary integer. They can be used to hold values for use in later queries or calculations. In Oracle 8 they will be able to be of the %ROWTYPE designation, or RECORD. Question 347. Describe The Use Of %rowtype And %type In Pl/sql? Answer : %ROWTYPE allows you to associate a variable with an entire table row. The %TYPEassociates a variable with a single column type. Question 348. What Is A Mutating Table Error And How Can You Get Around It? Answer : This happens with triggers. It occurs because the trigger is trying to update a row it is currently using. The usual fix involves either use of views or temporary tables so the database is selecting from one while updating the other. Question 349. How Is A Connection Establised By Odbc ? Answer : ODBC uses the description of the datasource available in the ODBC.INI file to load the required drivers to access that particular back end database. Question 350. What Description Of A Data Source Is Required For Odbc ? Answer : The name of the DBMS, the location of the source and the database dependent information. Question 351. What Is The Function Of A Odbc Driver ? Answer : The ODBC Driver allows the developer to talk to the back end database. Question 352. What Is The Function Of A Odbc Manager ? Answer : The ODBC Manager manages all the data sources that exists in the system. Question 353. What Are The Two Components Of Odbc ? Answer : An ODBC manager/administrator and 2. ODBC driver. Question 354. What Is Inheritance ? Answer : Inheritance is a method by which properties and methods of an existing object are automatically passed to any object derived from it. Question 355. What Is The Difference Between File Server And A Database Server ? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 44


Training Devision of 10daneces Answer : A file server just transfers all the data requested by all its client and the client processes the data while a database server runs the query and sends only the query output. Question 356. What Are The Four Types Of Events ? Answer : System Events, Control Events, User Events, Other Events. Question 357. Why Is An Event Driven Program Referred To A Passive Program ? Answer : Because an event driven program is always waiting for something to happen before processing. Question 358. What Is The Main Disadvantage Of Developing An Application Using An Api ? Answer : The application cannot use any special features of the backend server. Question 359. What Is The Main Advantage Of Developing An Application Using An Api ? Answer : The application can be connected to any back end server that is supported by the API. Question 360. What Are The Responsibilities Of A Server ? Answer : Manage resources optimally across multiple clients. Controlling database access and security. Protecting the databse and recovering it from crashes. Enforcing integrity rules globally. Question 361. What Is The First Work Of Client Process ? Answer : A client process at first establishes connection with the Server. Question 362. What Are The Different Topologies Available For Network ? Answer : Star, Bus, Ring. Question 363. What Are The Disadvantages Of The Client/server Model ? Answer : Heterogeneity of the system results in reduced reliablity, it May not be suitable for all applications. Managing and tuning networks becomes difficult. Question 364. What Are The Advantages Of Client/server Model ? Answer : Flexibility of the system, scalability, cost saving, centralised control and implementation of business rules, increase of developers productivity, portability, improved network and resource utilization. Question 365. What Are The Three Components Of A Client Server Model ? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 45


Training Devision of 10daneces A Client, A Server and A Network/Communication software. Question 366. Why Is It Better To Use An Integrity Constraint To Validate Data In A Table Than To Use A Stored Procedure ? Answer : Because an integrity constraint is automatically checked while data is inserted into a table. A stored has to be specifically invoked. Question 367. Why Are The Integrity Constraints Preferred To Database Triggers ? Answer : Because it is easier to define an integrity constraint than a database trigger. Question 368. What Is A Transaction ? Answer : A transaction is a set of operations that begin when the first DML is issued and end when a commit or rollback is issued. BEGIN COMMIT/ROLLBACK are the boundaries of a transaction. Question 369. What Are The Various Uses Of Database Triggers ? Answer : Database triggers can be used to enforce business rules, to maintain derived values and perform value-based auditing. Question 370. What Is An Integrity Constraint ? Answer : An integrity constraint allows the definition of certain restrictions, at the table level, on the data that is entered into a table. Question 371. What Is A Event Handler ? Answer : An event handler is a routine that is written to respond to a particular event. Question 372. What Are The Types Of Processes That A Server Runs ? Answer : Foreground process and, Background process. Question 373. Why Do Stored Procedures Reduce Network Traffic ? Answer : When a stored procedure is called, only the procedure call is sent to the server and not the statements that the procedure contains. Question 374. What Is Event Trigger ? Answer : An event trigger, a segment of code which is associated with each event and is fired when the event occurs. Question 375. What Does The Term Downsizing Refer To ? Answer : A host based application is re-engineered to run in smaller or LAN based environment. Question 376. What Does One Do When One Is Rightsizing ? Answer : With rightsizing, one would move applications to the most appropriate server platforms. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 46


Training Devision of 10daneces Question 377. What Does The Term Upsizing Refer To ? Answer : Applications that have outgrown their environment are re-engineered to run in a larger environment. This is upsizing. Question 378. Why Is The Most Of The Processing Done At The Sever ? Answer : To reduce the network traffic and for application sharing and implementing business rules. Question 379. In A Client Server Environment, What Would Be The Major Work That The Client Deals With? Answer : The client deals with the user interface part of the system. Question 380. What Is The Most Important Requirement For Oltp ? Answer : OLTP requires real time response. Question 381. What Does The Oltp Stands For? Answer : OLTP stands for On Line Transaction Processing. Question 382. What Does Preemptive In Preemptive Multitasking Mean ? Answer : Preemptive refers to the fact that each task is alloted fixed time slots and at the end of that time slot the next task is started. Question 383. Procedure And Functions Are Explicitly Executed. This Is Different From A Database Trigger. When Is A Database Trigger Executed? Answer : When the transaction is committed, During the data manipulation statement, When an Oracle supplied package references the trigger, During a data manipulation statement and when the transaction is committed. Question 384. Under Which Circumstance Must You Recompile The Package Body After Recompiling The Package Specification? Answer : Altering the argument list of one of the package constructs, Any change made to one of the package constructs, Any SQL statement change made to one of the package constructs, Removing a local variable from the DECLARE section of one of the package constructs. Question 385. The Check_theater Trigger Of The Theater Table Has Been Disabled. Which Command Can You Issue To Enable This Trigger? Answer : ALTER TRIGGER check_theater ENABLE; ENABLE TRIGGER check_theater; ALTER TABLE check_theater ENABLE check_theater; ENABLE check_theater; Question 386. Which Procedure Can Be Used To Create A Customized Error Message? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 47


Training Devision of 10daneces RAISE_ERROR, SQLERRM, RAISE_APPLICATION_ERROR, RAISE_SERVER_ERROR. Question 387. For Which Trigger Timing Can You Reference The New And Old Qualifiers? Answer : Statement and Row, Statement only, Row only, Oracle Forms trigger. Question 388. Which Line In The Following Statement Will Produce An Error? Answer : cursor action_cursor, select name, rate, action, into action_record, from action_table. Question 389. What Are The Advantages Of View? Answer : To protect some of the columns of a table from other users. To hide complexity of a query. To hide complexity of calculations. Question 390. What Is Cycle/no Cycle In A Sequence? Answer : CYCLE specifies that the sequence continue to generate values after reaching either maximum or minimum value. After pan-ascending sequence reaches its maximum value, it generates its minimum value. After a descending sequence reaches its minimum, it generates its maximum. NO CYCLE specifies that the sequence cannot generate more values after reaching its maximum or minimum value. Question 391. What Is A Database Link? Answer : Database link is a named path through which a remote database can be accessed. Question 392. If Unique Key Constraint On Date Column Is Created, Will It Validate The Rows That Are Inserted With Sysdate? Answer : It won't, Because SYSDATE format contains time attached with it. Question 393. How Will You Activate/deactivate Integrity Constraints? Answer : The integrity constraints can be enabled or disabled by ALTER TABLE ENABLE CONSTRAINT / DISABLE CONSTRAINT. Question 394. Where The Integrity Constraints Are Stored In Data Dictionary? Answer : The integrity constraints are stored in USER_CONSTRAINTS. Question 395. What Are The Pre-requisites To Modify Datatype Of A Column And To Add A Column With Not Null Constraint? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 48


Training Devision of 10daneces Answer : To modify the datatype of a column the column must be empty. To add a column with NOT NULL constrain, the table must be empty. Question 396. How Many Long Columns Are Allowed In A Table? Is It Possible To Use Long Columns In Where Clause Or Order By? Answer : Only one LONG column is allowed. It is not possible to use LONG column in WHERE or ORDER BY clause. Question 397. What Is Difference Between Char And Varchar2? What Is The Maximum Size Allowed For Each Type? Answer : CHAR pads blank spaces to the maximum length. VARCHAR2 does not pad blank spaces. For CHAR the maximum length is 255 and 2000 for VARCHAR2. Question 398. What Are The Data Types Allowed In A Table? Answer : CHAR, VARCHAR2, NUMBER, DATE, RAW, LONG and LONG RAW. Question 399. What Is On Delete Cascade? Answer : When ON DELETE CASCADE is specified Oracle maintains referential integrity by automatically removing dependent foreign key values if a referenced primary or unique key value is removed. Question 400. What Is The Usage Of Savepoints? Answer : SAVEPOINTS are used to subdivide a transaction into smaller parts. It enables rolling back part of a transaction. Maximum of five save points are allowed. Question 401. What Is Referential Integrity Constraint? Answer : Maintaining data integrity through a set of rules that restrict the values of one or more columns of the tables based on the values of primary key or unique key of the referenced table. Question 402. What Is An Integrity Constraint? Answer : Integrity constraint is a rule that restricts values to a column in a table. Question 403. What Is The Fastest Way Of Accessing A Row In A Table? Answer : Using ROWID. CONSTRAINTS. Question 404. What Is Rowid? Answer : ROWID is a pseudo column attached to each row of a table. It is 18 characters long, blockno, rownumber are the components of ROWID. Question 405. Explain Union, Minus, Union All And Intersect? Answer : INTERSECT - returns all distinct rows selected by both queries. MINUS - returns all distinct rows selected by the first query but not by the second. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 49


Training Devision of 10daneces UNION - returns all distinct rows selected by either query UNION ALL - returns all rows selected by either query, including all duplicates. Question 406. Explain Connect By Prior? Answer : Retrieves rows in hierarchical order eg. select empno, ename from emp where. Question 407. What Is Correlated Sub-query? Answer : Correlated sub-query is a sub-query, which has reference to the main query. Question 408. What Is The Sub-query? Answer : Sub-query is a query whose return values are used in filtering conditions of the main query. Question 409. What Is A Join? Explain The Different Types Of Joins? Answer : Join is a query, which retrieves related columns or rows from multiple tables. Self Join - Joining the table with itself. Equi Join - Joining two tables by equating two common columns. Non-Equi Join - Joining two tables by equating two common columns. Outer Join - Joining two tables in such a way that query can also retrieve rows that do not have corresponding join value in the other table. Question 410. What's An Sql Injection? Answer : SQL Injection is when form data contains an SQL escape sequence and injects a new SQL query to be run. Question 411. What Is Difference Between Truncate & Delete ? Answer : TRUNCATE commits after deleting entire table i.e., cannot be rolled back. Database triggers do not fire on TRUNCATE. DELETE allows the filtered deletion. Deleted records can be rolled back or committed. Database triggers fire on DELETE. Question 412. What Is The Parameter Substitution Symbol Used With Insert Into Command? Answer : &. Question 413. What Are The Wildcards Used For Pattern Matching.? Answer : _ for single character substitution and % for multi-character substitution. Question 414. Which Function Is Used To Find The Largest Integer Less Than Or Equal To A Specific Value? Answer : FLOOR. Question 415. What Are The Privileges That Can Be Granted On A Table By A User To Others? Answer : Insert, update, delete, select, references, index, execute, alter, all. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 50


Training Devision of 10daneces Question 416. What Operator Tests Column For The Absence Of Data? Answer : IS NULL operator. Question 417. What Is The Use Of The Drop Option In The Alter Table Command? Answer : It is used to drop constraints specified on the table. Question 418. What Operator Performs Pattern Matching? Answer : LIKE operator. Question 419. Which Date Function Is Used To Find The Difference Between Two Dates? Answer : MONTHS_BETWEEN. Question 420. Which Command Displays The Sql Command In The Sql Buffer, And Then Executes It? Answer : RUN. Question 421. What Is The Advantage Of Specifying With Grant Option In The Grant Command? Answer : The privilege receiver can further grant the privileges he/she has obtained from the owner to any other user. Question 422. Which System Tables Contain Information On Privileges Granted And Privileges Obtained? Answer : USER_TAB_PRIVS_MADE, USER_TAB_PRIVS_RECD. Question 423. Why Does The Following Command Give A Compilation Error? Answer : DROP TABLE &TABLE_NAME; Variable names should start with an alphabet. Here the table name starts with an '&' symbol. Question 424. What Is The Use Of Cascade Constraints? Answer : When this clause is used with the DROP command, a parent table can be dropped even when a child table exists. Question 425. How Does One Load Multi-line Records? Answer : One can create one logical record from multiple physical records using one of the following two clauses: CONCATENATE: - use when SQL*Loader should combine the same number of physical records together to form one logical record. CONTINUEIF - use if a condition indicates that multiple records should be treated as one. Eg. by having a '#' character in column 1. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 51


Training Devision of 10daneces Question 426. Why Is A Where Clause Faster Than A Group Filter Or A Format Trigger? Answer : Because, in a where clause the condition is applied during data retrievalthan after retrieving the data. Question 427. What Are The Triggers Available In The Reports? Answer : Before report, Before form, After form , Between page, After report. Question 428. How Can A Cross Product Be Created? Answer : By selecting the cross products tool and drawing a new group surrounding the base group of the cross products. Question 429. What Do You Mean By A Block In Forms4.0? Answer : Block is a single mechanism for grouping related items into a functional unit for storing, displaying and manipulating records. Question 430. What Are The Two Ways To Incorporate Images Into A Oracle Forms Application? Answer : Boilerplate Images. Image_items. Question 431. What Is A Display Item? Answer : Display items are similar to text items but store only fetched or assigned values. Question 432. What Are The Two Parts Of A Procedure ? Answer : Procedure Specification and Procedure Body. Question 433. What Is An Ole? Answer : Object Linking & Embedding provides you with the capability to integrate objects from many Ms- Windows applications into a single compound document creating integrated applications enables you to use the features form . Question 434. What Is The Use Of Parfile Option In Exp Command ? Answer : Name of the parameter file to be passed for export. Question 435. What Is The Optimal Parameter? Answer : It is used to set the optimal length of a rollback segment. Question 436. What Erase Package Procedure Does ? Answer : Erase removes an indicated global variable. Question 437. What Is The Difference Between Name_in And Copy ? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 52


Training Devision of 10daneces Copy is package procedure and writes values into a field. Name in is a package function and returns the contents of the variable to which you apply. Question 438. How Can You Execute The User Defined Triggers In Forms 3.0 ? Answer : Execute Trigger (trigger-name). Question 439. What Is The Use Of Break Group? What Are The Various Sub Events A Mouse Double Click Event Involves? Answer : A break group is used to display one record for one group ones. While multiple related records in other group can be displayed. Question 440. What Is An Anchoring Object & What Is Its Use? What Are The Various Sub Events A Mouse Double Click Event Involves? Answer : An anchoring object is a print condition object which used to explicitly or implicitly anchor other objects to itself. Question 441. What Is A Library? Answer : A library is a collection of subprograms including user named procedures, functions and packages. Question 442. What Is A Master Detail Relationship? Answer : A master detail relationship is an association between two base table blocks- a master block and a detail block. The relationship between the blocks reflects a primary key to foreign key relationship between the tables on which the blocks are based. Question 443. What Does The Term Panel Refer To With Regard To Pages? Answer : A panel is the no. of physical pages needed to print one logical page. Question 444. What Are The Built-ins To Display The User-named Editor? Answer : A user named editor can be displayed programmatically with the built in procedure SHOWEDITOR, EDIT_TETITEM independent of any particular text item. Question 445. What Is A Trace File And How Is It Created ? Answer : Each server and background process can write an associated trace file. When an internal error is detected by a process or user process, it dumps information about the error to its trace. This can be used for tuning the database. Question 446. What Is Rule-based Approach To Optimization ? Answer : Choosing an executing planbased on the access paths available and the ranks of these access paths. Question 447. What Is The Function Of Optimizer ? Answer : The goal of the optimizer is to choose the most efficient way to execute a SQL statement. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 53


Training Devision of 10daneces Question 448. What Is Execution Plan ? Answer : The combinations of the steps the optimizer chooses to execute a statement is called an execution plan. Question 449. What Are The Values That Can Be Specified For Optimizer Mode Parameter ? Answer : COST and RULE. Question 450. What Are The Responsibilities Of A Database Administrator ? Answer : Installing and upgrading the Oracle Server and application tools. Allocating system storage and planning future storage requirements for the database system. Managing primary database structures (tablespaces) Managing primary objects (table,views, indexes) Enrolling users and maintaining system security. Ensuring compliance with Oralce license agreement Controlling and monitoring user access to the database. Monitoring and optimizing the performance of the database. Planning for backup and recovery of database information. Maintain archived data on tape Backing up and restoring the database. Contacting Oracle Corporation for technical support. Question 451. Difference Between Procedure And Function.? Answer : Functions are named PL/SQL blocks that return a value and can be called with arguments procedure a named block that can be called with parameter. A procedure all is a PL/SQL statement by itself, while a Function call is called as part of an expression. Question 452. What Is Syntax For Dropping A Procedure And A Function Are These Operations Possible? Answer : Drop Procedure procedure_name. Drop Function function_name. Question 453. Difference Between Database Triggers And Form Triggers? Answer : -Data base trigger(DBT) fires when a DML operation is performed on a data base table. Form trigger(FT) Fires when user presses a key or navigates between fields on the screen -Can be row level or statement level No distinction between row level and statement level. -Can manipulate data stored in Oracle tables via SQL Can manipulate data in Oracle tables as well as variables in forms. -Can be fired from any session executing the triggering DML statements. Can be fired only from the form that define the trigger. -Can cause other database triggers to fire.Can cause other database triggers to fire, but not other form triggers. Question 454. What Is A Cursor For Loop? Answer : Cursor For Loop is a loop where oracle implicitly declares a loop variable, the loop index that of the same record type as the cursor's record. Question 455. How You Will Avoid Duplicating Records In A Query? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 54


Training Devision of 10daneces Answer : By using DISTINCT. Question 456. Explain The Difference Between A Hot Backup And A Cold Backup And The Benefits Associated With Each. Answer : A hot backup is basically taking a backup of the database while it is still up and running and it must be in archive log mode. A cold backup is taking a backup of the database while it is shut down and does not require being in archive log mode. The benefit of taking a hot backup is that the database is still available for use while the backup is occurring and you can recover the database to any point in time. The benefit of taking a cold backup is that it is typically easier to administer the backup and recovery process. In addition, since you are taking cold backups the database does not require being in archive log mode and thus there will be a slight performance gain as the database is not cutting archive logs to disk. Question 457. You Have Just Had To Restore From Backup And Do Not Have Any Control Files. How Would You Go About Bringing Up This Database? Answer : I would create a text based backup control file, stipulating where on disk all the data files where and then issue the recover command with the using backup control file clause. Question 458. How Do You Switch From An Init.ora File To A Spfile? Answer : Issue the create spfile from pfile command. Question 459. Explain The Difference Between A Data Block, An Extent And A Segment. Answer : A data block is the smallest unit of logical storage for a database object. As objects grow they take chunks of additional storage that are composed of contiguous data blocks. These groupings of contiguous data blocks are called extents. All the extents that an object takes when grouped together are considered the segment of the database object. Question 460. Give Two Examples Of How You Might Determine The Structure Of The Table Dept. Answer : Use the describe command or use the dbms_metadata.get_ddl package. Question 461. Where Would You Look For Errors From The Database Engine? Answer : In the alert log. Question 462. Compare And Contrast Truncate And Delete For A Table. Answer : Both the truncate and delete command have the desired outcome of getting rid of all the rows in a table. The difference between the two is that the truncate command is a DDL operation and just moves the high water mark and produces a now rollback. The delete

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 55


Training Devision of 10daneces command, on the other hand, is a DML operation, which will produce a rollback and thus take longer to complete. Question 463. Give The Reasoning Behind Using An Index. Answer : Faster access to data blocks in a table. Question 464. Give The Two Types Of Tables Involved In Producing A Star Schema And The Type Of Data They Hold. Answer : Fact tables and dimension tables. A fact table contains measurements while dimension tables will contain data that will help describe the fact tables. Question 465. What Type Of Index Should You Use On A Fact Table? Answer : A Bitmap index. Question 466. Give Two Examples Of Referential Integrity Constraints. Answer : A primary key and a foreign key. Question 467. A Table Is Classified As A Parent Table And You Want To Drop And Re-create It. How Would You Do This Without Affecting The Children Tables? Answer : Disable the foreign key constraint to the parent, drop the table, re-create the table, enable the foreign key constraint. Question 468. Explain The Difference Between Archivelog Mode And Noarchivelog Mode And The Benefits And Disadvantages To Each. Answer : ARCHIVELOG mode is a mode that you can put the database in for creating a backup of all transactions that have occurred in the database so that you can recover to any point in time. NOARCHIVELOG mode is basically the absence of ARCHIVELOG mode and has the disadvantage of not being able to recover to any point in time. NOARCHIVELOG mode does have the advantage of not having to write transactions to an archive log and thus increases the performance of the database slightly. Question 469. What Command Would You Use To Create A Backup Control File? Answer : Alter database backup control file to trace. Question 470. Give The Stages Of Instance Startup To A Usable State Where Normal Users May Access It. Answer : STARTUP NOMOUNT - Instance startup. STARTUP MOUNT - The database is mounted. STARTUP OPEN - The database is opened. Question 471. What Column Differentiates The V$ Views To The Gv$ Views And How? Answer : The INST_ID column which indicates the instance in a RAC environment the information came from. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 56


Training Devision of 10daneces Question 472. How Would You Go About Generating An Explain Plan? Answer : Create a plan table with utlxplan.sql. Use the explain plan set statement_id = ‘tst1′ into plan_table for a SQL statement. Look at the explain plan with utlxplp.sql or utlxpls.sql. Question 473. How Would You Go About Increasing The Buffer Cache Hit Ratio? Answer : Use the buffer cache advisory over a given workload and then query the v$db_cache_advice table. If a change was necessary then I would use the alter system set db_cache_size command. Question 474. Explain An Ora-01555 Answer : You get this error when you get a snapshot too old within rollback. It can usually be solved by increasing the undo retention or increasing the size of rollbacks. You should also look at the logic involved in the application getting the error message. Question 475. Describe The Difference Between A Procedure, Function And Anonymous Pl/sql Block. Answer : Candidate should mention use of DECLARE statement, a function must return a value while a procedure doesn't have to. Also one can use function in Select Sql statement but not procedure. Question 476. Describe The Use Of %rowtype And %type In Pl/sql Answer : %ROWTYPE allows you to associate a variable with an entire table row. The %TYPE associates a variable with a single column type. Question 477. Describe The Use Of Pl/sql Tables Answer : PL/SQL tables are scalar arrays that can be referenced by a binary integer. They can be used to hold values for use in later queries or calculations. In Oracle they will be able to be of the %ROWTYPE designation, or RECORD. Question 478. In What Order Should A Open/fetch/loop Set Of Commands In A Pl/sql Block Be Implemented If You Use The %notfound Cursor Variable In The Exit When Statement? Why? Answer : OPEN then FETCH then LOOP followed by the exit when. If not specified in this order will result in the final return being done twice because of the way the %NOTFOUND is handled by PL/SQL. Question 479. Give One Method For Transferring A Table From One Schema To Another: Answer : There are several possible methods, export-import, CREATE TABLE... AS SELECT, or COPY. Question 480. What Is The Purpose Of The Import Option Ignore? What Is It's Default Setting? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 57


Training Devision of 10daneces The IMPORT IGNORE option tells import to ignore "already exists" errors. If it is not specified the tables that already exist will be skipped. If it is specified, the error is ignored and the tables data will be inserted. The default value is N. Question 481. You Have A Rollback Segment In A Version 7.2 Database That Has Expanded Beyond Optimal, How Can It Be Restored To Optimal? Answer : Use the ALTER TABLESPACE ..... SHRINK command. Question 482. What Are Some Of The Oracle Provided Packages That Dbas Should Be Aware Of? Answer : Oracle provides a number of packages in the form of the DBMS_ packages owned by the SYS user. The packages used by DBAs may include: DBMS_SHARED_POOL, DBMS_UTILITY, DBMS_SQL, DBMS_DDL, DBMS_SESSION, DBMS_OUTPUT and DBMS_SNAPSHOT. Question 483. What Happens If The Constraint Name Is Left Out Of A Constraint Clause? Answer : The Oracle system will use the default name of SYS_Cxxxx where xxxx is a system generated number. This is bad since it makes tracking which table the constraint belongs to or what the constraint does harder. Question 484. What Happens If A Tablespace Clause Is Left Off Of A Primary Key Constraint Clause? Answer : This results in the index that is automatically generated being placed in then users default tablespace. Since this will usually be the same tablespace as the table is being created in, this can cause serious performance problems. Question 485. What Is The Proper Method For Disabling And Re-enabling A Primary Key Constraint? Answer : You use the ALTER TABLE command for both. However, for the enable clause you must specify the USING INDEX and TABLESPACE clause for primary keys. Question 486. What Happens If A Primary Key Constraint Is Disabled And Then Enabled Without Fully Specifying The Index Clause? Answer : The index is created in the users default tablespace and all sizing information is lost. Oracle doesn't store this information as a part of the constraint definition, but only as part of the index definition, when the constraint was disabled the index was dropped and the information is gone. Question 487. You Are Using Hot Backup Without Being In Archivelog Mode, Can You Recover In The Event Of A Failure? Why Or Why Not? Answer : You can't use hot backup without being in archivelog mode. So no, you couldn't recover. Question 488. What Causes The "snapshot Too Old" Error? How Can This Be Prevented Or Mitigated? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 58


Training Devision of 10daneces Answer : This is caused by large or long running transactions that have either wrapped onto their own rollback space or have had another transaction write on part of their rollback space. This can be prevented or mitigated by breaking the transaction into a set of smaller transactions or increasing the size of the rollback segments and their extents. Question 489. A User Is Getting An Ora-00942 Error Yet You Know You Have Granted Them Permission On The Table, What Else Should You Check? Answer : You need to check that the user has specified the full name of the object (SELECT empid FROM scott.emp; instead of SELECT empid FROM emp;) or has a synonym that points to the object (CREATE SYNONYM emp FOR scott.emp;). Question 490. If You Have An Example Table, What Is The Best Way To Get Sizing Data For The Production Table Implementation? Answer : The best way is to analyze the table and then use the data provided in the DBA_TABLES view to get the average row length and other pertinent data for the calculation. The quick and dirty way is to look at the number of blocks the table is actually using and ratio the number of rows in the table to its number of blocks against the number of expected rows. Question 491. How Can You Find Out How Many Users Are Currently Logged Into The Database? How Can You Find Their Operating System Id? Answer : There are several ways. One is to look at the v$session or v$process views. Another way is to check the current_logins parameter in the v$sysstat view. Another if you are on UNIX is to do a "ps -ef|grep oracle|wc -l? command, but this only works against a single instance installation. Question 492. You Want To Include A Carriage Return/linefeed In Your Output From A Sql Script, How Can You Do This? Answer : The best method is to use the CHR() function (CHR(10) is a return/linefeed) and the concatenation function "||". Another method, although it is hard to document and isn?t always portable is to use the return/linefeed as a part of a quoted string. Question 493. Which Is More Faster - In Or Exists? Answer : EXISTS is more faster than IN because EXISTS returns a Boolean value whereas IN returns a value. Question 494. How Will You Delete Duplicating Rows From A Base Table? Answer : delete from table_name where rowid not in (select max(rowid) from table group by duplicate_values_field_name); or delete duplicate_values_field_name dv from table_name. where rowid <(select min(rowid) from table_name tb where ta.dv=tb.dv); Question 495. How You Open And Close A Cursor Variable.why It Is Required? Answer : OPEN cursor variable FOR SELECT...Statement. CLOSE cursor variable In order to associate a cursor variable with a particular SELECT Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 59


Training Devision of 10daneces statement. OPEN syntax is used. In order to free the resources used for the query CLOSE statement is used. Question 496. What Is Oci. What Are Its Uses? Answer : Oracle Call Interface is a method of accesing database from a 3GL program. Uses--No precompiler is required,PL/SQL blocks are executed like other DML statements. The OCI library provides --functions to parse SQL statemets --bind input variables --bind output variables --execute statements --fetch the results Question 497. What Is A Outer Join? Answer : Outer Join--Its a join condition used where you can query all the rows of one of the tables in the join condition even though they don?t satisfy the join condition. Question 498. What Is Difference Between Rename And Alias? Answer : Rename is a permanent name given to a table or column whereas Alias is a temporary name given to a table or column which do not exist once the SQL statement is executed. Question 499. What Are Various Privileges That A User Can Grant To Another User? Answer : -SELECT. -CONNECT. -RESOURCES. Question 500. What Are Different Oracle Database Objects? Answer : -TABLES -VIEWS -INDEXES -SYNONYMS -SEQUENCES -TABLESPACES etc. Question 501. What Are The Pros And Cons Of Using Triggers? Answer : A trigger is one or more statements of SQL that are being executed in event of data modification in a table to which the trigger belongs. Triggers enhance the security, efficiency, and standardization of databases. Triggers can be beneficial when used: – to check or modify values before they are actually updated or inserted in the database. This is useful if you need to transform data from the way the user sees it to some internal database format. – to run other non-database operations coded in user-defined functions – to update data in other tables. This is useful for maintaining relationships between data or in keeping audit trail information. – To check against other data in the table or in other tables. This is useful to ensure data Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 60


Training Devision of 10daneces integrity when referential integrity constraints aren’t appropriate, or when table check constraints limit checking to the current table only. Question 502. When A Query Is Sent To The Database And An Index Is Not Being Used, What Type Of Execution Is Taking Place? Answer : A table scans. Question 503. What Is The Difference Of A Left Join And An Inner Join Statement? Answer : A LEFT JOIN will take ALL values from the first declared table and matching values from the second declared table based on the column the join has been declared on. An INNER JOIN will take only matching values from both tables. Question 504. What Is An Advantage To Using A Stored Procedure As Opposed To Passing An Sql Query From An Application? Answer : A stored procedure is pre-loaded in memory for faster execution. It allows the DBMS control of permissions for security purposes. It also eliminates the need to recompile components when minor changes occur to the database. Question 505. What Is A Cartesian Product? What Causes It? Answer : A Cartesian product is the result of an unrestricted join of two or more tables. The result set of a three table Cartesian product will have x * y * z number of rows where x, y, z correspond to the number of rows in each table involved in the join. It is causes by specifying a table in the FROM clause without joining it to another table. Question 506. What Is The Maximum Number Of Triggers, Can Apply To A Single Table? Answer : 12 triggers. Question 507. What Is The Output Of Sign Function? Answer : 1 for positive value, 0 for Zero, -1 for Negative value. Question 508. What Are The More Common Pseudo-columns? Answer : SYSDATE, USER , UID, CURVAL, NEXTVAL, ROWID, ROWNUM. Question 509. Other Way To Replace Query Result Null Value With A Text? Answer : SQL> Set NULL ‘N/A’ to reset SQL> Set NULL. Question 510. What Are Pl/sql Cursor Exceptions? Answer : Cursor_Already_Open, Invalid_Cursor. Question 511. Any Three Pl/sql Exceptions? Answer : Too_many_rows, No_Data_Found, Value_Error, Zero_Error, Others. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 61


Training Devision of 10daneces Question 512. Which Date Function Returns Number Value? Answer : months_between. Question 513. Display Odd/ Even Number Of Records? Answer : Odd number of records: select * from emp where (rowid,1) in (select rowid, mod(rownum,2) from emp); 1 3 5.

Even number of records: select * from emp where (rowid,0) in (select rowid, mod(rownum,2) from emp) 2 4 6.

Question 514. If A View On A Single Base Table Is Manipulated Will The Changes Be Reflected On The Base Table? Answer : If changes are made to the tables and these tables are the base tables of a view, then the changes will be reference on the view. Question 515. Can A View Be Updated/inserted/deleted? If Yes - Under What Conditions? Answer : A View can be updated/deleted/inserted if it has only one base table if the view is based on columns from one or more tables then insert, update and delete is not possible. Question 516. How To Access The Current Value And Next Value From A Sequence? Is It Possible To Access The Current Value In A Session Before Accessing Next Value? Answer : Sequence name CURRVAL, sequence name NEXTVAL. It is not possible. Only if you access next value in the session, current value can be accessed. Question 517. If Unique Key Constraint On Date Column Is Created, Will It Validate The Rows That Are Inserted With Sysdate? Answer : It won't, Because SYSDATE format contains time attached with it. Question 518. What Are The Pre-requisites To Modify Datatype Of A Column And To Add A Column With Not Null Constraint? Answer : To modify the datatype of a column the column must be empty. - To add a column with NOT NULL constrain, the table must be empty.

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 62


Training Devision of 10daneces Question 519. How Many Long Columns Are Allowed In A Table? Is It Possible To Use Long Columns In Where Clause Or Order By? Answer : Only one LONG column is allowed. It is not possible to use LONG column in WHERE or ORDER BY clause. Question 520. What Is Difference Between Char And Varchar2? What Is The Maximum Size Allowed For Each Type? Answer : CHAR pads blank spaces to the maximum length. VARCHAR2 does not pad blank spaces. For CHAR the maximum length is 255 and 2000 for VARCHAR2. Question 521. What Is A Database Resource Manager? Answer : Database resource manager allows us to create resource plans, which specify how much of our resources should go to various consumer groups.We can group users based on their resource requirement and we can have the database resource manager allocate a preset amount of resources to these groups.We can easily prioritize our users and jobs. Question 522. What Are The Uses Of A Database Resource Manager? Answer : The database resource manager enables us to limit the length of time a user session can stay idle and to automatically terminate long-running SQL statements and user sessions. 2) Using the database resource manager we can set initial login priorities for various consumer groups. 3) By using the concept of active session pool,we can specify the maximum number of concurrent active sessions for a consumer group-the Database resource manager will automatically queue all the subsequent requests until the currently running sessions complete. Question 523. Can We Switch Users Between Resource Consumer Groups/consumer Groups? Answer : DBA's can automatically switch users from one resource group to another ,based on preset resource usage criteria,and can limit the amount of undo space a resource group can use. Question 524. What Are The Four Elements Of A Database Resource Manager? Answer : Database resource manager is composed of the following four elements : Resource consumer group, resource plan,resource allocation method,resource plan directive. Question 525. What Is A Resource Consumer Group? Answer : A resource consumer group is used to group together similar users based on their resource needs. Question 526. What Is A Resource Plan? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 63


Training Devision of 10daneces The resource plan lays how resource consumer groups are allocated resources. Each resource plan contains a set of resource consumer groups that belong to this plan, together with instructions as to how resources are to be allocated among these groups. For instance,a resource plan may dictate CPU resources be allocated among three resource consumer groups so that the first group gets 60 percent and the remaining two groups get 20 percent each of the total CPU time. Question 527. What Is A Subplan? Answer : A subplan is a part of the resource plan that enables the allocation of resources in greater detailamong the resource consumer groups. Question 528. What Is A Resource Allocation Method? Answer : The resource allocation method indictates the specific method we choose to use to allocate resources like the CPU.The available methods of allocating the database resources are CPU method, Idle time, Execution time limit, Undo pool, Active session pool, automatic consumer group switching, canelling SQL and terminating sessions, parallel degree limit. Question 529. What Is A Cpu Method? Answer : Oracle uses multiple levels of CPU allocation to prioritize and allocate CPU usage among the competing user sessions.It is a type of resource allocation method. Question 530. What Is An Idle Time? Answer : It is a type of resource allocation method.We can direct that a user's session be terminated after it has been idle for a specified period of time.We can also specify that only idle sessions blocking other sessions be terminated. Question 531. What Is An Execution Time Limit? Answer : It is a type of resource allocation method.We can control resource usageby setting a limit on the maximum execution time of an opration. Question 532. What Is An Undo Pool? Answer : It is a type of resource allocation method. By setting an undo pool directive, we can limit the total amount of undos that can be generated by a consumer resource group. Question 533. What Is An Active Session Pool? Answer : It is a type of resource allocation method. We can set a maximum allowable number of concurrent sessions with in any consumer resource group.All sessions that are beyond the maximum limit are queued for execution after the freeing up of current active sessions. Question 534. What Is An Automatic Consumer Group Switching? Answer : It is a type of resource allocation method. Using this method, we can specify that a user session be automatically switched to a different group after it runs more than a specified number of seconds. The group that the session should switch to is called as switch Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 64


Training Devision of 10daneces group,and the time limit is the switch time. The session can revert to its original consumer group after e end of the top call, whih is defined as an entire PL/SQL block or a seperate SQL statement. Question 535. What Is Cancelling Sql And Terminating Sessions? Answer : It is a type of resource allocation method. By using CANCEL_SQL or KILL_SESSION as the switch group, we can direct a long-running SQL sement or even an entire session to be cancelled or terminated. Question 536. What Is A Parallel Degree Limit? Answer : It is a type of resource allocation method.We can use this method to specify the limit of the degree of parallelism for an operation. Question 537. What Is A Resource Plan Directive? Answer : It is an element of database resource manager. It links a resource plan to a specific resource consumer group. Question 538. What Is Oracle Database Vault? Answer : Oracle Database Vault is a security solution from oracle corporation. It restricts access to certain areas of the database.Even users with administrative privileges have restricted access. This fine-grained access control protects the database from super-privileged users. Question 539. Where Can We Use Oracle Database Vault? Answer : Oracle Database Vault can be used to protect standalone database instance, Oracle Real Application Cluster(RAC). Question 540. What Are The Components Of Oracle Database Vault? Answer : Oracle Database Vault has the following components: 1) Oracle Database Vault Access Control Components 2) Oracle Database Vault Administrator (DVA) 3) Oracle Database Vault Configuration Assistant (DVCA) 4) Oracle Database Vault DVSYS and DVF Schemas 5) Oracle Database Vault PL/SQL Interfaces and Packages 6) Oracle Database Vault and Oracle Label Security PL/SQL APIs 7) Oracle Database Vault Reporting and Monitoring Tools. Question 541. What Is Oracle Database Vault Access Control Components Made Of ? Answer : It is formed of the following components that helps us manage security for the database instance. They are: 1)Realms 2)Command Rules 3) Factors 4) Rule sets 5) Security Application roles. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 65


Training Devision of 10daneces Question 542. What Is A Realm? Answer : A realm is a functional grouping of database schemas,objects and roles that must be secured.After grouping we can use realms to control the use of system privileges to specific accounts or roles. This provides fine-grained access control. Question 543. What Is A Command Rule? Answer : A command rule is a special rule created to control how users can execute almost any SQL statement. This includes SELECT, ALTER SYSTEM, DDL and DML statements. Question 544. Do Command Rules Work Alone? Answer : No. They work with rule sets to determine whether or not a statement is allowed. Question 545. What Is A Factor? Answer : A factor is a named variable or a attribute such as user location, database IP address, or session user, which oracle database vault can recognize and secure. Question 546. What Is The Use Of A Factor? Answer : We can use factors for activities such as authorizing database accounts to connect to the database or creating filter logic to restrict the visibility and manageability of data. Question 547. What Is An Identity? Answer : Each factor can have one or more identities. An identitiy is the actual value of a factor. A factor can have several identities depending on the factor retrieval method or its identity mapping logic. Question 548. What Is A Rule Set? Answer : A rule set is a collection of one or more rules that we can associate with a realm authorization, command rule, factor assignment, or secure application role. Question 549. What Are The Possible Evaluations Of A Rule Set? Answer : The rule set evaluates to true or false based on the evaluation of each rule it contains and the evaluation type (All True or Any True). Question 550. What Is A Rule With In A Rule Set? Answer : The rule within a rule set is a PL/SQL expression that evaluates to true or false. Question 551. Can Rules Be Reused? Answer : We can have the same rule in multiple rule sets. Question 552. What Are Secure Application Roles? Answer : A secure application role is a special Oracle Database role that can be enabled based on the evaluation of an Oracle Database Vault rule set.

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 66


Training Devision of 10daneces Question 553. What Are The Steps Taken To Secure Database Using Oracle Database Avult Access Control Component? Answer : Create a realm composed of the database schemas or database objects that we want to secure. 2) We can further secure the realm by creating rules, command rules, factors, identities, rule sets, and secure application roles. 3) We can run reports on the activities these components monitor and protect. Question 554. What Is A Oracle Database Vault Administrator(dva)? Answer : Oracle Database Vault Administrator(DVA) is a Java application that is built on top of the Oracle Database Vault PL/SQL application programming interfaces (API). Question 555. What Is The Use Of Dva? Answer : DVA allows security managers who may not be proficient in PL/SQL to configure the access control policy through a user-friendly interface. 2) Oracle Database Vault Administrator provides an extensive collection of securityrelated reports that assist in understanding the baseline security configuration. 3) These reports help to point out deviations from this baseline. Question 556. What Is Oracle Database Vault Configuration Assistant (dvca)? Answer : It is a command-line utility that is used to perform maintenance tasks on Oracle Database Vault Installation. Question 557. What Are The Oracle Database Vault Schemas? Answer : Two major schemas of oracle database vault are DVSYS and DVF. Question 558. Give Details On Dvsys Schema? Answer : DVSYS schema stores objects needed to process Oracle data for Oracle database vault. This schema contains the roles, views, accounts, functions, and other database objects that the Oracle Database Vault uses. Question 559. Give Details On Dvf Schema? Answer : The DVF schema contains public functions to retrieve (at run time) the factor values set in the Oracle Database Vault access control configuration. Question 560. Give Details On Oracle Database Vault Pl/sql Interfaces And Packages? Answer : Oracle Database Vault PL/SQL Interfaces and Packages are collections that allow security managers, application developers to configure security policy. The PL/SQL procedures and functions allow general database accounts to operate within the boundaries of the access control policy in the context of a given database session. Question 561. What Is An Oracle Ultra Search? Answer : Oracle Ultra Search is built on the Oracle Database and Oracle Text technology that provides uniform search-and-location capabilities over multiple repositories such as, Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 67


Training Devision of 10daneces Oracle databases, other ODBC compliant databases, IMAP mail servers, HTML documents served up by a Web server, files on disk, and more. Question 562. What Components Constitute Oracle Ultra Search? Answer : Oracle ultra search is made of the following components: 1) Oracle Ultra search crawler 2) Oracle Ultrasearch backend 3) Oracle Ultra search middle tier. Question 563. What Is An Oracle Ultrasearch Crawler/give Details On Oracle Ultra Search Crawler? Answer : The Oracle Ultra Search crawler is a Java process activated by the Oracle server based on a a set schedule. When activated, the crawler spawns a configurable number of processor threads that fetch documents from various data sources and index them using Oracle Text. This index is used for querying. Data sources can be Web sites,database tables, files, mailing lists, Oracle Application Server Portal page groups, or user-defined data sources. Question 564. What Is Oracle Ultra Search Backend? Answer : The Oracle Ultra Search back end consists of an Oracle Ultra Search repository and Oracle Text. Oracle Text provides text indexing and search capabilities required to index and query data retrieved from the data sources. The back end indexes information from the crawler and serves up the query results. Question 565. What Is Oracle Ultra Search Middle Tier? Answer : The Oracle Ultra Search middle tier components are Web applications. The middle tier includes the Oracle Ultra Search administration tool, the APIs and the query applications. Question 566. How Is Middle Tier Deployed In Various Oracle Products? Answer : In the Oracle Database release, the Oracle Ultra Search middle tier and back end can reside in the same Oracle Home. However, in the OracleAS and Oracle Collaboration Suite releases, the middle tier is located in a different Oracle Home. Question 567. What Is Oracle Ultrasearch Administration Tool? Answer : The administration tool is a J2EE-compliant Web application. We can use it to manage Oracle Ultra Search instances and access it from the intranet. Question 568. What Is A Query Reporting Tool? Answer : Oracle Ultra Search includes highly functional query applications to query and display search results. The query applications are based on JSP and work with any JSP1.1 compliant engine. Question 569. Is Query Application Same As Oracle Administration Tool? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 68


Training Devision of 10daneces The administration tool is independent from the Oracle Ultra Search query application. Therefore, the administration tool and query application can be hosted on different computers to enhance security and scalability. Question 570. What Is An Oracle Ultra Search Apis? Answer : Oracle Ultra Search provides the following APIs: 1) The query API works with indexed data. The Java API does not impose any HTML rendering elements. The application can completely customize the HTML interface. 2) The crawler agent API crawls and indexes proprietary document repositories. The email Java API accesses archived e-mails and is used by the query application to display e-mails. It can also be used to build our own custom query application. 3) The URL rewriter API is used by the crawler to filter and rewrite extracted URL links before they are inserted into the URL queue. 4) The Document Service crawler agent API enables generation of attribute data based on the document contents. It accepts robot metatag instructions from the agent for the target document, and it transforms the original document contents for indexing control. Question 571. What Is An Oracle Ultrasearch Instance? Answer : An Ultra Search instance can be created to provide isolation for the data collections that have been crawled.We can create a read-only snapshot of a master Oracle Ultra Search instance. This is useful for query processing or for backup.We can also make a snapshot instance updatable. This is useful when the master instance is corrupted and we want to use a snapshot as a new master instance. Question 572. What Is Owb? Answer : Oracle Warehouse Builder (OWB) is an information integration tool that leverages the Oracle Database to transform data into high-quality information. The Oracle Database is a central component in the Warehouse Builder architecture because the Database hosts the Warehouse Builder repository and the code generated by Warehouse Builder. Question 573. What Are The Major Components Of Warehouse Builder? Answer : Oracle Warehouse Builder(OWB) is composed of Design centre, Control center manager, target schema, Warehouse builder repository, Repository browser, control center service. Question 574. What Is Omb Plus? Answer : OMB plus is a flexible, high-level command line metadata access tool for Oracle Warehouse Builder. We use OMB Plus to create, modify, delete, and retrieve object metadata in Warehouse Builder design and runtime repositories. Question 575. What Is The Scriping Language Used To Manipulate Owb? Answer : OMB Plus is a scripting language used to manipulate object and runtime repositories of OWB. OMB Plus is an extension TCL Programming language and hence has variable constructs, looping and control structures. Question 576. Where Are The Sql Scripts Located In Owb? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 69


Training Devision of 10daneces OWB scripts are installed at \ owb \rtp \sql and are used for managing deployment jobs,execution jobs,control centers from SQL*PLUS. Question 577. How Do You Launch Ombplus At Unix Prompt? Answer : We can launch OMB plus at the unix prompt using OWB_HOME/owb/bin/unix/OMBPlus.sh. Question 578. How Do You Connect To A Owb Repository From Omb Plus? Answer : From OMB Plus console enter the following : OMBCONNECT. repos/password@host:port:service_name USE WORKSPACE wokspace_name. Question 579. What Is Oracle Vm? Answer : Oracle VM is the latest virtualization technology from oracle. It is built upon the open source project Xen. Question 580. What Are The Components That Constitute Oracle Vm? Answer : Oracle VM is composed of Oracle VM Server ,the software component that is used for virtualization provisioning and Oracle VM Manager a GUI tool used to control VM Server. Question 581. What Is An Oracle Vm Agent? Answer : VM agent is a component of Oracle VM Server.It is the communication medium between the Oracle VM manager and the Oracle VM Server. Question 582. What Is Dom0? Answer : Dom0 refers to the Domain0 which is the refernce given to Oracle VM Server. Question 583. What Is Domu? Answer : Domu refers to unprivileged domains. Question 584. What Are The Types Of Server Pools? Answer : There are three major types of server pools namely Master Server, Utility Server, Virtual Servers. Question 585. What Is Asm? Answer : ASM is a Volume Manager and a file system for Oracle Database Files that supports single instance Oracle Database and Oracle Real Application cluster (RAC) configuration. Question 586. What Is The Recommended Storage Management Solution From Oracle?why? Answer : ASM is the recommended storage management solution from oracle as it provides an alternative to conventional volume managers,file systems and raw devices. Question 587. How Is Data File Stored In Asm? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 70


Training Devision of 10daneces Answer : ASM uses disk groups to store data files. Question 588. What Is An Asm Disk Group? Answer : An ASM disk group is a group of disks that ASM manages as an unit.Within the diskgroups an file system interface maintains the Oracle database files. ASM simplifies database storage by consolidating disks into disk groups.This reduces I/O overhead. Question 589. How Is The Performance Of Disk Group Comparable To Raw Disks?are Disk Groups A Good Alternative To Raw Disks? Answer : The files distributed across the set of disks in a disk group are striped or distributed across the disks to eliminate hot spots and improve performance.Thus they perform equally well as raw disks. Question 590. How Does Asm Eliminate Down Time? Answer : Disks can be added and removed from the disk groups online(i.e)during the operation of the database without any downtime. When disks are added or removed ASM automatically redistributes the contents with out any downtime.Thus ASM eliminates down time. Question 591. Give Details On Server-based Mirroring? Answer : This is a flexible option provided by ASM. The normal and redundant options of ASM provides two and three way mirroring. We can use external option to enable RAID(Redundant Array Of Independent Disks). Question 592. How Does An Asm Manage Files?how Is The File Management Simplified Using Asm? Answer : ASM uses the Oracle Managed Files(OMF) feature which simplifies file management. Files are created at specified location, renames files, deletes files when operations at tablespace level happens(say tablespace deletion). Question 593. Give Some Interfaces Used To Manage Asm:Answer : Oracle Enterprise Manager(OEM), SQL*PLUS, ASMCMD command-line interface are some interfaces that can be used with ASM. Question 594. Can Asm Co-exist With Non-asm System? Answer : Yes, ASM can co-exist with non-ASM third-party file systems and thus can be integrated into pre-existing environments. OEM has an interface for migrating nonASM files to ASM. Question 595. What Is An Asm Instance? Answer : An ASM instance is the instance that manages ASM disk groups. It composes of System Global Area(SGA) and background processes. ASM instance mounts a disk group that is made available to the database instance. An ASM instance manages the metadata of a disk group and provides file layout information to the database instances. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 71


Training Devision of 10daneces Question 596. Will The Sga(system Global Area) Of Asm Is Comparable In Size To An Oracle Database Instance? Answer : No. The SGA size of an ASM is smaller than that of an Oracle database instance, as an ASM performs fewer tasks than a database. Question 597. Can Asm Instance Mount A Database? Answer : No. An ASM instance can mount a disk group that can be used by a database instance. Question 598. What Is Asm Metadata And Where Is It Present? Answer : ASM metadata is the information that ASM uses to control the disk group. It is present within a disk group. Question 599. What Is An Asm Metadata Composed Of? Answer : An ASM metadata includes the following: 1) The disks that belong to a disk group 2) Amount of space available within a disk group 3) The filenames of the files within a disk group 4) The location of disk group datafile data extents 5) A redo log that records information about automatically changing data blocks Question 600. What Are The Possible Asm Configurations? Answer : ASM and database instances share access to disks in a disk group. There can be one ASM instance and one database instance serving single database in a node. There can be one ASM instance,multiple database instances serving many database in a node. If the ASM instance fails,all the databases fails.The advantage is that this doesn't demand a Server reboot(Operating system restart). There can be clustered ASM instances that are clustered using Oracle Clusterware.(i.e)One ASM instance on each node that are integrated using Oracle clusterware. Question 601. What Is Database Security? Answer : The goal of database security is to prevent unauthorized use of database or its components.Database security depends on system and network security. Question 602. What Are The Main Aspects Of Oracle Database Security Management? Answer : Controlling access to data(authorization. Restricting access to legitimate users (authentication). Ensuring accountability on part of the users(auditing). Safeguarding key data in the database(encryption). Managing the security of the entire organizational information structure (enterprise security). Question 603. What Is A Temporary Tablespace? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 72


Training Devision of 10daneces All users need a temporary tablespace where they can perform operations such as sorting data during SQL execution. Question 604. What Is A Default Tablspace? Answer : Users need to have a default tablespace, where their objects will be created if they don't explicitly assign a different tablespace during object creation. Question 605. What Are The Two Tablespaces Created At Database Creation Time In Oracle 10g Database? Answer : In Oracle database 10g at the time of database creation default temporary tablespace and default permanent tablespace for all users will be created during database-creation process. Once these two tablespaces are created, we don't have to specify them again during the database creation process. Question 606. What If We Dont Assign A Specific Tablespace As A Default Tablespace? Answer : If we don't assign a default table space, the System tablespace becomes the default tablespace. Question 607. Why Is It Needed To Create A Default Tablespace For Every User? Answer : If we dont assign a default tablespace System tablespace becomes the default tablespace. If a user creates a very large object in the System table space, they might take up all the space in it and make it impossible for the SYS superuser to create any new objects in it, causing the database to come to a grinding halt. This is the main reason why we should always create a default tablespace for every user. Question 608. Give The Statement To Create A User? Answer : SQL>CREATE USER (username) IDENTIFIED BY (password); In case of Oracle database 11g use the following statement: SQL>CREATE USER (username) identified by "(password)"; The above query creates a user and password for the user. It is good practice to assign default temporary and permanent tablespace to the users. It is a good practice to ass them at the time of database creation. Question 609. How Do We Get The Default Tablespaces Of A User? Answer : The following query gives the default temporary and permanent tablespace for a user: SQL>SELECT default_tablespace,temporary_tablespace from dba_users where username='(username)'; Question 610. Can A User Created New Connect To The Database? Answer : A new user can't connect directly to database, because the user doesn't have any privileges to do so. When a user tries to connect he gets the following error at the SQL prompt: ERROR: Ora-01045: user lacks CREATE SESSION privilege; logon denied. Question 611. How Do We Rectify The Bove Error/ora:01045 Error? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 73


Training Devision of 10daneces Answer : In order for a user to connect and start communicating with the database ,he must be granted CREATE SESSION system privilege.The following statement is used: SQL>GRANT CREATE SESSION to (username); How to create a user with CONNECT system privilege? SQL>GRANT CONNECT to (username) identified by (password); Question 612. Can A Newly Created User Create Database Objects(tables, Indexes, Views, Synonyms, Sequences Etc) In A Database? Answer : No, a newly created user won't be able to create database objects directly. Even if the user is assigned default temporary and permanent tablespace at the creation time, it is mandatory to allocate quota on a tablespace to users. Question 613. How Do You Allocate Quota On A Tablespace To Users? Answer : The following command is used to allocate quota on a tablespace: SQL>ALTER USER (username) QUOTA ON (tablespacename); Question 614. What Is Fine-grained Access Control? Answer : It is a new security mechanism from Oracle that provides low-level data security Question 615. What Is The Advantage Of Fine-grained Access Control? Answer : Traditional access control techniques like granting roles, privileges, views are broadbased that resulted in unnecessarily restricting users. As a solution Oracle came up with fine-grained access control where control on data access is at low-level. Question 616. What Are The Mechanisms Used In Fine-grained Access Control? Answer : Oracle uses two related mechanisms to enforce fine-grained security within the database.They are: Application context. Fine-grained access control Policy. Question 617. What Is Virtual Private Database(vpd)? Answer : This term is used to refer to the implementation of fine-grained-access-control policies using application contexts. This offers security at row-level rather than table level. Each user of the application can be limited to seeing only a part of the table's data by using VPD concept. This row-level security is enforced by attaching a security policy directly to a database object such as, table, view or a synonym. It provides a much stronger security than application level security. No matter whatever tool is used(SQL*PLUS, adhoc query tool, report writer), the user can't elude this row-level security enforced by the database server. Question 618. What Are The Uses Of Fine-grained Access Control? Answer : We can use the fine-grained access control for the following purposes: Enforce row-level access control through SELECT, INSERT, UPDATE and DELETE statements. Create a security policy that controls access based on a certain value of a column. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 74


Training Devision of 10daneces Create Policies that are applied the same way always as well as policies that dynamically change during the execution of the query. Create sets of scurity policies,called policy groups. Question 619. How Does Vpd Enforce Security? Answer : VPD uses a type of query rewrite to restrict users to certain rows of tables and views. a security policy is attached to the table or tables to which we want to control access,and stored procedures are written to modify any relevant SQL statements made against the tables in the question. For example, when a user issues an UPDATE statement against the table with such a security policy, Oracle will dynamically append a predicate(a WHERE clause)to the user's statement to modify it and limit the user's access to that table. This will prevent users belonging to say SALES department from accessing and modifying FINANCE department records. UPDATE emp set salary=salary*10 will be modified as UPDATE emp set salary=salary*10 where dept='SALES';. Question 620. What Is Needed To Create A Vpd? Answer : To create a VPD, we have to create what is known as an application context and then implement fine grained access control to enforce the row-level security for database tables and views. The application context helps us create security policies that draw upon certain aspects of a user's session information. For example when an user logs into the database, the user ID identifies the user, and based on that piece of information, the application's security policy sets limits on what the user can do within the database. VPD is simple an implementation of the application context with fine-grained access control. Question 621. To What Statements Can We Apply Vpd Policy? Answer : VPD policy can be applied to SELECT, INSERT, UPDATE, INDEX and DELETE statements. Question 622. Give Details On Application Context ? Answer : An application context allows us to define a set of application attributes, usually a set of session environmental variables, that we can use to control an application's access to the database. Using application attributes we can supply relevant predicate values for finegrained access control policy. Question 623. What Are The Major Focuses Of Performance Tuning? Answer : Performance tuning focuses primarily on writing efficient SQL, allocating appropriate computing resources, and analyzing wait events and contention in a system. Question 624. How Does Oracle Aid Performance Tuning? Answer : Oracle provides several options to aid performance tuning, such as partitioning lair tables, using materialized views, storing plan outlines, using tools like Automatic Optimizer statistics collection feature, cages like DBMS_STATS, SQL Tuning Advisor to tune SQL statements,etc.

Question 625. Why Is Performance Tuning A Menancing Area For Dba's? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 75


Training Devision of 10daneces Answer : Like many other features of Oracle like exp/imp,backu recovery this field can't be automated. This is one area that requires a lot of detective work on the part of application programmers and DBA's to see w some process is running slower than expected, why can't we scale applications to a larger number of users without problems like performance degradation etc.This is a area where our technical knowledge must be used along with constant experimentation and observation. Question 626. What Are The Approaches Towards Performance Tuning? Answer : We can follow either a systematic approach or a reactive approach for performance tuning. Question 627. What Is A Systematic Approach To Performance Tuning? Answer : It is mandatory to design the database properly at initial stages to avoid potential problems. It is mandatory to know the nature of application that a database is going to support. With a clear idea on the application's nature database can be optimally created by allocating appropriate resources to avoid problems when the application is moved to production. Most production moves cause problem because of the scalability problems with the applications. So, oracle recommends to tune database at inception stage. this is systematic approach to performance tuning. Question 628. What Are The Oracle's Suggestions Towards Systematic Tuning? Answer : Oracle suggests a specific design approach with the following steps. This is a top down approach: Design the application correctly. Tune the application SQL code. Tune memory. Tune I/O. Tune contention and other issues. Question 629. What Are The Effects Of Poor Database Design? Answer : A poor database design results in poor application performance. We have to tune the application code and some database resources such as memory, CPU, I/O owing to performance degradation. Question 630. An Applications Performs Well In Development And Testing. Will There Be Any Performance Problem When It Is Moved To Production? Answer : Production moves may cause problems due to scalability. We can't simulate the original load in test and development. So problems may crop up at times as the application may be performing poor due to scalability problems. Question 631. What Is Reactive Performace Tuning? Answer : Performance tuning is an iterative process. We as a DBA may have to tune applications which is designed and implemented in production. The performance tuning at htis stage is referred to as reactive performance tuning. Question 632. Which Is Useful - Systematic Or Reactive Tuning? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 76


Training Devision of 10daneces Answer : The performance tuning steps to improve the performance of a database depends on the stage at which we get the input and on the nature of the application. DBA's can assist the developers to write optimal code that is scalable based on systematic approach. Mostly the real life problems that are encountered after production moves have to be solved by reactive performance tuning. Question 633. We Have An Application Whose Code Can't Be Changed.can We Improve Its Performance? Answer : We can improve the application performance without changing base SQL code by optimizing the SQL performance. Oracle has come up with SQL Advisor tool that helps SQL performance. We can make use of SQL Advisor tools' SQL Profiles to improve performance, though we can't touch the underlying SQL. Question 634. What Is The Use Of Sql Over Procedural Languages? Answer : SQL isn't a procedural language in which we have to specify the steps to be followed to achieve the statement goal. We don't have to specify how to accomplish a task(say data retrival) using SQL, rather we can specify as to what needs to be done. Question 635. What Is Query Processing? Answer : When a user starts a data retrieval operation, the user's SQL statement goes through several sequential steps that together constitute query processing. Query processing is the transformation of the SQL statement into efficient execution plan to return the requested data from the database. Question 636. What Is Query Optimization? Answer : Query optimization is the process of choosing the most efficient execution plan. The goal is to achieve the result with least cost in terms of resource usage. Resources include I/O and CPU usage on the server where the database is running. This is a means to reduce the execution times of the query, which is the sum of the execution times of the all component operations of the query. Question 637. What Are The Techniques Used For Query Optimization? Answer : Cost-based optimization, heuristic strategy are used for query optimization. Question 638. What Are The Phases Of A Sql Statement Processing? Answer : An user's SQL statement goes through the parsing, optimizing, and execution stages. If the SQL statement is a query(SELECT), data has to be retrived so there's an additional fetch stage before the SQL processing is complete. Question 639. What Is Parsing? Answer : Parsing primarily consists of checking the syntax and semantics of the SQL statements. The end product of the parse stage of query compilation is the creation of a parse tree, which represents the query structure. The parse tree is then sent to the logical query plan generation stage. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 77


Training Devision of 10daneces Question 640. Mention The Steps In The Creation Of A Parse Tree:Answer : The SQL statement is decomposed into relational algebra query that 's analyzed to see whether it's syntactically correct. 2) The query then undergoes semantic checking. 3) The data dictionary is consulted to ensure that the tables and the individual columns that are referenced in the query do exist,as well as all the object privileges. 4) The column types are checked to ensure that the data matches the column definition. 5) The statement is normalized so that it can be processed more efficiently 6) The query is rejected if it is incorrectly formulated 7) Once the parse tree passes all the syntactic and semantic checks,it is considered a valid parse tree,and it's sent to the logical query plan generation stage. Question 641. Where Does The Parse Tree Generation Take Place? Answer : The parse tree generation takes place in the library cache portion of the SGA(system global Area). Question 642. What Is Optimization/what Happens During Optimization Phase? Answer : During the optimization phase, Oracle uses its optimizer(CBO(cost-based optimizer)) to choose the best access method for retriving data for the tables and indexes referred to in the query. Question 643. How Does A Cbo Generate An Optimal Execution Plan For The Sql Statement? Answer : Using the statistics we provide and the hints specified in the SQL queries, the CBO produces an optimal execution plan for the SQL statement. Question 644. What Are The Parts Of An Optimizer Phase? Answer : An optimizer phase can be divided into two distinct parts: the query rewrite phase and the physical execution plan generation phase. Question 645. What Is Query Rewrite Phase? Answer : In this phase ,the parse tree is converted into an abstract logical query plan. This is an initial pass at an actual query plan, and it contains only a general algebraic reformulation of the initial query. The various nodes and branches of the parse tree are replaced by operators of relational algebra. Question 646. What Is Execution Plan Generation Phase/physical Execution Plan Execution Plan Generation Phase? Answer : During this phase, Oracle transforms the logical query plan into a physical query plan. The optimizer may be faced with a choice of several algorithms to solve a query. It needs to choose the most efficient algorithm to answer a query, and it needs to determine the most efficient way to implement the operations. The optimizer determines the order in which it will perform the steps. Question 647. What Are The Factors Considered By A Physical Query/execution Plan? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 78


Training Devision of 10daneces Answer : Following factors are considered by a physical query or an execution plan: The various operations(eg:joins) to be performed during the query. The order in which the operations are performed. The algorithm to be used for performing each operation. The best way to retrieve data from disk or memory. The best way to pass data from one operation to another during the query. Question 648. Which Generates The Query Plan/what Is Generated By Optimizer? Answer : The optimizer generates several valid physical query plans.All the physical query plans are potential execution plans. Question 649. How Does The Optimizer Choose The Query Plan/what Is Costbased Query Optimization? Answer : The optimizer generates several physical query plans that are potential execution plans. The optimizer then chooses among them by estimating the cost of each possible physical plan based on the table and index statistics available to it, and selecting the plan with the lowest estimated cost. This evaluation of the possible physical query plans is called cost-based query optimization. Question 650. What Are The Factors Affecting The Cost Of A Execution Plan? Answer : The cost of executing a plan is directly proportional to the amount of resources such as I/O, memory and CPU necessary to execute the proposed plan. Question 651. What Happens After Choosing The Low-cost Physical Query Plan? Answer : The optimizer passes the low-cost physical query plan to the Oracle's query execution engine. Question 652. What Is A Heuristic Strategy? Answer : The database uses a less systematic query optimiation technique known as the heuristic strategy. Question 653. What Are Unary And Binary Operations? Answer : A join operation is called a binary operation, an operation like selection is called a unary operation. Question 654. What Is An Optimal Operation Processing Strategy? Answer : In general an optimal strategy is to perform unary operations first so the more complex and timeconsuming binary operations use smaller operands. Performing as many of the possible unary operations first reduces the row sources of the join operations. Question 655. What Are The Heuristic-processing Strategies? Answer : Perform selection operation early so that we can eliminate a majority of the candidate rows early in the operation. If we leave most rows in until the end, we're going to do needless comparisons with the rows we're going to get rid of later. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 79


Training Devision of 10daneces Perform projection operations early so that we limit the number of columns we have to deal with. If we need to perform consecutive join operation,perform the operations that produce the smaller join first. Compute common expressions once and save the results. Question 656. What Is Query Execution? Answer : During the final stage of a query processing, the optimized query(the physical query plan that has been selected) is executed. If it's a SELECT statement the rows are returned to the user. If it's an INSERT,UPDATE or DELETE statement ,the rows are modified. The SQL execution engine takes the execution plan provided by the optimization phase and executes it. Question 657. What Is The Crucial Step In Sql Statement Processing? Answer : Of the three steps involved in the SQL statement processing, the optimization process is the crucial one because it determines the all important question of how fast our data will be retrived. Question 658. What Is The Job Of An Optimizer? Answer : The job of an optimizer is to find the optimal/best plan to execute our DML statements such as SELECT, INSERT, UPDATE and DELETE. Oracle uses CBO to help determine efficient methods to execute queries. Question 659. What Is An Index? Answer : An index is a data structure that takes the value of one or more columns of a table(the key) and returns all rows/requested-columns in a row quickly. Question 660. Why Is An Index Efficient? Answer : The efficiency of an index comes from the fact that it lets us find necessary rows without having to scan all the rows of a table. They need a fewer disk I/O's than if we had to scan the table and hence are efficient. Question 661. When Do We Need To Index Tables? Answer : We need to index tables only when the queries will be selecting a small portion of the table. If our query is retriving rows that are greater than 10 or 15 percent of the total rows in the table, we may not need an index. Question 662. Why Does An Index Traverses A Table's Row Faster? Answer : Indexes prevent a full table scan, so it is inherently a faster means to traverse a table's row. Question 663. What Is Rac? Answer : RAC stands for Real Application cluster. It is a clustering solution from Oracle Corporation that ensures high availability of databases by providing instance failover, media failover features. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 80


Training Devision of 10daneces Question 664. Mention The Oracle Rac Software Components ? Answer : Oracle RAC is composed of two or more database instances. They are composed of Memory structures and background processes same as the single instance database.Oracle RAC instances use two processes GES(Global Enqueue Service), GCS(Global Cache Service) that enable cache fusion.Oracle RAC instances are composed of following background processes: ACMS—Atomic Controlfile to Memory Service (ACMS). GTX0-j—Global Transaction Process. LMON—Global Enqueue Service Monitor. LMD—Global Enqueue Service Daemon. LMS—Global Cache Service Process. LCK0—Instance Enqueue Process. RMSn—Oracle RAC Management Processes (RMSn). RSMN—Remote Slave Monitor. Question 665. What Is Grd? Answer : GRD stands for Global Resource Directory. The GES and GCS maintains records of the statuses of each datafile and each cahed block using global resource directory. This process is referred to as cache fusion and helps in data integrity. Question 666. Give Details On Cache Fusion? Answer : Oracle RAC is composed of two or more instances. When a block of data is read from datafile by an instance within the cluster and another instance is in need of the same block, it is easy to get the block image from the insatnce which has the block in its SGA rather than reading from the disk. To enable inter instance communication Oracle RAC makes use of interconnects. The Global Enqueue Service(GES) monitors and Instance enqueue process manages the cache fusion. Question 667. Give Details On Acms ? Answer : ACMS stands for Atomic Controlfile Memory Service. In an Oracle RAC environment ACMS is an agent that ensures a distributed SGA memory update. SGA updates are globally committed on success or globally aborted in event of a failure. Question 668. Give Details On Gtx0-j ? Answer : The process provides transparent support for XA global transactions in a RAC environment. The database auto tunes the number of these processes based on the workload of XA global transactions. Question 669. Give Details On Lmon ? Answer : This process monitors global enqueues and resources across the cluster and performs global enqueue recovery operations. This is called as Global Enqueue Service Monitor. Question 670. Give Details On Lmd ? Answer : This process is called as global enqueue service daemon. This process manages incoming remote resource requests within each instance. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 81


Training Devision of 10daneces Question 671. Give Details On Lms ? Answer : This process is called as Global Cache service process. This process maintains statuses of datafiles and each cahed block by recording information in a Global Resource Directory(GRD). This process also controls the flow of messages to remote instances and manages global data block access and transmits block images between the buffer caches of different instances.This processing is a part of cache fusion feature. Question 672. Give Details On Lck0 ? Answer : This process is called as Instance enqueue process. This process manages non-cache fusion resource requests such as libry and row cache requests. Question 673. Give Details On Rmsn ? Answer : This process is called as Oracle RAC management process. These pocesses perform managability tasks for Oracle RAC. Tasks include creation of resources related Oracle RAC when new instances are added to the cluster. Question 674. Give Details On Rsmn ? Answer : This process is called as Remote Slave Monitor. This process manages background slave process creation andd communication on remote instances. This is a background slave process. This process performs tasks on behalf of a co-ordinating process running in another instance. Question 675. What Components In Rac Must Reside In Shared Storage? Answer : All datafiles, controlfiles, SPFIles, redo log files must reside on cluster-aware shred storage. Question 676. What Is The Significance Of Using Cluster-aware Shared Storage In An Oracle Rac Environment? Answer : All instances of an Oracle RAC can access all the datafiles, control files, SPFILE's, redolog files when these files are hosted out of cluster-aware shared storage which are group of shared disks. Question 677. Give Few Examples For Solutions That Support Cluster Storage ? Answer : ASM(automatic storage management), raw disk devices, network file system(NFS), OCFS2 and OCFS(Oracle Cluster Fie systems). Question 678. What Is An Interconnect Network? Answer : an interconnect network is a private network that connects all of the servers in a cluster. The interconnect network uses a switch/multiple switches that only the nodes in the cluster can access. Question 679. How Can We Configure The Cluster Interconnect? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 82


Training Devision of 10daneces Configure User Datagram Protocol(UDP) on Gigabit ethernet for cluster interconnect. On unia and linux systems we use UDP and RDS(Reliable data socket) protocols to be used by Oracle Clusterware. Windows clusters use the TCP protocol. Question 680. Can We Use Crossover Cables With Oracle Clusterware Interconnects? Answer : No, crossover cables are not supported with Oracle Clusterware intercnects. Question 681. What Is The Use Of Cluster Interconnect? Answer : Cluster interconnect is used by the Cache fusion for inter instance communication. Question 682. How Do Users Connect To Database In An Oracle Rac Environment? Answer : Users can access a RAC database using a client/server configuration or through one or more middle tiers ,with or without connection pooling. Users can use oracle services feature to connect to database. Question 683. What Is The Use Of A Service In Oracle Rac Environemnt? Answer : Applications should use the services feature to connect to the Oracle database. Services enable us to define rules and characteristics to control how users and applications connect to database instances. Question 684. What Are The Characteriscs Controlled By Oracle Services Feature? Answer : The charateristics include a unique name, workload balancing and failover options, and high availability characteristics. Question 685. Which Enable The Load Balancing Of Applications In Rac? Answer : Oracle Net Services enable the load balancing of application connections across all of the instances in an Oracle RAC database. Question 686. What Is A Virtual Ip Address Or Vip? Answer : A virtl IP address or VIP is an alternate IP address that the client connectins use instead of the standard public IP address. To configureVIP address, we need to reserve a spare IP address for each node, and the IP addresses must use the same subnet as the public network. Question 687. What Is The Use Of Vip? Answer : If a node fails, then the node's VIP address fails over to another node on which the VIP address can accept TCP connections but it cannot accept Oracle connections. Question 688. Give Situations Under Which Vip Address Failover Happens:Answer : VIP addresses failover happens when the node on which the VIP address runs fails, all interfaces for the VIP address fails, all interfaces for the VIP address are disconnected from the network. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 83


Training Devision of 10daneces Question 689. What Is The Significance Of Vip Address Failover? Answer : When a VIP address failover happens, Clients that attempt to connect to the VIP address receive a rapid connection refused error .They don't have to wait for TCP connection timeout messages. Question 690. What Are The Administrative Tools Used For Oracle Rac Environments? Answer : Oracle RAC cluster can be administered as a single image using OEM(Enterprise Manager), SQL*PLUS,Servercontrol(SRVCTL), clusterverificationutility(cvu), DBCA, NETCA. Question 691. How Do We Verify That Rac Instances Are Running? Answer : Issue the following query from any one node connecting through SQL*PLUS. $connect sys/sys as sysdba SQL>select * from V$ACTIVE_INSTANCES; The query gives the instance number under INST_NUMBER column,host_:instancename under INST_NAME column. Question 692. What Is Fan? Answer : Fast application Notification as it abbreviates to FAN relates to the events related to instances, services and nodes. This is a notification mechanism that Oracle RAc uses to notify other processes about the configuration and service level information that includes service status changes such as, UP or DOWN events. Applications can respond to FAN events and take immediate action. Question 693. Where Can We Apply Fan Up And Down Events? Answer : FAN UP and FAN DOWN events can be applied to instances, services and nodes. State the use of FAN events in case of a cluster configuration change? During times of cluster configuration changes, Oracle RAC high availability framework publishes a FAN event immediately when a state change occurs in the cluster. So applications can receive FAN events and react immediately. This prevents applications from polling database and detecting a problem after such a state change. Question 694. Why Should We Have Seperate Homes For Asm Instance? Answer : It is a good practice to have ASM home separate from the database home(ORACLE_HOME). This helps in upgrading and patching ASM and the Oracle database software independent of each other. Also, we can deinstall the Oracle database software independent of the ASM instance. Question 695. What Is The Advantage Of Using Asm? Answer : Having ASM is the Oracle recommended storage option for RAC databases as the ASM maximizes performance by managing the storage configuration across the disks. ASM does this by distributing the database file across all of the available storage within our cluster database environment. Question 696. What Is Rolling Upgrade? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 84


Training Devision of 10daneces Answer : It is a new ASM feature from Database 11g. ASM instances in Oracle database 11g release(from 11.1) can be upgraded or patched using rolling upgrade feature. This enables us to patch or upgrade ASM nodes in a clustered environment without affecting database availability. During a rolling upgrade we can maintain a functional cluster while one or more of the nodes in the cluster are running in different software versions. Question 697. Can Rolling Upgrade Be Used To Upgrade From 10g To 11g Database? Answer : No, it can be used only for Oracle database 11g releases(from 11.1). Question 698. Can The Dml_locks And Result_cache_max_size Be Identical On All Instances? Answer : These parameters can be identical on all instances only if these parameter values are set to zero. Question 699. Mention The Components Of Oracle Clusterware:Answer : Oracle clusterware is made up of components like voting disk and Oracle Cluster Registry(OCR). Question 700. What Is A Crs Resource? Answer : Oracle clusterware is used to manage high-availability operations in a cluster. Anything that Oracle Clusterware manages is known as a CRS resource. Some examples of CRS resources are database, an instance, a service, a listener, a VIP address, an application process etc. Question 701. What Is The Use Of Ocr? Answer : Oracle clusterware manages CRS resources based on the configuration information of CRS resources stored in OCR(Oracle Cluster Registry). Question 702. How Does A Oracle Clusterware Manage Crs Resources? Answer : Oracle clusterware manages CRS resources based on the configuration information of CRS resources stored in OCR(Oracle Cluster Registry). Question 703. Name Some Oracle Clusterware Tools And Their Uses? Answer : OIFCFG - allocating and deallocating network interfaces. OCRCONFIG - Command-line tool for managing Oracle Cluster Registry. OCRDUMP - Identify the interconnect being used. CVU - Cluster verification utility to get status of CRS resources. Question 704. What Are The Modes Of Deleting Instances From Oracle Real Application Cluster Databases? Answer : We can delete instances using silent mode or interactive mode using DBCA(Database Configuration Assistant). Question 705. How Do We Remove Asm From A Oracle Rac Environment? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 85


Training Devision of 10daneces Answer : We need to stop and delete the instance in the node first in interactive or silent mode. After that asm can be removed using srvctl tool as follows: srvctl stop asm -n node_name srvctl remove asm -n node_name

We can verify if ASM has been removed by issuing the following command: srvctl config asm -n node_name

Question 706. How Do We Verify That An Instance Has Been Removed From Ocr After Deleting An Instance? Answer : Issue the following srvctl command: srvctl config database -d database_name cd CRS_HOME/bin ./crs_stat

Question 707. How Do We Verify An Existing Current Backup Of Ocr? Answer : We can verify the current backup of OCR using the following command : ocrconfig showbackup Question 708. What Are The Performance Views In An Oracle Rac Environment? Answer : We have v$ views that are instance specific. In addition we have GV$ views called as global views that has an INST_ID column of numeric data type. GV$ views obtain information from individual V$ views. Question 709. What Are The Types Of Connection Load-balancing? Answer : There are two types of connection load-balancing: server-side load balancing and clientside load balancing. Question 710. What Is The Differnece Between Server-side And Client-side Connection Load Balancing? Answer : Client-side balancing happens at client side where load balancing is done using listener. In case of server-side load balancing listener uses a load-balancing advisory to redirect connections to the instance providing best service. Question 711. Give The Usage Of Srvctl ? Answer : srvctl start instance -d db_name -i "inst_name_list" [-o start_options]. srvctl stop instance -d name -i "inst_name_list" [-o stop_options]. srvctl stop instance -d orcl -i "orcl3,orcl4" -o immediate. srvctl start database -d name [-o start_options]. srvctl stop database -d name [-o stop_options]. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 86


Training Devision of 10daneces srvctl start database -d orcl -o mount. Question 712. What Is A San ? Answer : A storage area network (SAN) is a specialized high-speed network of storage devices and computer systems (also referred to as servers, hosts, or host servers). Currently,most SANs use the Fibre Channel protocol. A storage area network presents shared pools of storage devices to multiple servers. Each server can access the storage as if it were directly attached to that server. The SAN makes it possible to move data between various storage devices, share data between multiple servers, and back up and restore data rapidly and efficiently. In addition, a properly configured SAN provides robust security, which facilitates both disaster recovery and business continuance. Components of a SAN can be grouped closely together in a single room or connected over long distances. This makes SAN a feasible solution for businesses of any size: the SAN can grow easily with the business it supports. Question 713. Are Servers Homogenous In San Environment? Answer : No. Servers need not be homogenous in SAN environment. Each server may host numerous applications that require dedicated storage for applications processing. Question 714. How Does A San(storage Area Network) Work? Answer : The SAN (storage area network) components interact as follows: When a host wishes to access a storage device on the SAN, it sends out a blockbased access request for the storage device. The request is accepted by the HBA for that host and is converted from its binary data form to the optical form required for transmission on the fiber optic cable. At the same time, the request is “packaged� according to the rules of the Fibre Channel protocol. The HBA transmits the request to the SAN. Depending on which port is used by the HBA to connect to the fabric, one of the SAN switches receives the request and checks which storage device the host wants to access. From the host perspective, this appears to be a specific disk, but it is actually just a logical device that corresponds to some physical device on the SAN. It is up to the switch to determine which physical device has been made available to the host for its targeted logical device. Once the switch has determined the appropriate physical device, it passes the request to the appropriate storage device. Question 715. What Is A Fibre Channel Protocol(fcp)? Answer : Fibre Channel Protocol (FCP) is a transport protocol (similar to TCP used in IP networks) which predominantly transports SCSI(small computer system interface) commands over Fibre Channel networks. Question 716. What Are The Various Layers Of Fibre Channel Protocol/fibre Channel? Answer : Fibre Channel is a layered protocol. It consists of 5 layers, namely: FC0 The physical layer, which includes cables, fiber optics, connectors,pinouts etc. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 87


Training Devision of 10daneces FC1 The data link layer, which implements the 8b/10b encoding and decoding of signals. FC2 The network layer, defined by the FC-PI-2 standard, consists of the core of Fibre Channel, and defines the main protocols. FC3 The common services layer, a thin layer that could eventually implement functions like encryption or RAID. FC4 The Protocol Mapping layer. Layer in which other protocols, such as SCSI, are encapsulated into an information unit for delivery to FC2. Question 717. What Is Fc-ph? Answer : FC0, FC1, and FC2 are also known as FC-PH, the physical layers of fibre channel. Question 718. Where Does The Fiber Channel Router Operate? Answer : Fibre Channel routers operate up to FC4 level (i.e. they are in fact SCSI routers), switches up to FC2, and hubs on FC0 only. Question 719. What Are The Various Speed At Which We Use Fibre Channel Products? Answer : Fibre Channel products are available at 1 Gbit/s, 2 Gbit/s, 4 Gbit/s, 8 Gbit/s, 10 Gbit/s and 20 Gbit/s. Products based on the 1, 2, 4 and 8 Gbit/s standards should be interoperable, and backward compatible. The 10 Gbit/s standard (and 20 Gbit/s derivative), however, is not backward compatible with any of the slower speed devices, as it differs considerably on FC1 level (64b/66b encoding instead of 8b/10b encoding). 10Gb and 20Gb Fibre Channel is primarily deployed as a high-speed "stacking" interconnect to link multiple switches. Question 720. What Is An Ifcp? Answer : iFCP (Internet Fibre Channel Protocol) is an emerging standard for extending Fibre channel storage networks across the Internet. iFCP provides a means of passing data to and from Fibre Channel storage devices in a local storage area network (SAN) or on the Internet using TCP/IP. TCP provides congestion control as well as error detection and recovery services. iFCP merges existing SCSI and Fibre Channel networks into the Internet. iFCP can either replace or be used in conjunction with existing Fibre Channel protocols, such as FCIP(Fibre Channel over IP). Question 721. Why Is Ifcp Superior To Fcip? Answer : iFCP addresses some problems that FCIP does not. For example, FCIP is a tunneling protocol that simply encapsulates Fibre Channel data and forwards it over a TCP/IP network as an extension of the existing Fibre Channel network. However, FCIP is only equipped to work within the Fibre Channel environment, while the storage industry trend is increasingly towards the Internet-based storage area network. Because iFCP gateways can either replace or complement existing Fibre Channel fabrics, iFCP can be used to facilitate migration from a Fibre Channel SAN to an IP SAN or a hybrid network. Question 722. Differentiate Between Truncate And Delete. Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 88


Training Devision of 10daneces The Delete command will log the data changes in the log file where as the truncate will simply remove the data without it. Hence Data removed by Delete command can be rolled back but not the data removed by TRUNCATE. Truncate is a DDL statement whereas DELETE is a DML statement. Question 723. What Is The Maximum Buffer Size That Can Be Specified Using The Dbms_output.enable Function? Answer : 1000000. Question 724. Can You Use A Commit Statement Within A Database Trigger? Answer : Yes, if you are using autonomous transactions in the Database triggers. Question 725. What Are Oracle Precompilers? Answer : A precompiler is a tool that allows programmers to embed SQL statements in high-level source programs like C, C++, COBOL, etc. The precompiler accepts the source program as input, translates the embedded SQL statements into standard Oracle runtime library calls, and generates a modified source program that one can compile, link, and execute in the usual way. Examples are the Pro*C Precompiler for C, Pro*Cobol for Cobol, SQLJ for Java etc. Question 726. What Is Syntax For Dropping A Procedure And A Function? Are These Operations Possible? Answer : Drop Procedure/Function;

yes, if they are standalone procedures or functions. If they are a part of a package then one have to remove it from the package definition and body and recompile the package. Question 727. How To Check If Apps 11i System Is Autoconfig Enabled ? Answer : Under $AD_TOP/bin check for file adcfginfo.sh & if this exists use adcfginfo.sh contextfile=<CONTEXT>show=enabled.

If this file is not there , look for any configuration file under APPL_TOP if system is Autoconfig enabled then you will see entry like # AutoConfig automatically generates this file.It will be read and .......

Question 728. How To Check If Oracle Apps 11i System Is Rapid Clone Enabled ? Answer : For syetem to be Rapid Clone enabled , it should be Autoconfig enabled (Check above How to confirm if Apps 11i is Autoconfig enabled). You should have Rapid Clone Patches applied , Rapid Clone is part of Rapid Install Product whose Family Pack Name is ADX. By default all Apps 11i Instances 11.5.9 and above are Autoconfig and Rapid Clone enabled. Question 729. Whats Is Difference Between Two Env Files In .env And Apps.env Under $appl_top ? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 89


Training Devision of 10daneces Answer : APPS.env is main environment file which inturn calls other environment files like . env under $APPL_TOP, .env under 806 ORACLE_HOME and custom. env for any Customized environment files. Question 730. Whats Main Concurrent Manager Types? Answer : ICM - Internal Concurrent Manager which manages concurrent Managers. Standard Managers - Which Manage processesing of requests. CRM - Conflict Resolution Managers , resolve conflicts in case of incompatibility. Question 731. Whats Us Directory In $ad_top Or Under Various Product Top's ? Answer : US directory is defauly language directory in Oracle Applications. If you have multiple languages Installed in your Applications then you will see other languages directories besides US, that directory will contain reports, fmx and other code in that respective directory like FR for France, AR for arabic, simplifies chinese or spanish. Question 732. Where Is Concurrent Manager Log File Location? Answer : By default standard location is $APPLCSF/$APPLLOG , in some cases it can go to $FND_TOP/log as well. Question 733. Where Would I Find .rf9 File, And What Execatly It Dose ? Answer : These files are used during restart of patch in case of patch failure because of some reason. Question 734. Where Is Appsweb.cfg Or Appsweb_$context.cfg Stored And Why Its Used ? Answer : This file is defined by environment variable FORMS60_WEB_CONFIG_FILE This is usually in directory $OA_HTML/bin on forms tier. This file is used by any forms client session. When a user try to access forms , f60webmx picks up this file and based on this configuration file creates a forms session to user/client. Question 735. What Is Multi Node System ? Answer : Multi Node System in Oracle Applications 11i means you have Applications 11i Component on more than one system. Typical example is Database, Concurrent Manager on one machine and forms, Web Server on second machine is example of Two Node System. Question 736. Can A Function Take Out Parameters. If Not Why? Answer : No. A function has to return a value,an OUT parameter cannot return a value.

Question 737. Can The Default Values Be Assigned To Actual Parameters? Answer : Yes. In such case you don’t need to specify any value and the actual parameter will take the default value provided in the function definition. Question 738. What Is Difference Between A Formal And An Actual Parameter? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 90


Training Devision of 10daneces The formal parameters are the names that are declared in the parameter list of the header of a module. The actual parameters are the values or expressions placed in the parameter list of the actual call to the module. Question 739. Difference Between Procedure And Function? Answer : A function always returns a value, while a procedure does not. When you call a function you must always assign its value to a variable. Question 740. Can You Clone From Multi Node System To Single Node System And Vice Versa ? Answer : Yes, this is now supported via Rapid Clone, Check if your system has all prerequisite patches for Rapid Clone and you are on latest rapid clone patch. Question 741. Does Rapid Clone Takes Care Of Updating Global Orainventory Or You Have To Register Manually In Global Orainventory After Clone ? Answer : Rapid Clone will automatically Update Global oraInventory during configuration phase. You don't have to do any thing manually for Global oraInventory. Question 742. What Is .dbc File , Where Its Stored , Whats Use Of .dbc File ? Answer : dbc as name says is database connect descriptor file which stores database connection information used by application tier to connect to database. This file is in directory $FND_TOP/secure also called as FND_SECURE. Question 743. Whats Things You Do To Reduce Patch Timing ? Answer : You can take advantage of following : Merging patches via admrgpch. Use various adpatch options like nocompiledb or nocompilejsp. Use defaults file. Staged APPL_TOP during upgrades. Increase batch size (Might result into negative ). Question 744. How You Put Applications 11i In Maintenance Mode ? Answer : Use adadmin to change Maintenance mode is Oracle Apps. With AD.I you need to enable maintenance mode in order to apply apps patch via adpatch utility. If you don't want to put apps in maintenance mode you can use adpatch options=hotpatch feature. Question 745. Can You Apply Patch Without Putting Applications 11i In Maintenance Mode ? Answer : Yes, use options=hotpatch as mentioned above with adpatch Question 746. What Are Various Options Available With Adpatch ? Answer : Various options available with adpatch depending on your AD version are autoconfig, check_ exclusive, checkfile, compiledb, compilejsp, copyportion, databaseprtion, generateportion, hotpatch, integrity, maintainmrc, parallel, prereq, validate. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 91


Training Devision of 10daneces Question 747. Adident Utility Is Used For What ? Answer : ADIDENT UTILITY in oracle apps is used to find version of any file. AD Identification. for ex. "adident Header. Question 748. How Do You Pass Cursor Variables In Pl/sql? Answer : Pass a cursor variable as an argument to a procedure or function. You can, in essence, share the results of a cursor by passing the reference to that result set. Question 749. How Do You Open And Close A Cursor Variable. Why It Is Required? Answer : Using OPEN cursor_name and CLOSE cursor_name commands. The cursor must be opened before using it in order to fetch the result set of the query it is associated with. The cursor needs to be closed so as to release resources earlier than end of transaction, or to free up the cursor variable to be opened again. Question 750. What Should Be The Return Type For A Cursor Variable. Can We Use A Scalar Data Type As Return Type? Answer : The return type of a cursor variable can be %ROWTYPE or record_name%TYPE or a record type or a ref cursor type. A scalar data type like number or varchar can’t be used but a record type may evaluate to a scalar value. Question 751. What Is Use Of A Cursor Variable? How It Is Defined? Answer : Cursor variable is used to mark a work area where Oracle stores a multi-row query output for processing. It is like a pointer in C or Pascal. Because it is a TYPE, it is defined as TYPE REF CURSOR RETURN ;. Question 752. What Where Current Of Clause Does In A Cursor? Answer : The Where Current Of statement allows you to update or delete the record that was last fetched by the cursor. Question 753. Difference Between No Data Found And %notfound Answer : NO DATA FOUND is an exception which is raised when either an implicit query returns no data, or you attempt to reference a row in the PL/SQL table which is not yet defined. SQL%NOTFOUND, is a BOOLEAN attribute indicating whether the recent SQL statement does not match to any row. Question 754. What Is Ias Patch ? Answer : iAS Patch are patches released to fix bugs associated with IAS_ORACLE_HOME (Web Server Component) Usually these are shipped as Shell scripts and you apply iAS patches by executing Shell script. Note that by default ORACLE_HOME is pointing to 8.0.6 ORACLE_HOME and if you are applying iAS patch export ORACLE_HOME to iAS . You can do same by executing environment file under $IAS_ORACLE_HOME Question 755. If We Run Autoconfig Which Files Will Get Effected ? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 92


Training Devision of 10daneces In order to check list of files changes during Autoconfig , you can run adchkcfg utility which will generate HTML report. This report will list all files and profile options going to change when you run AutoConfig. Question 756. What Is Difference Between .xml File And Autoconfig ? Answer : Autoconfig is Utility to configure your Oracle Application environment. .xml file is repository of all configuration from which AutoConfig picks configuration and polulates related files. Question 757. What Is .lgi Files ? Answer : .lgi files are created with patching along with .log files . .lgi files are informative log files containing information related to patch. You can check .lgi files to see what activities patch has done. Usually informative logs. Question 758. How Will You Skip Worker During Patch ? Answer : If in your adctrl there are six option shown then seventh is hidden option.(If there are seven options visible then 8th option is to Skip worker depending on ad version). Question 759. Which Two Tables Created At Start Of Apps Patch And Drops At End Of Patch ? Answer : FND_INSTALLED_PROCESS and AD_DEFFERED_JOBS are the tables that get updated while applying a patch mainly d or unified driver. Question 760. How To Compile An Oracle Reports File ? Answer : Utility adrepgen is used to compile Reports.Synatx is given below adrepgen userid=apps source=$PRODUCT _TOPsrwfilename.rdf dest=$PRODUCT_TOPsrwfilename.rdf stype=rdffile dtype=rdffile logfile=x.log overwrite= yes batch=yes dunit=character. Question 761. What Is Difference Between Ad_bugs And Ad_applid_patches ? Answer : AD_BUGS holds information about the various Oracle Applications bugs whose fixes have been applied (ie. patched) in the Oracle Applications installation. AD_APPLIED_PATCHES holds information about the "distinct" Oracle Applications patches that have been applied. If 2 patches happen to have the same name but are different in content (eg. "merged" patches), then they are considered distinct and this table will therefore hold 2 records. Question 762. What Is Adsplice Utility ? Answer : ADSPLICE UTILITY in oracle apps is utility to add a new product.. Question 763. How Can You Licence A Product After Installation ? Answer : You can use ad utility adlicmgr to licence product in Oracle Apps. Question 764. What Is Mrc ? What You Do As Apps Dba For Mrc ? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 93


Training Devision of 10daneces MRC also called as Multiple Reporting Currency in oracle Apps. Default you have currency in US Dollars but if your organization operating books are in other currency then you as apps dba need to enable MRC in Apps. How to enable MRC coming soon.. Question 765. Where Is Jserv Configuration Files Stored ? Answer : Jserv configuration files are stored in $IAS_ORACLE_HOME/Apache/Jserv/etc. Question 766. Where Is Applications Start/stop Scripts Stored ? Answer : applications start/stop scripts are in directory $COMMON_TOP/admin/scripts/$CONTEXT_NAME. Question 767. What Are Main Configuration Files In Web Server (apache) ? Answer : Main configuration files in Oracle Apps Web Server are httpd.conf, apps.conf, oracle_apache.conf, httpd_pls.conf jserv.conf, ssp_init.txt, jserv.properties, zone.properties plsql.conf, wdbsvr.app, plsql.conf. Question 768. Can C Driver In Apps Patch Create Invalid Object In Database ? Answer : No, C driver only copies files in File System. Database Object might be invalidated during D driver when these objects are created/dropped/modified. Question 769. What Is Dev60cgi And F60cgi ? Answer : CGI stands for Common Gateway Interface and these are Script Alias in Oracle Apps used to access forms server . Usually Form Server access directly via http://hostname:port/dev60cgi/f60cgi. Question 770. Why Does A Worker Fails In Oracle Apps Patch And Few Scenarios In Which It Failed For You ? Answer : Apps Patch worker can fail in case it doesn't find expected data, object, files or any thing which driver is trying to update/edit/modify. Possible symptoms may be underlying tables/objects are invalid, a prereq patch is missing, login information is incorrect, inconsistency in seeded data. Question 771. What Is Difference Between Mod_osso And Mod_ose In Oracle Http Server ? Answer : mod_osso is module in Oracle's HTTP Server serves as Conduit between Oracle Apache Server and Singl Sign-On Server where as mod_ose is also another module in Oracle's HTTP Server serves as conduit between Oracle Apache and Oracle Servlet Engine. Question 772. What Is Difference Between Compile_all=special And Compile=all While Compiling Forms ? Answer : Both the options will compile all the PL/SQL in the resultant .FMX, .PLX, or .MMX file but COMPILE_ALL=YES also changes the cached version in the source .FMB, .PLL, or .MMB file. This confuses version control and build tools (CVS, Subversion, make, scons); they believe you've made significant changes to the source. COMPILE_ALL=SPECIAL does not do this. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 94


Training Devision of 10daneces Question 773. What Is Gsm In Oracle Application E-business Suite ? Answer : GSM stands for Generic Service Management Framework. Oracle E-Business Suite consist of various compoennts like Forms, Reports, Web Server, Workflow, Concurrent Manager . Earlier each service used to start at their own but managing these services (given that) they can be on various machines distributed across network. So Generic Service Management is extension of Concurrent Processing which manages all your services , provide fault tolerance (If some service is down ICM through FNDSM and other processes will try to start it even on remote server) With GSM all services are centrally managed via this Framework. Question 774. What Is Fndsm ? Answer : FNDSM is executable and core component in GSM ( Generic Service Management Framework discussed above). You start FNDSM services via APPS listener on all Nodes in Application Tier in E-Business Suite. Question 775. Difference Between An Implicit And An Explicit Cursor? Answer : The implicit cursor is used by Oracle server to test and parse the SQL statements and the explicit cursors are declared by the programmers. Question 776. What Is A Cursor? Answer : A cursor is a mechanism by which you can assign a name to a “select statement� and manipulate the information within that SQL statement. Question 777. What Is The Purpose Of A Cluster? Answer : A cluster provides an optional method of storing table data. A cluster is comprised of a group of tables that share the same data blocks, which are grouped together because they share common columns and are often used together. For example, the EMP and DEPT table share the DEPTNO column. When you cluster the EMP and DEPT, Oracle physically stores all rows for each department from both the EMP and DEPT tables in the same data blocks. You should not use clusters for tables that are frequently accessed individually. Question 778. How Do You Find The Number Of Rows In A Table ? Answer : By using select count(*) from tablename Question 779. Whats Is Location Of Access_log File ? Answer : access_log file by default is located in $IAS_ORACLE_HOME/ Apache/Apache/logs. Location of this file is defined in httpd.conf by patameter CustomLog or TransferLog. Question 780. What Is Your Oracle Apps 11i Webserver Version And How To Find It ? Answer : From 11.5.8 to 11.5.10 Webserver version is iAS 1.0.2.2.2, In order to find version under $IAS_ORACLE_HOME/Apache/Apache/bin execute ./httpd -version . Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 95


Training Devision of 10daneces ./httpd -version Server version: Oracle HTTP Server Powered by Apache/1.3.19 Server built: Dec 6 2005 14:59:13 (iAS 1.0.2.2.2 rollup 5). Question 781. What Is Location Of Jserv Configuration Files ? Answer : Jserv configuration files are located in $IAS_ORACLE_HOME /Apache/Jserv/etc . Question 782. What Is Plsql/database Cache ? Answer : In order to improve performance mod_pls (Apache component) caches some database content to file. This database/plssql cache is usually of type session and plsql cache session cache is used to store session information. plsql cache is used to store plsql cache i.e. used by mod_pls Question 783. Where Is Database/plsql Cache Stored ? Answer : PLSQL and session cache are stored under $IAS_ORACLE_HOME/ Apache/modplsql/cache directory. Question 784. What Is *.dbc File And Whats Is Location Of Dbc File ? Answer : DBC as name stands for is database connect descriptor file used to connect to database. This file by default located in $FND_TOP/secure directory also called as $FND_SECURE directory Question 785. What Is Content Of Dbc File And Why Its Important ? Answer : DBC file is quite important as whenever Java or any other program like forms want to connect to database it uses DBC file. Typical entry in DBC file is GUEST_USER_PWD APPS_JDBC_URL DB_HOST. Question 786. What Are Few Profile Options Which You Update After Cloning ? Answer : Rapid clone updates profile options specific to site level. If you have any profile option set at other levels like server, responsibility, user....level then reset them. Question 787. How To Retrieve Sysadmin Password ? Answer : If forgot password link is enabled and SYSADMIN account is configured with mail id user forget password link else you can reset SYSADMIN password via FNDCPASS. Question 788. Whats Is Two_task In Oracle Database ? Answer : TWO_TASK mocks your tns alias which you are going to use to connect to database. Lets assume you have database client with tns alias defined as PROD to connect to Database PROD on machine teachmeoracle.com listening on port 1521. Then usual way to connect is sqlplus username/passwd@PROD ; now if you don't want to use @PROD then you set TWO_TASK=PROD and then can simply use sqlplus username/passwd then sql will check that it has to connect to tnsalias define by value PROD i.e. TWO_TASK. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 96


Training Devision of 10daneces Question 789. What Is Gwyuid ? Answer : GWYUID, stands for Gateway User ID and password. Usually like APPLSYSPUB/PUB. Question 790. Where Gwyuid Defined And What Is Its Used In Oracle Applications ? Answer : GWYUID is defined in dbc i.e. Database Connect Descriptor file . It is used to connect to database by think clients. Question 791. If Apps_mrc Schema Is Not Used In 11.5.10 And Higher Then How Mrc Is Working ? Answer : For products like Payable, Recievables which uses MRC and if MRC is enabled then each transaction table in base schema related to currency now has an assoicated MRC Subtables. Question 792. When You Apply C Driver Patch Does It Require Database To Be Up And Why ? Answer : Yes, database and db listener should be Up when you apply any driver patch in apps. even if driver is not updating any database object connection is required to validate appsand other schema and to upload patch history information in database tables. Question 793. How You Will Avoid Your Query From Using Indexes? Answer : By changing the order of the columns that are used in the index, in the Where condition, or by concatenating the columns with some constant values. Question 794. When Do You Use Where Clause And When Do You Use Having Clause? Answer : The WHERE condition lets you restrict the rows selected to those that satisfy one or more conditions. Use the HAVING clause to restrict the groups of returned rows to those groups for which the specified condition is TRUE. Question 795. There Is A % Sign In One Field Of A Column. What Will Be The Query To Find It? Answer : SELECT column_name FROM table_name WHERE column_name LIKE ‘%%%’ ESCAPE ‘’;. Question 796. Where Will You Find Forms Configuration Details Apart From Xml File ? Answer : Forms configuration at time of startup is in script adfrmctl.sh and appsweb_$CONTEXT_NAME.cfg (defined by environment variable FORMS60_WEB_CONFIG_FILE) for forms client connection used each time a user initiates forms connection. Question 797. What Is Forms Server Executable Name ? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 97


Training Devision of 10daneces f60srvm. Question 798. What Are Different Modes Of Forms In Which You Can Start Forms Server And Which One Is Default ? Answer : You can start forms server in SOCKET or SERVLET by defualt Forms are configured to start in socket mode. Question 799. How You Will Start Discoverer In Oracle Apps 11i ? Answer : In order to start dicoverer you can use script addisctl.sh under $OAD_TOP/admin/scripts/$CONTEXT_NAME or startall.sh under $ORACLE_HOME/discwb4/util (under Middle/Application Tier). Question 800. How Many Oracle Home Are Oracle Apps And Whats Significance Of Each ? Answer : There are three $ORACLE_HOME in Oracle Apps, Two for Application Tier (Middle Tier) and One in Database Tier. ORACLE_HOME 1 : On Application Tier used to store 8.0.6 techstack software. This is used by forms, reports and discoverer. ORACLE_HOME should point to this ORACLE_HOME which applying Apps Patch. ORACLE_HOME 2: On Application Tier used by iAS (Web Server) techstack software. This is used by Web Listener and contains Apache. ORACLE_HOME 3: On Database Tier used by Database Software usually 8i,9i or 10g database. Question 801. Where Is Html Cache Stored In Oracle Apps Server ? Answer : Oracle HTML Cache is available at $COMMON_TOP/_pages. For some previous versions you might find it in $OA_HTML/_pages. Question 802. Can You Use Both Adpatch And Opatch In Apps ? Answer : Yes you have to use both in apps, for apps patches you will use ADPATCH UTILITY and for applying database patch in apps you will use opatch UTILITY. Question 803. What Is Difference Between Adpatch And Opatch ? Answer : ADPATCH is utility to apply oracle apps Patches whereas OPATCH is utility to apply database patches Question 804. How To Compile Jsp In Oracle Apps ? Answer : You can use ojspCompile.pl perl script shipped with Oracle apps to compile JSP files. This script is under $JTF_TOP/admin/scripts. Sample compilation method is perl ojspCompile.pl --compile --quiet. Question 805. How To Compile Invalid Objects In Database ? Answer : You can use admin utility to compile or you can use utlrp.sql script shipped with Oracle Database to compile Invalid Database Objects. Question 806. How Will You Find Invalid Objects In Database ? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 98


Training Devision of 10daneces Answer : using query SQLPLUS select count(*) from dba_objects where status like 'INVALID';

Question 807. What Is Web Listener ? Answer : Web Listener is Web Server listener which is listening for web Services(HTTP) request. This listener is started by adapcctl.sh and defined by directive (Listen, Port) in httpd.conf for Web Server. When you initially type request like http://becomeappsdba.blogspot.com:80 to access application here port number 80 is Web Listener port. Question 808. How To Start Apps Listener ? Answer : In Oracle 11i, you have script adalnctl.sh which will start your apps listener. You can also start it by command lsnrctl start APPS_$SID (Replace sid by your Instance SID Name) Question 809. What Is Use Of Apps Listener ? Answer : Apps Listener usually running on All Oracle Applications 11i Nodes with listener alias as APPS_$SID is mainly used for listening requests for services like FNDFS and FNDSM. Question 810. What Are Various Joins Used While Writing Subqueries? Answer : =, IN, NOT IN, IN ANY, IN ALL, EXISTS, NOT EXISTS. Question 811. What Is Difference Between Unique And Primary Key Constraints? Answer : An UNIQUE key can have NULL whereas PRIMARY key is always not NOT NULL. Both bears unique values. Question 812. What Is Difference Between Sql And Sql*plus? Answer : SQL is the query language to manipulate the data from the database. SQL*PLUS is the tool that lets to use SQL to fetch and display the data. Question 813. Which Data Type Is Used For Storing Graphics And Images? Answer : Raw, Long Raw, and BLOB. Question 814. What Is Difference Between Substr And Instr? Answer : INSTR function search string for sub-string and returns an integer indicating the position of the character in string that is the first character of this occurrence. SUBSTR function return a portion of string, beginning at character position, substring_length characters long. SUBSTR calculates lengths using characters as defined by the input character set. Question 815. What Is Difference Between Icm, Standard Managers And Crm In Concurrent Manager ? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 99


Training Devision of 10daneces Answer : ICM stand for Internal Concurrent Manager, which controls other managers. If it finds other managers down , it checks and try to restart them. You can say it as administrator to other concurrent managers. It has other tasks as well. Standard Manager :These are normal managers which control/action on the requests and does batch or single request processing. CRM acronym for Conflict Resolution Manager is used to resolve conflicts between managers and request. If a request is submitted whose execution is clashing or it is defined not to run while a particular type of request is running then such requests are actioned/assigned to CRM for Incompatibilities and Conflict resolution. Question 816. What Happens If You Don't Give Cache Size While Defining Concurrent Manager ? Answer : Lets first understand what is cache size in Concurrent Manager. When Manager picks request from FND CONCURRENT REQUESTS Queues, it will pick up number of requests defined by cache size in one shot and will work on them before going to sleep. If you don't define cache size while defining CM then it will take default value 1, i.e. picking up one request per cycle. Question 817. There Are Lot Of Dbc File Under $fnd_secure, How Its Determined That Which Dbc File To Use From $fnd_secure ? Answer : This value is determined from profile option "Applications Database ID". Question 818. What Is Rra/fndfs ? Answer : Report Review Agent(RRA) also referred by executable FNDFS is default text viewer in Oracle Applications 11i for viewing output files and log files. Question 819. What Is Pcp In Oracle Applications 11i ? Answer : PCP is acronym for Parallel Concurrurent processing. Usually you have one Concurrent Manager executing your requests but if you can configure Concurrent Manager running on two machines (Yes you need to do some additional steps in order to configure Parallel Concurrent Processing). So for some of your requests primary CM Node is on machine1 and secondary CM node on machine2 and for some requests primary CM is on machine2 and secondary CM on machine1. Question 820. Why I Need Two Concurrent Processing Nodes Or In What Scenarios Pcp Is Used ? Answer : Well If you are running GL Month end reports or taxation reports annually these reposrts might take couple of days. Some of these requests are very resource intensive so you can have one node running long running, resource intensive requests while other processing your day to day short running requets. Another scenario is when your requests are very critical and you want high resilience for your Concurrent Processing Node, you can configure PCP. So if node1 goes down you still have CM node available processing your requests.

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 100


Training Devision of 10daneces Question 821. If A View On A Single Base Table Is Manipulated Will The Changes Be Reflected On The Base Table? Answer : If changes are made to the tables and these tables are the base tables of a view, then the changes will be reference on the view. Question 822. What Is The Difference Between Customization And Configuration? Answer : Customization word used for Master Data maintenance. And Configuration word used for pricing Procedure Determination. Question 823. How To Access The Current Value And Next Value From A Sequence? Is It Possible To Access The Current Value In A Session Before Accessing Next Value? Answer : Sequence name CURRVAL, sequence name NEXTVAL. It is not possible. Only if you access next value in the session, current value can be accessed. Question 824. If Unique Key Constraint On Date Column Is Created, Will It Validate The Rows That Are Inserted With Sysdate? Answer : It won't, Because SYSDATE format contains time attached with it. Question 825. What Are The Pre-requisites To Modify Datatype Of A Column And To Add A Column With Not Null Constraint? Answer : To modify the datatype of a column the column must be empty. To add a column with NOT NULL constrain, the table must be empty. Question 826. How Many Long Columns Are Allowed In A Table? Is It Possible To Use Long Columns In Where Clause Or Order By? Answer : Only one LONG column is allowed. It is not possible to use LONG column in WHERE or ORDER BY clause. Question 827. What Is Difference Between Char And Varchar2? What Is The Maximum Size Allowed For Each Type? Answer : CHAR pads blank spaces to the maximum length. VARCHAR2 does not pad blank spaces. For CHAR the maximum length is 255 and 2000 for VARCHAR2. Question 828. What Is A Transaction? Answer : Transaction is logical unit between two commits and commit and rollback. Question 829. What Are Disadvantages Of Having Raw Devices? Answer : We should depend on export/import utility for backup/recovery (fully reliable). The tar command cannot be used for physical file backup, instead we can use dd command, which is less flexible and has limited recoveries. Question 830. When Will Be A Segment Released? Answer : When Segment is dropped. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 101


Training Devision of 10daneces When Shrink (RBS only) When truncated (TRUNCATE used with drop storage option) Question 831. What Is Use Of Rollback Segments In Oracle Database? Answer : They allow the database to maintain read consistency between multiple transactions. Question 832. What Is Advantage Of Having Disk Shadowing / Mirroring? Answer : Shadow set of disks save as a backup in the event of disk failure. In most operating systems if any disk failure occurs it automatically switchover to place of failed disk. Improved performance because most OS support volume shadowing can direct file I/O request to use the shadow set of files instead of the main set of files. This reduces I/O load on the main set of disks. Question 833. What Is Redo Log File Mirroring? How It Can Be Achieved? Answer : Process of having a copy of redo log files is called mirroring. This can be achieved by creating group of log files together, so that LGWR will automatically writes them to all the members of the current on-line redo log group. If any one group fails then database automatically switch over to next group. It degrades performance. Question 834. How To Implement The Multiple Control Files For An Existing Database? Answer : Shutdown the database. Copy one of the existing controlfile to new location. Edit Config ora file by adding new control filename. Restart the database. Question 835. What Is A Control File? Answer : Database's overall physical architecture is maintained in a file called control file. It will be used to maintain internal consistency and guide recovery operations. Multiple copies of control files are advisable. Question 836. It Is Possible To Use Raw Devices As Data Files And What Are The Advantages Over File System Files? Answer : Yes. The advantages over file system files are that I/O will be improved because Oracle is bye-passing the kernel which writing into disk. Disk corruption will be very less. Question 837. How Can We Plan Storage For Very Large Tables? Answer : Limit the number of extents in the table Separate table from its indexes. Allocate sufficient temporary storage. Question 838. How Will You Monitor The Space Allocation? Answer : By querying DBA_SEGMENT table/view. Question 839. Why Query Fails Sometimes? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 102


Training Devision of 10daneces Rollback segment dynamically extent to handle larger transactions entry loads. A single transaction may wipeout all available free space in the rollback segment tablespace. This prevents other user using rollback segments. Question 840. How The Space Utilization Takes Place Within Rollback Segments? Answer : It will try to fit the transaction in a cyclic fashion to all existing extents. Once it found an extent is in use then it forced to acquire a new extent (number of extents is based on the optimal size). Question 841. What Is The Functionality Of System Table Space? Answer : To manage the database level transactions such as modifications of the data dictionary table that record information about the free space usage. Question 842. What Is The Role Of Pctfree Parameter Is Storage Clause? Answer : This is used to reserve certain amount of space in a block for expansion of rows. Question 843. How Does Space Allocation Table Place Within A Block? Answer : Each block contains entries as follows Fixed block header Variable block header Row Header, row date (multiple rows may exists) PCTEREE (% of free space for row updating in future) Question 844. What Is The Significance Of Having Storage Clause? Answer : We can plan the storage for a table as how much initial extents are required, how much can be extended next, how much % should leave free for managing row updating, etc., Question 845. Which Parameter In Storage Clause Will Reduce Number Of Rows Per Block? Answer : PCTFREE parameter Row size also reduces no. of rows per block. Question 846. What Is Meant By Free Extent? Answer : A free extent is a collection of continuous free blocks in tablespace. When a segment is dropped its extents are reallocated and are marked as free. Question 847. How Will You Force Database To Use Particular Rollback Segment? Answer : SET TRANSACTION USE ROLLBACK SEGMENT rbs_name. Question 848. What Is Redo Log Buffer? Answer : Changes made to the records are written to the on-line redo log files. So that they can be used in roll forward operations during database recoveries. Before writing them into the redo log files, they will first brought to redo log buffers in SGA and LGWR will write into files frequently. LOG_BUFFER parameter will decide the size. Question 849. What Is Meant By Recursive Hints? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 103


Training Devision of 10daneces Number of times processes repeatedly query the dictionary table is called recursive hints. It is due to the data dictionary cache is too small. By increasing the SHARED_POOL_SIZE parameter we can optimize the size of data dictionary cache. Question 850. What Is Dictionary Cache? Answer : Dictionary cache is information about the database objects stored in a data dictionary table. Question 851. What Are Database Buffers? Answer : Database buffers are cache in the SGA used to hold the data blocks that are read from the data segments in the database such as tables, indexes and clusters DB_BLOCK_BUFFERS parameter in INIT.ORA decides the size. Question 852. What Is An Index? How It Is Implemented In Oracle Database? Answer : An index is a database structure used by the server to have direct access of a row in a table. An index is automatically created when a unique of primary key constraint clause is specified in create table command Question 853. What Is A Schema? Answer : The set of objects owned by user account is called the schema. Question 854. What Is Parallel Server? Answer : Multiple instances accessing the same database (only in multi-CPU environments). Question 855. What Is A Database Instance? Explain. Answer : A database instance (Server) is a set of memory structure and background processes that access a set of database files. The processes can be shared by all of the users. The memory structure that is used to store the most queried data from database. This helps up to improve database performance by decreasing the amount of I/O performed against data file. Question 856. What Is The Use Of Control File? Answer : When an instance of an Oracle database is started, its control file is used to identify the database and redo log files that must be opened for database operation to proceed. It is also used in database recovery. Question 857. What Does A Control File Contains? Answer : Database name - Names and locations of a database's files and redolog files. - Time stamp of database creation. Question 858. What Is The Use Of Redo Log Information? Answer : The information in a redo log file is used only to recover the database from a system or media failure prevents database data from being written to a database's data files. Question 859. What Is The Function Of Redo Log? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 104


Training Devision of 10daneces Answer : The primary function of the redo log is to record all changes made to data. Question 860. What Is A Redo Log? Answer : The set of redo log files for a database is collectively known as the database redo log. Question 861. What Are The Characteristics Of Data Files? Answer : A data file can be associated with only one database. Once created a data file can't change size. One or more data files form a logical unit of database storage called a tablespace. Question 862. What Is A Datafile? Answer : Every Oracle database has one or more physical data files. A database's data files contain all the database data. The data of logical database structures such as tables and indexes is physically stored in the data files allocated for a database. Question 863. What Is A Temporary Segment? Answer : Temporary segments are created by Oracle when a SQL statement needs a temporary work area to complete execution. When the statement finishes execution, the temporary segment extents are released to the system for future use. Question 864. What Are The Uses Of Rollback Segment? Answer : To generate read-consistent database information during database recovery and to rollback uncommitted transactions by the users. Question 865. What Is Rollback Segment? Answer : A database contains one or more rollback segments to temporarily store "undo" information. Question 866. What Is An Index Segment? Answer : Each index has an index segment that stores all of its data. Question 867. What Are The Different Types Of Segments? Answer : Data segment, index segment, rollback segment and temporary segment. Question 868. What Is A Segment? Answer : A segment is a set of extents allocated for a certain logical structure. Question 869. What Is An Extent? Answer : An extent is a specific number of contiguous data blocks, obtained in a single allocation and used to store a specific type of information. Question 870. What Is Row Chaining? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 105


Training Devision of 10daneces In circumstances, all of the data for a row in a table may not be able to fit in the same data block. When this occurs, the data for the row is stored in a chain of data block (one or more) reserved for that segment. Question 871. How To Define Data Block Size? Answer : A data block size is specified for each Oracle database when the database is created. A database users and allocated free database space in Oracle data blocks. Block size is specified in init.ora file and cannot be changed latter. Question 872. What Is Data Block? Answer : Oracle database's data is stored in data blocks. One data block corresponds to a specific number of bytes of physical database space on disk. Question 873. What Is Network Database Link? Answer : Network database link is created and managed by a network domain service. A network database link can be used when any user of any database in the network specifies a global object name in a SQL statement or object definition. Question 874. What Is Public Database Link? Answer : Public database link is created for the special user group PUBLIC. A public database link can be used when any user in the associated database specifies a global object name in a SQL statement or object definition. Question 875. What Is Private Database Link? Answer : Private database link is created on behalf of a specific user. A private database link can be used only when the owner of the link specifies a global object name in a SQL statement or in the definition of the owner's views or procedures. Question 876. What Are The Types Of Database Links? Answer : Private database link, public database link & network database link. Question 877. What Is Database Link? Answer : A database link is a named object that describes a "path" from one database to another. Question 878. When Can Hash Cluster Used? Answer : Hash clusters are better choice when a table is often queried with equality queries. For such queries the specified cluster key value is hashed. The resulting hash key value points directly to the area on disk that stores the specified rows. Question 879. What Is Hash Cluster? Answer : A row is stored in a hash cluster based on the result of applying a hash function to the row's cluster key value. All rows with the same hash key values are stored together on disk. Question 880. What Is Index Cluster? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 106


Training Devision of 10daneces A cluster with an index on the cluster key. Question 881. What Is Database? Answer : Database is a structure that stores information about multiple types of entities, the attributes (or characteristics) of the entities, and the relationships among the entities. It also contains data types for attributes and indexes. Question 882. Which Type Of Storage System Is Oracle? What Other Storage Systems Are Available? Answer : Oracle is a type of Relational Database Management System (RDBMS). Another available storage system is Hierarchical Storage Management system, such as Information Management System (IMS) from IBM and Integrated Database Management System (IDMS) from Computer Associates. Question 883. Define Database Management System (dbms) And Rdbms. Answer : DBMS is a program that defines the rules for data storage and retrieval. RDBMS is a special type of DBMS that stores the data in the relational format as described in the relational theory by E.F. Codd. Question 884. How Is Oracle Different From Other Programming Languages? Answer : Oracle or any other DBMS is a program that handles user requests (data retrieval, storage, or modification requests) without any requirement to specify the algorithm to do so. Question 885. Give Some Examples Of Join Methods. Answer : Some examples of join methods are given as follows: Merge join —Sorts both the joining tables by using the join key and then merges the sorted rows. Nested loop join —-Applies filter conditions specific to the outer table and gets a result set. After that, it joins the inner table with the result set using either an index or a full table scan. Hash join —Uses hash algorithm for filter conditions on smaller table first and then performs the same hashing algorithm on the other table for joined columns. After that, it returns the matching rows. Question 886. Which Sorting Algorithm Does Oracle Follow? Answer : Oracle used to follow a balanced binary tree sorting algorithm to effectively build an nmemory index on the incoming data. Binary tree search places a huge memory and CPU overhead on the system for large searches; therefore, Oracle introduced an algorithm based on heap sort, which is more efficient. However, it also has a limitation of reordering incoming rows even when the data is not arriving out of order. Question 887. What Is Database Designing? Answer : Database designing is a process, which follows the requirement analysis phase to determine the required database structure to satisfy application, product, or business requirements as per the given criteria. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 107


Training Devision of 10daneces Question 888. What Is The Difference Between Logical Data Model And Physical Data Model? Answer : Physical data model depicts database in terms of physical objects, such as tables and constraints; whereas, logical data model depicts database in terms of logical objects, such as entities and relationships, and it is represented by the entity- relationship model. Question 889. What Is A Primary Key? Answer : A primary key is an attribute (or a collection of attributes) that uniquely identifies each row in the table. In other words, each entity instance in a table must be unique; and therefore, primary key is a way of ensuring this. Question 890. What Is A Foreign Key? Answer : A foreign key is an attribute in a child table that matches the primary key value in the parent table. Question 891. What Is Functional Dependency? Answer : Generally, in any table or relation, an attribute or a set of attributes is used to determine the value of rest of the attributes in the table or relation. This is possible as the rest of the attributes are the functions of the key column. This situation is called functional dependency and it is possible when there exists one and only value for each non-key attributes that correspond to the key attribute. Question 892. What Is Trivial Functional Dependency? Answer : A trivial functional dependency is the situation, which shows a relation between an attribute with a superset of itself such that the attribute is dependent on the superset. Consider an attribute of the dress entity, say length. If the length attribute is dependent on the dress code attribute of the dress entity, then it is a non-trivial dependency; however, if the length attribute is dependent on the color and length attributes of the dress entity, then it is a trivial dependency. Question 893. What Is Full Functional Dependency? Answer : Full functional dependency is the situation when an attribute depends on a group of attributes completely but not on the subset of the attributes. Question 894. What Is Multi-valued Dependency? Answer : A multi-valued dependency is the situation when an attribute (assume B) is dependent on another attribute (assume A). However, there are multiple rows in a table representing the dependency. This situation can happen when there is at least one more attribute which is dependent on A and it requires to have multiple rows of A and B to represent all the possible combinations. A multi-valued dependency is represented by A->> B. Question 895. What Is Transitive Dependency? Answer : A transitive dependency is the situation when an attribute indirectly depends on another attribute through a third attribute. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 108


Training Devision of 10daneces Question 896. What Is The Standard Normal Form For Most Online Transaction Processing (oltp) Databases? Answer : 3NF is the standard normal form for most OLTP databases. Question 897. What Is Join Dependency? Answer : A join dependency is a situation where a table can be created by joining two or more tables. Question 898. What Happens When A User Requests For Some Information From Rdbms? Answer : The following steps are performed when a user requests for some information: 1. RDBMS checks if a copy of the parsed SQL statement exists in the library cache. If parsed copy exists, then steps 2 to 6 are skipped. 2. RDBMS validates the syntax of the statement. 3. RDBMS ensures that all the columns and tables referenced in the statement exist. 4. RDBMS acquires parse locks on objects referenced in the statement so that their definitions do not change while statement is parsed. 5. RDBMS ensures that the user has sufficient privileges. 6. Statement is parsed and execution plan is created. 7. Statement is executed. 8. Values are fetched. Question 899. What Do You Mean By Data Consistency? How Does Oracle Maintain Consistency Of Data? Answer : In a multi-user environment, there can be situations when one or more users are reading certain set of data while other is modifying the same set of data. Data consistency provides a stable or consistent data to the users throughout the session. Data consistency is maintained through rollback segments. A rollback segment holds the data image before change; therefore, one or more sessions will get the same image of the data throughout the session that were reading the data while another session is updating. Question 900. What Happens When Multiple Users Try To Update The Same Set Of Data? Answer : Oracle uses locking mechanism to ensure that only one session or user can update a single set of data at given point in time. Question 901. How Long Does The Rollback Segment Hold Data To Maintain Consistency? Answer : Rollback segment holds the previous version of data block until either it gets committed or the space is not available for reuse. If a session is reading specific block from rollback segment while the other session has committed the information, then more rollback space is required to maintain more rollback information. In that case, this specific block ages out of the rollback segment and the reading or selecting session gets an error. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 109


Training Devision of 10daneces Question 902. What Is The Process Of Updating Or Inserting Certain Data In The Database? Answer : Following is the process to update or insert data in the database: RDBMS searches for parsed statement in library cache or parses the statement to generate execution plan. Server process retrieves relevant data from disk to the buffer cache. In case of inserting data in the database, the data block with sufficient free space will be retrieved. Lock is acquired. The data block is updated in the buffer cache. A lock is acquired on rollback segment as well to store old version of data in case rollback is required. User process creates a redo entry in the redo log buffer to support recovery. Question 903. What Is System Change Number (scn)? Answer : SCN is an ID that Oracle generates for every transaction. It is recorded with the corresponding change in a redo entry. Question 904. What Is Log Writer (lgwr)? Answer : LGWR is the background process that writes redo information from redo log buffers to the log files. Question 905. When Does Lgwr Write To The Log File? Answer : Following are the situations when LGWR writes to the log file: When a user process commits a transaction When redo log buffer is one-third full When more than a megabyte of changes are recorded into the redo log buffer Before DBWR writes modified blocks to the datafiles Question 906. What Is The Logical Structure Of The Disk Resources? Answer : Following is the logical structure of the disk resources: Data block :Refers to the smallest logical storage unit. Size of a data block is a multiple of operating system block size. Extent :Refers to the contiguous set of data blocks, which is allocated as a unit to a segment. Tablespace :Refers to the final logical storage unit. It is mapped to physical datafile. Segment:Allocates a logical structure, such as table. It is a set of extents, which are stored in the same tablespace. Question 907. Name A Tablespace, Which Is Automatically Created When You Create A Database. Answer : The SYSTEM tablespace is created automatically during database creation. It contains data dictionary objects. All data stored on behalf of stored PL/SQL program units (procedures, functions, packages, and triggers) resides in the SYSTEM tablespace, which is always online when the database is open. Question 908. Which File Is Accessed First When You Start An Oracle Database? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 110


Training Devision of 10daneces Initialization parameter file or SPFILE is always accessed first when an Oracle database is started. This file is used to determine database level setting because those values are stored as parameters in this file. Question 909. How Do You Control The Number Of Datafiles In An Oracle Database? Answer : The number of datafiles in an Oracle database is controlled by the initialization parameter DB_FILES. Question 910. How Do You Control The Maximum Number Of Redo Log Files In A Database? Answer : The maximum number of redo log files can be controlled by the parameter MAXLOGFILES. Question 911. What Are The Advantages Of Using Spfile? Answer : SPFILE supports dynamic changes in parameter values. The changes in SPFILE can only be made by using the Oracle statements; therefore, there is no chance of accepting impossible changes as it will be checked by the system. As a result, chances of human errors are reduced. Moreover, back up of SPFILE is possible through RMAN. Question 912. How Do You View Parameter Values When You Are Using Pfile Or Spfile? Answer : You can use the SHOW PARAMETER command from SQL*Plus or query v$PARAMETER view to see the value of the parameters. Question 913. What Happens After A User Process Fails? Answer : PMON cleans up the memory after user process fails. Question 914. What Happens During Startup Mount? Answer : In case of startup mount, the parameter and control files can be read but the datafiles and the log files cannot be accessed because database is not yet open. Generally, this mode is used when a datafile recovery is required. Question 915. What Is The Difference Between Multithreaded/shared Server And Dedicated Server? Answer : In case of a dedicated server, a server process is associated with a single user process and serves it dedicatedly. In case of a shared server, a single server process can serve multiple user processes. This is achieved with the help of a dispatcher process, which places each user process in a single request queue. Server process picks up the user process whenever it is free. After that, the server process puts the result in the individual response queue associated with different dispatcher processes. Question 916. What Is A Listener Process? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 111


Training Devision of 10daneces The listener or Transparent Network Substrate (TNS) listener is a server process that provides network connectivity to the Oracle database. The listener is configured to listen for connection requests on a specified port on the database server. When an incoming request is received on the port, the listener attempts to resolve the request and forward the connection information to the appropriate database instance. Question 917. Which Files Must Be Backed Up? Answer : The following files must be backed up: Database files Control files Archived log files INIT.ORA Password files Question 918. What Is Full Backup? Answer : A full backup is a backup of all the datafiles, control files, and SPFILE. A full backup can be made with RMAN or the operating system commands while the database is open or closed. As a rule, you must perform full backup, if your database is not running in the archive log mode. Question 919. Which Tools Can You Use For Full Backup? Answer : You can use either the operating system utilities or the RMAN utility for full backup. However, Oracle recommends the use of RMAN utility. Question 920. Can You Backup The Online Redo Log Files? Answer : We cannot backup the online redo logs; however, online redo logs are protected by multiplexing and optionally by archiving. Question 921. What Is The Difference Between Hot Backup And Cold Backup? Answer : Hot backup is taken when database is still online while cold backup is taken when database is offline. Database needs to be in the archive log mode for the hot backup but there is no such requirement for the cold backup. Question 922. Why More Redo Is Generated During Hot Backup? Answer : During the hot backup, when a tablespace is put up in the backup mode, all the datafiles that belongs to the tablespace get their checkpoint frozen. When DBWR process writes the changed data blocks to the datafile, the same data blocks are written to redo log files to support roll forward process to maintain the consistency of a hot backup. This is the reason for large redo generation and requirement of archive logs for hot backup. Question 923. What Is The Difference Between Incremental Backup And Differential Backup? Answer : Both, Incremental and differential backup files that have been modified or created after the previous backup. However, attributes are reset after the incremental backup but not after the differential backup. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 112


Training Devision of 10daneces Question 924. Can We Take Incremental Backup Without Taking The Full Backup? Answer : No, full backup should be taken before the incremental backup. Question 925. What Is Rman? Answer : RMAN is an Oracle supplied tool or utility that can be used to manage backup and recovery activities. Question 926. How Do You Find The Total Database Size In The Database? Answer : You can use the following database views to get the information on database size: dba_segments —Gives the information about the used space. You can take a total of all the bytes in the dba_segments view to get the used space. dba_data__files —Gives the Information on space allocated to datafiles for permanent tablespaces. v$log— Gives the information on redo log files. Question 927. Can You Track Changes To Blocks During Hot Backup? Answer : Oracle database 11g offers bock change tracking feature. It records the information in block change tracking file. RMAN uses this information to determine specific blocks to be backed up again without re-scanning the entire datafile. Question 928. What Are The Architectural Components Of Rman? Answer : Following are the architectural components of RMAN: RMAN executable Server processes Channels Target database Recovery catalog database (optional) Media management layer (optional) Backups, backup sets, and backup pieces Question 929. How Does Rman Improve Performance Of Backup? Answer : RMAN uses multiple channels and does not take backup of free blocks. This is the reason why performance of RMAN backup is better. Question 930. What Are Channels? Answer : RMAN process uses channel to communicate with I/O devices. You can control the type of I/O device, parallelism, number of files, and size of files by allocating channels. Question 931. Can You Take Offline Backup With Rman? Answer : Yes, you can take offline backup with RMAN. Question 932. What Is A Recovery Catalog? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 113


Training Devision of 10daneces Recovery catalog is an inventory of the backup taken by RMAN for the database. It is used to restore a physical backup, reconstruct it, and make it available to the Oracle server. Question 933. Can You Use Rman Without Recovery Catalog? Answer : Yes, RMAN can be used without recovery catalog. Question 934. Why Is The Catalog Optional? Answer : Catalog is optional because RMAN manages backup and recovery operations and it requires a place to store necessary information about the database. RMAN always stores this information in the target database control file. You can also store the RMAN metadata in a recovery catalog schema contained in a separate database. The recovery catalog schema must be stored in a database other than the target database. Question 935. What Does Rman Backup Consist Of? Answer : RMAN backup consists of a backup of all or part of a database. This results from issuing an RMAN backup command. A backup consists of one or more backup sets. Question 936. What Is A Backup Set? Answer : Backup set is a logical grouping of backup files that are created when you issue an RMAN backup command. It is RMAN's name for a collection of files associated with a backup. A backup set is composed of one or more backup pieces. Question 937. If The Database Is Running In The Noarchivelog Then Which Type Of Backups Can You Take? Answer : In this case, you can take only cold backups. Question 938. Can You Take Partial Backups If The Database Is Running In The Noarchivelog Mode? Answer : In this case, partial backup is possible; however, they are not useful. Question 939. Can You Take Online Backups If The Database Is Running In The Noarchivelog Mode? Answer : No. The database needs to be in the ARCHIVELOG mode to support online backups. Question 940. Where Should You Place Archive Log Files- In The Same Disk Where Database Exists Or In Another Disk? Answer : Archive log files should not be saved in the same disk as datafiles to ensure recovery in case of media failure. They should be kept on separate mount points or disk. Question 941. Can You Take Online Backup Of A Control File? Answer : Yes, by using the following statement: alter database backup controlfile to '<location>' or trace Question 942. What Is Logical Backup? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 114


Training Devision of 10daneces Logical backup is a process of extracting data in the form of SQL statements, where it is useful to recover in case the objects are lost. The main drawback of using this backup is that MEAN TIME TO RECOVER is high. Question 943. Suppose You Lost A Control File. How Do You Recover From This? Answer : You need to perform the following steps to recover the control file: Start the database in the nomount mode Create the control file from the control file backup and place it in the correct location Mount the database Recover the database Open the database Question 944. Suppose The Current Log File Is Damaged. How Do You Recover From This? Answer : You need to perform the following steps to recover the current log file: Mount the database Create new log file and drop the damaged file Recover the database Open the database Question 945. Suppose Some Blocks Are Damaged In A Datafile. Can You Recover These Blocks If You Are Using Rman? Answer : Yes, the damaged blocks can be recovered. Question 946. What Is A Complete Recovery? Answer : Complete recovery uses redo data or incremental backups combined with a backup of a database, datafile, or tablespace to update it to the most current point in time. Oracle applies all the redo changes contained in the archived and online logs to the backup. During a complete recovery, all the changes made to the restored file since the time of the backup are re-done. Question 947. What Is Cancel-based Recovery? Answer : Cancel-based recovery is a user managed incomplete recovery where a user can apply the UNTIL CANCEL clause to perform recovery until the user manually cancels the recovery process. The process can be cancelled when the user is sure that no more recovery is possible. Cancel-based recovery is performed when there is a requirement to recover up to a particular archived redo log file. It allows a user to control the recovery process because the user can provide names of archive log files to be used for recovery. Cancel-based recovery can be performed using the following statement: SQL>RECOVER DATABASE UNTIL CANCEL Question 948. Suppose You Have Written A Script To Take Backups. How Do You Make It Run Automatically Every Week? Answer : You can create a cron job to execute the script on a preÂŹ determined schedule. Question 949. How Can You Manage Storage Options During Export Or Import? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 115


Training Devision of 10daneces You can manage storage options during export or import by using the compress option. It ensures that the storage is compressed whenever the parameter value is Y. Question 950. How Can You Ensure Data Consistency While Taking Export Dump? Answer : You can use the consistent parameter and set the value Y for this parameter to ensure that all the changes to the data are captured. However, you can use the N value to ensure that there is no transactional activity on the database during export. You need larger undo space if the Y value is being used. Question 951. Suppose You Lost Your Parameter File Accidentally And Don't Have Any Backup. How Will You Recreate A New Parameter File With The Parameters Set To Previous Values. Answer : To recreate a new parameter file, you need to store the value of non-default parameters in the alert log. It can be used to get the value of non-default parameters. Question 952. What Is Sql*loader? Answer : SQL*Loader is a tool to load data from file to a database table. Question 953. Is It Essential To Have A Character-based Delimiter In Datafile For Sql*loader To Identify Data? Answer : No. You can also use tabulation-delimited files by using one of the following statements:

Question 954. Can Sql*loader Load Unicode-based Datafiles? Answer : Yes. If the datafile was in Unicode, you can use the following code snippet to the control file:

Question 955. How Can You Load Fixed Length Records Using Sql*loader? Answer : You can use the following code snippet to load the fixed length records:

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 116


Training Devision of 10daneces

Question 956. How Can You Load Microsoft Excel Data Into Oracle? Answer : You can save the data in text file with proper separators from Microsoft Excel. After that, SQL* Loader can be used to load the data from any other text file. Question 957. How Does Sql*loader Handles Newline Characters In A Record? Answer : SQL*Loader expects a record to be in a single line; therefore, whenever it encounters a newline character in a record, it treats the record as a new record and either throws an error based on the constraints of a table or inserts erroneous records without throwing any error. Question 958. Can You Selectively Load Only Those Records That You Need? Answer : Yes, you can use the WHEN clause to specify the selection criteria. However, it does not allow you to use the OR clause; instead, you can only use the AND clause. Question 959. How Can You Load Multi-line Records? Answer : You can use the CONCATENATE or CONTINUEIF function to join multiple physical records to form a single logical record. CONCATENATE is used when SQL*Loader should combine the same number of physical records together to form one logical record. However, CONTINUEIF is used if a condition indicates that multiple records should be treated as one. For example, a # character in the first column. Question 960. How Can You Load Records With Multi-line Fields? Answer : You can define record delimiter by using stream record format. It allows you to have \n as part of a field. The record delimiter is defined after the infile clause, as shown in the following code snippet:

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 117


Training Devision of 10daneces

Question 961. How Can You Get Sql*loader To Commit Only At The End Of The Load File? Answer : You cannot ensure a commit only at the end of the load file but you can increase the value of ROWS parameter to ensure the commit after certain number of rows. Question 962. Can You Improve The Performance Of Sql*loader? Answer : You can use direct path load to improve the performance. Indexes and constraints make inserts slow. Removing indexes and constraints improve performance of inserts; and therefore, of SQL*Loader. Question 963. What Is The Difference Between The Conventional And Direct Path Loads? Answer : The direct path load loads data directly into datafiles while conventional path load uses standard insert statements. There are a few restrictions with direct path loads. The data loaded using direct path load does not replicates. Question 964. How Can You Load The Ebcdic Data? Answer : You can specify the character set WE8EBCDIC500 for the EBCDIC data. The following code snippet shows the SQL*Loader control file to load a fixed length EBCDIC record into the Oracle database:

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 118


Training Devision of 10daneces

Question 965. Can You Skip Header Records While Loading? Answer : You can use the SKIP parameter to skip number of records. In addition, you can use SKIP=1 to skip the header record. Question 966. What Is The Control File? How Is It Used? Answer : Control file is a file that contains all the information about the physical structure of the database, such as the number of log files and their location. Oracle database server uses control file to find its physical component. Question 967. Where Is The Information About Control File Stored? Answer : Initialization parameter file or server parameter file stores the information about control file. The name of the parameter to store control file information is CONTROL_FILES. Question 968. At What Stage Of Instance, Startup Information About Control File Is Read (from Parameter File)? Answer : Control file is required to mount the database; therefore, the control file information should be available before mounting, that is, at mount stage. Question 969. What Kind Of Information Is Stored In A Control File? Answer : Control file stores information about log switches, checkpoints, and modification in disk resources. Question 970. Can You Recover A Control File? Answer : No. A backup of control file generates a script to create a new control file Question 971. What Happens When Control File Is Damaged? Answer : You cannot restore the database if control file is damaged. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 119


Training Devision of 10daneces Question 972. How Do You Ensure That Control File Is Safe Considering The Importance Of It? Answer : Multiplexing is used to ensure availability of the control file. It means creating multiple copies of the control file. Ideally, you should keep those copies in different physical locations so that in case of media failure, you have at least one copy of control file that can be used. Question 973. How Do You Resize A Datafile? Answer : You can resize a datafile by using the ALTER DATABASE DATAFILE <file_name> RESIZE statement. Question 974. What View Would You Use To Look At The Size Of A Datafile? Answer : The DBA_DATA_FILES view can be used to look at the size of a datafile. Question 975. What Are Online Redo Log Files? How Are They Used? Answer : Redo log files are the disk resources to store data changes. Whenever data is changed, the information about the change is stored in the redo log file. It helps in recovery. Question 976. Define The Redo Log Group And The Redo Log Member. Answer : Redo log group is a set of identical redo log files. Each log file in the group is referred to as a redo log member. A database needs to maintain at least two redo log groups. Question 977. What Is Log Switch? Answer : A log switch is a point when LoG WRiter (LGWR) fills one online redo log group and starts writing to another. At every log switch a checkpoint occurs. Question 978. What Is Checkpoint? Answer : A checkpoint is a point when a background process updates the headers of all datafiles and control files to synchronize the files. At checkpoint, DataBase WRiter (DBWR) writes the dirty buffers to the datafile. Question 979. What Is The Need To Multiplex Redo Log File? How Can You Do That? Answer : Multiplexing is required to improve recoverability of the database in case of disk failure. You can multiplex redo log file by maintaining more than one member in each group. Question 980. What Is Pctincrease? Answer : PCTINCREASE determines the size of next extent with respect to the current extent. Question 981. A Table Is Created With The Following Setting Storage: Initial 200k Next 200k Minextents 2 Maxextents 100 Pctincrease 40. What Will Be Size Of The 4th Extent? Answer : 392K. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 120


Training Devision of 10daneces Question 982. What Is Pctused? Answer : PCTUSED is a parameter that is used to specify the percentage required for a block to be considered as used. The default value for this parameter is 40, which means that a block is considered to be used when it is more than 40% full and cannot be added to a freelist. Question 983. What Is Pctfree? Answer : PCTFREE is used to determine the portion of a block that should be left un-used for future updates. Question 984. What Is Automatic Segment Space Management (assm)? Answer : ASSM is a method used by Oracle to manage space inside data blocks. It eliminates the need to specify parameters, such as PCTUSED, freelist, and freelist groups, for objects created in the tablespace. Question 985. What Is Freelist? Answer : Freelist is a bitmap kind of structure in the header of every segment in which every bit maps to a block in the segment. This list can be used to determine which blocks are available to insert new rows. Question 986. What Is Row Migration? Answer : Whenever a row length increases, as a result of an update and the current block is unable to provide additional space, the row has to be moved to another block with sufficient space. In such situations, the original location of the row holds the rowid of the new location. Question 987. How Does Row Migration Affect Performance? Answer : In case of full table scan, the optimizer ignores rowid of individual migrated rows. Therefore, full table scans are not affected by row migration. Index read causes additional I/O's on migrated rows. In case of index read, rowids cannot be ignored. In such a case, the index scan will need to read at least two locations for a migrated row as compared to a single read for a non-migrated row. Therefore, index scans are adversely affected by row migration. Question 988. What Is Change Data Capture (cdc)? Answer : CDC is a technique to capture changes in database tables. These changes are stored in special tables. CDC operates in two modes: asynchronous, which is based on Java, and synchronous, which is based on database triggers. Performance overhead is higher in case of synchronous CDC. Question 989. What Is Oracle Streams? Answer : The Oracle Streams product from Oracle Corporation encourages users of Oracle databases to propagate information within and between databases. It provides tools to capture, process (stage), and manage database events through Advanced Queuing queues. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 121


Training Devision of 10daneces Question 990. What Is The Difference Between Oracle Streams And Cdc? Answer : Oracle Streams are based on advance queues. The Streams provide a mechanism to synchronize data between two servers. Streams ensure reliable data synchronization between the servers based on the defined rules. Both Oracle CDC and Streams are generally used for data synchronization between Oracle database servers. With Oracle CDC, you could write your own data export routines, which create flat files for the purpose of synchronization between two database servers; whereas, with Streams you must have a network link between the two servers. Question 991. What Is Database Change Notification? Answer : Database Change Notification is a service that is used to notify the registered clients whenever a change is committed. Question 992. What Is Stream Replication? Answer : Stream replication uses the information available in redo logs to synchronize data between two servers. The capture process captures the changes at source, and the changes are transported to the target database, which generates the transactions and the apply process applies those transactions. Question 993. What Is Stream? Answer : Oracle Streams is a data replication and integration feature. It enables the propagation of data, transactions, and events in a data stream either within a database or from one database to another. Question 994. What Is Streams Pool In Oracle 10g? Answer : Streams pool is a part of System Global Area (SGA) from which memory for Streams is allocated if it is configured. It can be configured by specifying initialization parameter, STREAMS_POOL_SIZE. If the size of the Streams pool is greater than zero, then any SGA memory used by Streams is allocated from the Streams pool. If the size of the Streams pool is equal to zero, then the memory used by Streams is allocated from the shared pool that may use up to 10% of the shared pool. Question 995. What Is Logical Change Record (lcr)? Answer : LCR contains database change. Streams require the changes to be captured in specific format. LCR keeps the changes in that format. Question 996. What Is The Capture Process? Answer : Capture process extracts database changes from redo log files at source. It Is a background process. Question 997. What Is The Apply Process? Answer : The apply process is a background process that runs on target database. It dequeues messages (LCR) and applies those to the target database either directly or through handler. Question 998. What Is Sys.anydata? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 122


Training Devision of 10daneces Answer : SYS.AnyData is a queue that can capture messages of type AnyData. This is a standard used in the Streams replication for storing LCRs. The reason for using this queue is that messages are wrapped into type AnyData before queuing. Question 999. What Is Downstream Capture? Answer : Generally, capture process functions at source database. However, if you want to save resources at the source database, you can set up another database for the capture process only. The feature, which allows you to move capture process to another database, is called downstream capture. Question 1000. How Can You Find The Setup Of Lob_assembly? Answer : You can find the setup of lob_assembly by using the DBA_APPLY_DML_HANDLER view. Question 1001. List Some Important Streams Views. Answer : Following are some important Streams views: DBA_STREAMS_TABLE_RULES DBA_APPLY_CONFLICT_COLUMNS GV$STREAMS_CAPTURE Question 1002. How Can You Set Dml Handler? Answer : DML handler can be set by using the following statement: Dbms_apply_adm.set_dml_handler(object_name/object_type, operation_name/error_handler,user_procedure,apply_db_link). Question 1003. How Is Rac Different From Non-rac Databases? Answer : A non-RAC database has a single node while a RAC database has multiple (at least two) nodes. The nodes in a RAC set up share storage. RAC offers failover option while a non-RAC database does not offer failover option because it is based on a single node. Question 1004. How Do You Start Or Stop An Instance On Rac? Answer : Following statements can be used to start or stop an instance on RAC:

Question 1005. What Is Global Resource Directory (grd)? Answer : GRD is used by GES and GCS to maintain status of datafiles and cached blocks. This process provides required information for cache fusion and maintains data integrity. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 123


Training Devision of 10daneces Question 1006. What Is The Benefit Of Using Virtual Ip (vip)? Answer : Whenever an application uses VIP to connect to a database, it can failover to another available node in case of a failure of one node. You need to use VIP as the host name in the Transparent Network Substrate (TNS) entry to use VIP. Question 1007. What Is The Use Of Atomic Controlfile Memory Service (acms)? Answer : ACMS ensures global updates to System Global Area (SGA) in a RAC set up. Question 1008. How Does Rac Ensures Data Consistency Between Two Nodes? Answer : RAC ensures data consistency between two nodes through cache fusion. Question 1009. What Is Cache Fusion? Answer : In a RAC setup, each node has its own memory; however, they share physical datafiles. As we know that data blocks are read into memory for updates or query in a single instance database. Similarly, in a RAC set up, a node reads a block from datafile when the node needs it. However, in RAC setting, the required block may be already available in the memory of another node and it is faster to read block from the memory of another block than from a datafile. Therefore, RAC provides a mechanism to read block from memory of one node to the memory of another node. This mechanism is called cache fusion. Oracle uses high-speed interconnect to communicate between nodes. GES monitors and the Instance Enqueue process manages the cache fusion. Question 1010. What Is The Use Of Gtxo-j? Answer : GTX is a Global Transaction process, which provides transparent support for XA global transactions. The number of these processes is decided automatically based on the requirements. Question 1011. What Is The Use Of Lock Monitor Process? Answer : It manages global resources and locks. It configures locks and resources whenever an instance joins or leaves the cluster. It is also called Global Enqueue Service Monitor. Question 1012. What Is The Use Of Lmd? Answer : LMD stands for Lock Monitor Daemon process. This process is used for deadlock detection. It also manages remote resource and enqueue requests. Question 1013. What Is The Use Of Lms? Answer : LMS stands for Lock Monitor Service. The primary job of this process is to transfer data blocks between cache of different nodes using high-speed interconnect. It is the most important and critical process for cache fusion. Each node has at least two LMS processes. Question 1014. What Is The Use Of Lcko? Answer : LCKO is lock process, which is used to manage requests for shared resources. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 124


Training Devision of 10daneces Question 1015. What Is The Use Of Rmsn? Answer : RMSn are RAC Management processes. These processes manage RAC and create more resources whenever new instances are added to RAC. Question 1016. What Is The Use Of Rsmn? Answer : RSMN stands for Remote Slave Monitor process. It creates slave processes on remote instance on behalf of master coordinating process running on another instance. Question 1017. What Components Are Shared In Rac? Answer : A RAC setup shares datafiles, control files, SP Files, redo log files; therefore, these files must be stored in the cluster-aware shared storage. Question 1018. List The Characteristics Of Oracle Services. Answer : An Oracle service must have a unique name. It offers workload balancing and failover options. Question 1019. What Enables The Load Balancing Of Applications In Rac? Answer : Oracle Net Services enables the load balancing of applications in RAC. Question 1020. What Is Vip? Answer : VIP is an IP address, which is not directly connected to any host. It is a spare address, which can be mapped to another host in the same subnet. It can be easily mapped to another host in case of a failure. Question 1021. Name The Three Network Components Of Rac. Answer : The three network components of RAC are public, private, and VIP. Question 1022. Give Situations Under Which Vip Address Failover Happens. Answer : A VIP essentially points to another host. VIP address failover happens whenever the host pointed by the VIP fails. Question 1023. Which Tools Are Available To Manage Rac Environments? Answer : RAC can be managed using Oracle Enterprise Manager (OEM), Server Control Utility (srvctl), and Database Configuration Assistant (DBCA). Question 1024. List The Situations When An Application Can Receive Fan Event Notification. Answer : Applications can receive FAN event notification in the following situations: RAC service up RAC service down Node down Load balancing advisory Question 1025. Can Rolling Upgrade Be Used To Upgrade From Oracle 10g To Oracle 11g Database? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 125


Training Devision of 10daneces Answer : No, it can only be used for Oracle database 11g releases. Question 1026. Can You Set The Result_cache_max_size Parameter To Zero On One Instance In Rac? Answer : If you set the value of RESULT_CACHE_MAX_SIZE parameter to zero, it will disable result cache. You cannot disable result cache on one node in a RAC; therefore, if you set this parameter to zero on one node, then you have to set this parameter to zero for rest of the nodes in RAC. Question 1027. Which Parameters Should Be Set While Starting Up The Asm Instance? Answer : You need to set the CLUSTER_DATABASE and INSTANCE_TYPE parameters while starting up the ASM instance. Question 1028. List The Components Of Oracle Clusterware. Answer : The components of Oracle Clusterware are given as follows: Oracle Process Monitor Daemon RACG Process Oracle Notification Service Event Manager Cluster Ready Service (CRS) Cluster Synchronization Services (CSS) Question 1029. What Is A Cluster Ready Service (crs) Resource? Answer : CRS is the main program that manages high availability operations. The resource managed by CRS process is called CRS or cluster resource, such as database, instance, service, listener, VIP address, or application process. Question 1030. What Is The Use Of Oracle Cluster Registry (ocr)? Answer : OCR stores information about cluster resources and their configuration. The CRS process uses that information to manage resources. Question 1031. What Are The Modes Of Deleting Instances From Oracle Rac Databases? Answer : You can delete the instances using either the silent mode or the interactive mode using DBCA. Question 1032. What Are The Different Types Of Connection Load Balancing? Answer : Following are the two types of connection load balancing: Server-side load balancing Client-side load balancing Question 1033. Give The Steps To Install And Configure Rac. Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 126


Training Devision of 10daneces Following are the steps to install and configure RAC: 1. Install operating system drivers 2. Configure ASM 3. Create ASM disks 4. Install grid infrastructure 5. Create additional disk groups as needed 6. Setup automatic reload of ASM Cluster File System (ACFS) drivers on reboot 7. Setup ACFS disk group 8. Install software 9. Create database 10. Perform sanity checks Question 1034. What Do You Understand By Transparent Application Failover (taf)? Answer : TAF is a major advantage of RAC. It ensures that application failover to another node of RAC when one node fails without any visible change from application. It also ensures that application servers are using proper failover in TNSNAMES.ORA files. Question 1035. Explain The Procedure Of Restoring Rman For The Recovery If All The Instances Are Down. Answer : Following is the procedure of restoring RMAN for the recovery: Bring all the nodes down Start a node Restore all the data files and archive logs Recover the node Open the database Bring other nodes up Confirm that all nodes are operational Question 1036. How Can You Connect To A Specific Node In A Rac Environment? Answer : You can use the tnsnames.ora configuration file to ensure that you have the INSTANCE_NAME parameter specified in it. Question 1037. What Is Rac Cluster? Answer : RAC cluster is a database with a shared cache architecture that overcomes the limitations of traditional shared-nothing and shared-disk approaches. It is a key component of Oracle's private cloud architecture. Question 1038. How Does An Oracle Clusterware Manage Crs Resources? Answer : The configuration information for CRS resources is stored in OCR. The Clusterware uses that information to manage CRS resources. Question 1039. What Is Global Services Daemon (gsd)? Answer : GSD runs on each node and is not an Oracle background process. This process performs administrative tasks, such as startup and shut down, based on the requests from different clients, such as DBCA and enterprise manager. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 127


Training Devision of 10daneces Question 1040. What Happens When A Data Manipulation Language (dml) Is Issued In A Rac Environment? How The Requests For Common Buffers Handled In A Rac Environment? Answer : A DML behaves on RAC in a similar manner as on a single node instance except a small change. Each node on RAC has its own buffer cache. In case of DML, it looks for the data block in a local cache. If the current copy of block is not present, cache fusion is applied to get the latest copy from the local cache of other blocks. If this is not possible then the block is read into the local cache from disk and updated similar to a single node instance. The buffer cache of other blocks is fused with the current block later as required. Question 1041. How Can You Record Information About Current Session? Answer : Oracle provides a package called dbms_application_info. This package can be used to set information about current session. Question 1042. What Is The Use Of Recording Information About Current Session? Answer : The information is useful for tracing. You can set client information, module, or action information from different module of the application. At runtime, you can query different performance views to find out the action performed by application at that specific time. Question 1043. Can You Redefine A Table Online? Answer : Yes, you can use the dbms_redefinition package to redefine a table online. Question 1044. How Can You Find Out If A Table Can Be Redefined? Answer : You can use the dbms_redefinition.can_redef_table procedure to determine if a table can be redefined. Question 1045. How Can A Session Indicate Its Interest In Receiving Alerts? Answer : A session can register itself for a specific type of alert or all alerts by using the register procedure. Such sessions are called waiting sessions. Question 1046. When Does An Alert Gets Signaled? Answer : Alerts are transaction-based. Whenever, a transaction causing event of interest commits, the alert is signaled. Question 1047. How Can You Process Messages In Order Asynchronously? Answer : Oracle provides a package called dbms_aq package to queue the messages, which can be consumed by another session or application in order. Question 1048. Suppose You Want To Audit Specific Activities On Sensitive Data. How Can You Achieve That? Answer : You can use the fine-grained auditing feature of Oracle. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 128


Training Devision of 10daneces Question 1049. What Do You Understand By Fine-grained Auditing? Answer : Fine-grained auditing can be used to implement auditing at a low level of granularity. It allows you to audit a transaction when a specific column or a row is changed. Question 1050. How Can You Implement Fine-grained Auditing? Answer : Oracle has provided a package called dbms_fga to implement fine-grained auditing. It contains the following procedures: Add_policy Drop_policy Enable_policy Disable_policy Question 1051. What Do You Understand By Flashback Feature Of Oracle? Answer : Flashback feature allows you to use a flashback version of the database, that is, you can query the database from a state in the past based on a specific System Change Number (SCN) or time in the past. Question 1052. What Are The Benefits Of Flashback Feature? Answer : Flashback feature provides the following benefits: Flashback Database —You can use this feature to flashback database to a point in past instead of restoring from backup and recovering to the specific point Flashback Standby Database —You can use this feature to flashback standby database to a time prior to point of failure Flashback Re-instantiation —You do not need to re-instantiate database following a failover using this feature Flashback Drop —You can restore dropped tables using this feature Flashback Table —You can use this feature to flashback table to a specific point Flashback Row History —This feature gives you ability to view the changes in one or more rows Flashback Transaction History —You can use this feature to diagnose problems, perform analysis, and audit transactions Question 1053. How Can You Enable Flashback Feature? Answer : Oracle provides the dbms_flashback package to use flashback feature. The package has the following procedures to facilitate this feature: Enable_at_time Enable_at_system_change_number Get_system_change_number Disable Question 1054. What Is A User-defined Lock? Answer : Oracle manages database resources through locking mechanism. These locks are usually managed by the system and are released on commit or rollback of a transaction. However, Oracle has provided this functionality to the users so that they can create userdefined locks. These locks are similar to system created locks in functionality but are Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 129


Training Devision of 10daneces not released automatically when transaction commits or rollbacks. Therefore, a user has to be extremely careful while using user-defined locks. Question 1055. How Can You Create A User-defined Lock? Answer : The dbms_lock package can be used to create user-defined locks. Question 1056. How Can You Schedule A Job In Database? Answer : You can use the dbms_scheduler package to create and schedule a database job. Question 1057. How Can You Get Actual Data Change Values From Previous Transactions In Oracle? Answer : Oracle provides a feature called log miner, which can be used to view data changes from previous transactions. Question 1058. How Can You Initialize Log Miner? Answer : You can use the DBMS_LOGMNR.START_LOGMNR procedure to initialize the log miner. Question 1059. What Functionality Does Oracle Provide To Secure Sensitive Information? Answer : You can use the dbms__obfuscation_toolkit package to encrypt sensitive information. The Data Encryption Standard (DES) or triple DES algorithm can be used to encrypt the data. Question 1060. How Can You Generate Profile Of Pl/sql Applications To Identify Performance Bottlenecks? Answer : You can use the dbms_profiler package to collect and store profile information about a PL/SQL application. Question 1061. How Can You Communicate With Operating System Files From Oracle? Answer : You can use the utl_file package to communicate with operating system files from PL/SQL code. This package provides multiple functions to open, read, write, and close the operating system files. Question 1062. Who Owns The Operating System Files Created By The Utl_file Package? Answer : The operating system files generated by utl_file are owned by operating system user Oracle. Question 1063. Name A Few Places You Will Look To Get More Details On A Performance Issue. Answer : Oracle records the information about different kind of errors and the processes in the files, such as ALERT log, user process trace files, and background process trace files.

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 130


Training Devision of 10daneces Question 1064. What Is The Use Of Alert Log File? Where Can You Find The Alert Log File? Answer : The ALERT log is a log file that records database-wide events. The information in the ALERT log file is generally used for trouble shooting. Following events are recorded in the ALERT log file: Database shutdown and startup information All non-default parameters Oracle internal (ORA-600) errors Information about a modified control file At log switch The location of ALERT log file is specified in the BACKGROUND_DUMP_DEST parameter. Question 1065. Which Tools Are Available To Monitor Performance? Answer : Oracle offers Oracle Enterprise Manager (OEM) to monitor performance. OEM can also be used to startup and shutdown the instance. In addition, it can be used to manage database in general. Question 1066. What Are The Background Trace Files? Answer : Background trace files are associated with background processes and are generated when certain background process experiences an error. The information in background trace files is generally used for trouble shooting. These files are located in the directory specified in the BACKGROUND_DUMP_DIRECTORY parameter. Question 1067. Which Trace File Is Used For Performance Tuning And Why? Answer : User process trace file is used for performance tuning because it contains information about execution plan and resource consumption. This information can be used for performance tuning. Question 1068. Which Utility Can You Use To Make Trace File More Readable? Answer : You can use the TKPROF utility to make user process trace file more readable. TKPROF converts raw information into formatted output in user process trace file. Question 1069. How Can You Monitor Performance Of The Database Proactively? Answer : Several tools, such as Oracle Enterprise Manager, and utilities from third party are available for monitoring database performance. However, all these tools or utilities depend on statistics gathered by Oracle, which are available through dynamic performance views. Question 1070. What Are Dynamic Performance Views? Who Has The Access To These Views? Answer : Dynamic performance views are also called V$ views. These views provide information about the sessions. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 131


Training Devision of 10daneces Any Oracle user can get information from dynamic performance views if the user has the select any table privilege. This privilege is generally granted through the SELECT_CATALOG_ROLE role. Question 1071. What Is A Lock? Answer : Lock is a mechanism provided by Oracle to reserve a database object so that different sessions do not interfere in each other's work. Locking helps in ensuring data consistency and maintaining database objects in usable state in multi-user environment. However, it can cause one session to block another. Question 1072. What Is Db File Sequential Read Wait Event? Answer : The db file sequential read wait event performs single-block read operations against indexes, tables, control files, rollback segments, and data file headers. It has three parameters: file#, first block#, and block count. Question 1073. What Do You Understand By Db File Scattered Read? Answer : Db file scattered read indicates a scatter read into multiple discontinuous locations. It generally indicates full table scan and that multiple blocks are being read into memory. Such reads are called scattered read calls, because the blocks are scattered throughout memory. Question 1074. Describe The Oracle Wait Interface. Answer : The Oracle Wait Interface is the set of data dictionary tables that store information about wait events. Oracle offers multiple views to give information about wait events, such as v$system_event and v$session_event. You can get the information about wait events for the database or a specific session from these views and find out the event, which seems too high. Upon further analysis, you can determine the cause of such events and then resolve the issue. Question 1075. How Can You Get More Details About The Blocking Session? Answer : You can use the v$session or gv$session view in Real Application Clusters (RAC) environment to get the session information. Question 1076. How Can You Identify Locked Object? Answer : After you get ID1 from the v$lock view for locked object, you can query the dba_objects view to get the name of the object. Question 1077. What Is A Latch? How Is It Used In Oracle? Answer : A latch is a semaphore or an on/off switch in Oracle database that a process must access in order to conduct certain type of activities. Latches govern the usage of Oracle's internal resources by its processes. They enforce serial access to the resources and limit the amount of time for which a single process can use a resource. There are over 80 latches available in Oracle. Question 1078. What Is An Event? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 132


Training Devision of 10daneces An event in Oracle is an occurrence that substantially alters the way your database executes or performs. There are two types of events in Oracle: wait events and OEMdefined events. Question 1079. Explain Wait Events. Answer : Wait event occurs when a user process is kept waiting because of some problem, such as an I/O bottleneck or a busy CPU. The information about wait event is available in the V$SYSTEM_WAIT and V$SESSION_WAIT dynamic performance views. Question 1080. What Is The Main Reason For Block Corruption? Answer : Block corruption or physical corruption occurs when a block on a physical disk becomes unreadable or inconsistent to the state that the data is unusable. Block corruption can be caused by many different sources; and therefore, it is difficult to find the exact reason of block corruption. However, it is mostly due to human error with the use of software (patches), firmware, or hardware bugs. You can avoid this by testing all the hardware and software patches thoroughly in the test environment. In addition, you can use mirrored disk to protect your data. Question 1081. Which Parameters Affect The Behavior Of Merge Join? Answer : The behavior of merge join is influenced by the initialization parameters: sort_area_size and db__file_muitiblock_read_count. Question 1082. What Is The Difference Between Latches And Enqueues? Answer : Enqueue is used to queue request for lock on any db object that can't be served immediately and session is ready to wait. Latches are internal locking mechanism of Oracle to provide short term exclusive access to Oracle's internal objects like library cache etc. Another difference is that enqueues follow first-in-first-out (FIFO) algorithm while latches do not follow any such algorithm. Question 1083. What Is Cost-based Optimizer? Answer : Cost-based optimizer is the optimizer component of the Oracle, which is recommended and supported by Oracle. It determines query plans based on overall cost of usage of each resource to get the best possible plan with respect to the resource usage cost. It uses internal statistics to determine the best execution plan for the statement. Question 1084. What Is The Statspack Tool? Answer : The STASPACK tool is an ORACLE supplied tool to monitor database performance. It can be used to diagnose instance wide problems both proactively and reactively. Question 1085. How Do You Handle Ora-01000: Maximum Open Cursors Exceeded Error? Answer : The ORA-01000: maximum open cursors exceeded error can be handled by checking the parameter setting for OPEN_CURSORS. You can resolve the error by closing the cursors that are no longer in use, raising the OPEN__CURSORS parameter within your initialization file, and restarting the Oracle database. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 133


Training Devision of 10daneces Question 1086. How Do You Handle Ora- 01403: No Data Found Error? Answer : You can handle ORA- 01403: no data found error by terminating the processing for the SELECT statement. Question 1087. Why Is Union All Faster Than Union? Answer : The UNION operation removes redundancy while UNION ALL does not; therefore, the UNION operation needs to perform sort. As a result, UNION ALL performs better as it does not need to perform any sort. Question 1088. What Is Data Guard? Answer : Data guard is a setup in which you can have one or more standby database available for a production database. Question 1089. Why Do You Need To Have Data Guard? What Are The Benefits Of Using Data Guard? Answer : Data guard setup ensures that another database is available as a copy of production database at almost real time. As a result, we have higher protection for enterprise data and the new database is available very quickly without the need to actually restore and recover from backup. Therefore, data guard offers an excellent disaster recovery solution. Question 1090. What Are The Services Required On Primary Database? Answer : Primary database requires log writer to generate log information, archiver process to generate archive log files, and fetch archive log server to request the archive log files from standby database. Question 1091. What Are The Services Required On Standby Database? Answer : Standby database requires Fetch Archive Log (FAL) client to request and fetch archive log files from primary database, remote file server to receive archived log files from primary database, archiver process to archive redo logs applied to standby database, and Managed Recovery Process (MRP) to apply redo logs to the standby database. Question 1092. What Happens When Standby Database Is Not Available? Answer : If standby database is not available and the changes are made in primary database, then there will be a gap in the sequence of archive logs. The information about archive logs in these gaps can be found in the v$archive_gap view. Question 1093. What Is Role Transition And When Does It Happen? Answer : Role transition is the change of role between primary and standby databases. It can happen in the following two cases: Switchover, where primary database is switched to standby database and standby database is switched to primary database Failover, where a standby database can be used as a disaster recovery solution in case of a failure in the primary database Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 134


Training Devision of 10daneces Question 1094. What Is The Maximum Number Of Standby Databases That Can Be Associated With A Production Database? Answer : A production database can have maximum of nine standby databases. Question 1095. What Is The Difference Between Logical Standby Database And Physical Standby Database? Answer : A physical standby database is physically same as production database, It has same file structure as production database while logical database can have different physical structure as compared to production database. A physical standby is available only when production database is not available while logical standby can be available for reporting in parallel to production database. Question 1096. How Can You Find Out Whether A Database Is Primary Or Standby? Answer : You can query the v$database view. The database_role column provides the relevant information. Question 1097. How Can You Manage Operating System Resources From The Database? Answer : You can use Database Resource Manager (DRM) to manage operating system resources. Question 1098. What Is A Drm? Answer : DRM offers a component based approach to resource allocation management. It allows you to create resource plans, which specify resource allocation to various consumer groups. You can group users based on the resource requirement. DRM offers an easy-to-use and flexible system by defining distinct independent components. Question 1099. What Are The Components Or Elements Of Drm? Answer : The three main components or elements of DRM are given as follows: Resource consumer groups Resource plans Resource plan directives Question 1100. Define Resource Consumer Group. Answer : A resource consumer group is used to classify users into logical group based on their resource consumption requirements. Following are the two ways to define resource consumer group: A resource consumer group is a method of classifying users based on their resource consumption requirements or tendencies. A resource consumer group is a method of prioritizing database resource usage by classifying users based on their business needs.

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 135


Training Devision of 10daneces Question 1101. Can You Switch Users Between Resource Consumer Groups? If Yes, How? Answer : You can switch users between resource consumer groups by using any of the following three procedures: dbms_resource_manager.switch_consumer_group_for_sess. dbms_resource_manager.switch_consumer_group_for_user. dbms_session.switch_current_consumer_group. Question 1102. What Is A Cpu Method Or Parameter? Answer : Oracle uses eight levels of CPU allocation, namely CPU_P1 to CPU_P8, to prioritize and allocate CPU usage among the competing user sessions. Question 1103. What Is Parallel Degree Limit? Answer : Parallel degree limit is an allocation method for degree of parallelism. It specifies the maximum degree of parallelism for an operation. It can be set using the PARALLEL_DEGREE_LIMIT_P1 parameter. The default value of this parameter is null which indicates no limit is imposed. Question 1104. What Is Automatic Consumer Group Switching? Answer : It is a type of resource allocation method used to automatically switch the consumer group if the switch criterion is met. The switch group is specified using the SWITCH_GROUP parameter. Switch criteria can be set using the SWITCH_TIME and SWITCH_ESTIMATE parameters. Question 1105. What Is Canceling Sql And Terminating Sessions? Answer : You can specify the directives to cancel long-running SQL queries or to terminate longrunning sessions based on the amount of system resources consumed. In other words, you can cancel SQL queries or kill sessions if consumer group meets certain criteria. The criterion is specified using the SWITCH_TIME and SWITCH_ESTIMATE parameters. The option to CANCEL_SQL or KILL_SESSION can be specified by the SWITCH_GROUP parameter. Question 1106. What Is A Sub-plan? Answer : A resource sub-plan is a plan, which gets the resource to allocate from a higher-level plan. It is created in a similar manner as a plan. However, a top-level plan gets to allocate 100% of the resources while a sub-plan can allocate only the resources allocated to it by the top-level plan. Question 1107. What Is Optimal Flexible Architecture (ofa)? Why Is It Important To Use Ofa? Answer : The OFA standard is a set of configuration guidelines created to ensure fast and reliable Oracle databases that require little maintenance. It is designed to enable the following: Organize large amounts of complicated software and data on disk, to avoid device bottlenecks and poor performance

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 136


Training Devision of 10daneces Facilitate routine administrative tasks, such as software and data backup, which are often vulnerable to data corruption Facilitate switching between multiple Oracle databases Adequately manage and administer database growth Help eliminate fragmentation of free space in the data dictionary, isolate other fragmentation, and minimize resource contention Question 1108. Give The Command To Display Space Usage On The Unix System. Answer : The df -lk command is used to display space usage on the UNIX system. Question 1109. Give The Command To List The Files In The Unix Directory To List Hidden Files. Answer : The ls -ltra command is used to list the files in the UNIX directory to list the hidden files. Question 1110. How Do You Execute A Unix Command That Will Continue Running Even After You Log Out? Answer : You can use the nohup command to execute a UNIX command that will continue running even after you log out. Normally when you log out, or your session terminates unexpectedly, the system kills all the processes you have started. In this case, you can use the nohup command, which allows you to run the command, process, or shell script that can continue running in the background after you log out from a shell. Question 1111. What Privileges Are Available On A Unix Directory? Answer : Following privileges are available on the UNIX directory or file: Read —Allows you to view and list the directory or file contents. Write —Allows you to create, edit, and delete files and subdirectories in the directory. Execute —Gives you the previous read or write permissions. It also allows you to change into the directory and execute programs or shells from the directory. Question 1112. How Can You Replace A String In A File In The Vi Editor? Answer : A string in a file can be replaced by using the %s/<old string>/<new string>/g command. Question 1113. Give Two Unix Kernel Parameters That Affect Installation Of Oracle. Answer : The SHMMAX & SHMMNI UNIX kernel parameters affect the installation of Oracle. Question 1114. List The Major Steps In Installation Of Oracle Software On Unix In Brief. Answer : Following are the steps in installation of Oracle software on UNIX: Set up disk Set up kernel parameters Run the orainst command Question 1115. How Do You Find Out The Number Of Instances That Are Running On A Server? Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 137


Training Devision of 10daneces Answer : You can check the /etc/oratab file on a server to find out all the Oracle instances running on that server. Question 1116. How Do You Automate Starting And Shutting Down Of Databases In Unix? Answer : The /etc/oratab file contains an entry for each instance running on the server. The last character of that entry indicates whether the instance should be started and shutdown automatically. You can set the value to Y for the SID to automatically start and shutdown the specific instance. Question 1117. How Do You View Virtual Memory Statistics In Linux? Answer : Virtual memory statistics are available through the vmstat command. Question 1118. Which Command Would You Use To Check How Much Hard Disk Space Is Free In Linux? Answer : The df -k or du -sk commands can be used to check the free hard disk space in Linux. Question 1119. What Is System Activity Reporter (sar)? Answer : SAR is a utility to display resource usage on the UNIX system, such as CPU activity, disk, and memory usage. There are a number of switches or options that can be used with SAR; for example, -a is used for all data and -b is used for buffer activity. Three of the main flags that can be used with SAR are given as follows: sar -u —Shows CPU activity sar -w— Shows swapping activity sar -b —Shows buffer activity Question 1120. What Is Shmmax? Answer : SHMMAX is the maximum size of a shared memory segment on a Linux system. Question 1121. What Should Be The Size Of The Swap Partition In A Ram? Answer : Swap partition should be: Equal to the size of RAM, if your RAM is less than 1G Half the size of RAM for RAM sizes from 2G to 4G 2G for RAM sizes more than 4G Question 1122. What Is Dynamic Intimate Shared Memory (dism) In Solaris? Answer : DISM in Solaris is similar to huge pages in Linux. It provides larger chunks of memory for System Global Area (SGA) to avoid paging. It is very helpful to use DISM for SGA to improve the performance of Oracle database. DISM can support up to 4 MB page size. Question 1123. Which Command Would You Use To Check How Many Memory Segments Are Acquired By Oracle Instances? Answer :

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 138


Training Devision of 10daneces You can use the ipcs -m UNIX command to check the memory segments that are acquired by Oracle instances. Question 1124. How Will You Determine Which Segment Belongs To Which Database Instances? Answer : You can use the ipcs - m command. Question 1125. Which Command Would You Use To See How Many Processes Are Running In Unix? Answer : You can use the ps command to see the currently running processes in UNIX. Question 1126. How Do You Kill A Process In Unix? Answer : You can use the kill command to kill a process in UNIX. Question 1127. Can You Change The Priority Of A Process In Unix? Answer : You can use the renice command to change the priority of a UNIX process with the following restrictions: A user can only change the nice value of processes, which they own A user cannot start processes with nice values less than 20 A user cannot lower the nice values of their processes after they have raised them Root has full access to the renice command Question 1128. How Can You Delete Blank Lines Using The Vi Editor? Answer : The :g/^$/d command can be used to delete blank lines using the vi editor. Question 1129. How Can You Go To A Specific Line Of A File Using The Vi Editor? Answer : The :<linenumber> command can be used to go to a specific line of a file using the vi editor. Question 1130. What Is The Cut Command In Unix? Answer : The cut command is used to extract sections from each line of input. Question 1131. How Can You Execute Unix Commands From Sql Plus? Answer : You can use the host command to execute the UNIX commands from SQL plus. Question 1132. How Can You Get The Details Of Smon Process? Answer : You can get the details of SMON process by using the ps -ef | grep smon command. Question 1133. How Can You Split A File In Unix? Answer : The split command can be used to split a file in UNIX; for example, split -I 2000 filetosplit.txt splittedfile.txt. Question 1134. What Are The Benefits Of Using Huge Page Memory For Sga? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 139


Training Devision of 10daneces Huge page memory is used for SGA if you have sufficient space in the huge page memory, which cannot be paged out; and therefore, it improves the performance of Oracle. Question 1135. Which Unix Command Will Control The Default File Permissions When Files Are Created? Answer : The umask command controls the default file permissions when files are created. Question 1136. How Would You Determine The Time Zone Under Which A Database Was Operating? Answer : You can determine the time zone under which a database was operating by using the select DBTIMEZONE from dual; statement. Question 1137. What Command Would You Use To Encrypt A Pl/sql Application? Answer : The WRAP command can be used to encrypt a PL/SQL application. Question 1138. How Many Columns Can Be Used To Create A Composite Index? Answer : A composite index can support 32 columns as long as total size of the columns does not exceed DB_BLOCK_SIZE. Question 1139. What Is Partitioning? Answer : Partitioning is used to divide large tables into manageable partitions based on different criteria, such as list, hash, or range. Oracle treats a partition similar to a table. Therefore, partitioning allows you to operate on one partition at a time without affecting the application. Question 1140. What Is Conditional Compilation? Answer : Conditional compilation allows you to compile code conditionally based on compiler directives. It is helpful when you need to have different code based on certain conditions. Question 1141. Explain Materialized Views. Answer : Materialized views are also called snapshot. They represent a state of data at a specific point in time. These are generally used in warehouse application to avoid commonly used data analysis by storing analyzed data. Unlike normal views, they actually store data and need to be refreshed. Question 1142. What Is A Database Trigger? Answer : A database trigger is event driven program. You do not need to invoke a trigger. It is fired whenever triggering event happens. Question 1143. What Is Statement-level Trigger? Answer : Statement-level trigger is a trigger that executes once for a statement regardless of the number of rows affected by the triggering event. It is fired when a bulk insert (FORALL insert) is performed. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 140


Training Devision of 10daneces Question 1144. What Is Row-level Trigger? Answer : A row trigger is fired each time the table is affected by the triggering statement. It is useful in case the code in the trigger depends on data provided by the triggering statement or rows that are affected. Question 1145. What Do You Understand By Data Definition Language (ddl) Trigger? Answer : The DDL trigger executes every time a DDL statement is executed. These are associated with a database or schema. Question 1146. What Is System-level Trigger? Answer : These triggers are defined on system-level. The triggers are fired at system-level events, such as logon, logoff, startup, and DDL, which are explained as follows: Database startup triggers —Refer to the triggers that are fired at database startup. These can be used to automate certain action that you want to perform every time at startup. Logon triggers —Refer to the triggers that are fired at logon. You can use these trigger to generate audit information related to logon. Logoff triggers —Refer to the triggers that are fired at logoff time. You can include certain session closure related activities in these triggers. Server error triggers —Refer to the triggers that are fired at server error. These triggers can be used to log error details and send email notification. DDL triggers --Refer to the triggers that are fired at DDL operations and can be used to audit DDL changes. Question 1147. You Have An Update Statement On A Table. The Table Has Statement-level And Row-level Triggers. Suppose The Statement Updates N Number Of Rows. How Many Times Triggers Will Be Fired? Answer : The triggers will be fired N+1 number of times. Row level trigger will be fired n number of times, once for each row-level trigger and the statement-level trigger will be fired once. Question 1148. What Permissions Must Be Granted To Users To Allow Them To Connect To The Database? Answer : You should grant the CONNECT permission to the user. Question 1149. What Is A Database Link? What Is The Difference Between A Public And A Private Database Link? What Is A Fixed User Database Link? Answer : A database link is created to access a remote database from a local database. One requirement to create a database link is that the database server should be able to connect to the remote database. A private database link is available to the owner of the link while a public database link is available to all the users. A fixed user database link is available only to the user specified in the link. Question 1150. What Is Execute Immediate? Answer : Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 141


Training Devision of 10daneces EXECUTE IMMEDIATE is a statement required to process most dynamic SQL statements. Question 1151. What Is Null? Answer : Oracle has a specific value called null which is neither equal nor not equal to any value. In addition, null is neither true nor false. A value can be checked for null using special operator called IS NULL or IS NOT NULL Question 1152. Can You Pivot The Results Of A Query? Answer : You can use hierarchical query with the sys_connect_by_path function in Oracle 9i and above to pivot the result. Question 1153. What Are Different Types Of Cursors? Answer : There are following two types of cursors: Implicit cursor —Created by Oracle for-each individual SQL. If you use an implicit cursor, Oracle performs the open, fetch, and close operations automatically. Explicit cursor —Used to fetch and manipulate multiple rows. As the name suggests, explicit cursor is specified explicitly. It is declared, opened, fetched, and closed specifically. It is used with loop structures. Question 1154. What Is Recursive Sql? Answer : Whenever you execute an SQL statement, Oracle performs a number of tasks behind the scenes, such as privilege checks and object existence checks. It needs to execute multiple SQL statements to perform those tasks. These SQLs are called recursive SQLs. Question 1155. How Do You Capture An Exception In Oracle? Answer : A PL/SQL code block has an exception section, which can be used to capture and handle exception. The section begins with the keyword EXCEPTION. You can capture an exception by specifying its name and then state appropriate action to handle the exception. Question 1156. If A Table Has Few Rows, Should You Create Indexes On This Table? Answer : You can build bit-map index but it may not be used in the Online Transaction Processing (OLTP) environment because it is not selective and may not add value to query performance. Therefore, practically in OLTP application, you should not build an index on this table. Question 1157. Suppose A Column Has Many Repeated Values. Which Type Of Index You Should Create On This Column? Answer : Bit-map index should be created on this column. Question 1158. Can You Import Objects From Oracle Version 7.3 To 9i? Answer : Yes, you can use the exp or imp utilities to import the objects from Oracle version 7.3 to 9i. Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 142


Training Devision of 10daneces Our Technology Specialization and Certification Courses:

Interview Question For Oracle DBA For detail knowledge and information contact at 9968634018

Page 143


Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.