dba interview q&a

130
DBA interview Questions and answers second set Helpful questions and answers. Each one needs to know what the questions that he will face in the interview, so here are some questions and answers. Dipti 17/9/2008

Upload: kalimireddy

Post on 15-Dec-2015

28 views

Category:

Documents


5 download

DESCRIPTION

DBA Interview Questions and Answers

TRANSCRIPT

Page 1: DBA Interview Q&A

DBA interview Questions and answers second setHelpful questions and answers.

Each one needs to know what the questions that he will face in the interview, so here are some questions and answers.

Dipti17/9/2008

Page 2: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

http://www.geekinterview.com/Interview-Questions/Oracle/Database-Administrationhttp://www.coolinterview.com/type.asp?iType=8

Technical - Oracle

1. Explain the difference between a hot backup and a cold backup and the benefits associated with each

2. You have just had to restore from backup and do not have any control files. How would you go about bringing up this database?

3. How do you switch from an init.ora file to a spfile? 4. Explain the difference between a data block, an extent and a segment. 5. Give two examples of how you might determine the structure of the table

DEPT. 6. Where would you look for errors from the database engine? 7. Compare and contrast TRUNCATE and DELETE for a table. 8. Give the reasoning behind using an index. 9. Give the two types of tables involved in producing a star schema and the type

of data they hold. 10. . What type of index should you use on a fact table? 11. . Give two examples of referential integrity constraints. 12. 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? 13. Explain the difference between ARCHIVELOG mode and NOARCHIVELOG mode

and the benefits and disadvantages to each. 14. What command would you use to create a backup control file? 15. Give the stages of instance startup to a usable state where normal users may

access it. 16. What column differentiates the V$ views to the GV$ views and how? 17. How would you go about generating an EXPLAIN plan? 18. How would you go about increasing the buffer cache hit ratio? 19. Explain an ORA-01555 20. Explain the difference between $ORACLE_HOME and $ORACLE_BASE. 21. How would you determine the time zone under which a database was

operating? 22. Explain the use of setting GLOBAL_NAMES equal to TRUE. 23. What command would you use to encrypt a PL/SQL application? 24. Explain the difference between a FUNCTION, PROCEDURE and PACKAGE. 25. Explain the use of table functions. 26. Name three advisory statistics you can collect. 27. Where in the Oracle directory tree structure are audit traces placed? 28. Explain materialized views and how they are used. 29. When a user process fails, what background process cleans up after it? 30. What background process refreshes materialized views? 31. How would you determine what sessions are connected and what resources

they are waiting for? 32. Describe what redo logs are. 33. How would you force a log switch? 34. Give two methods you could use to determine what DDL changes have been

made. 35. What does coalescing a tablespace do?

Page 3: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

36. What is the difference between a TEMPORARY tablespace and a PERMANENT tablespace?

37. Name a tablespace automatically created when you create a database. 38. When creating a user, what permissions must you grant to allow them to

connect to the database? 39. How do you add a data file to a tablespace? 40. How do you resize a data file? 41. What view would you use to look at the size of a data file? 42. What view would you use to determine free space in a tablespace? 43. How would you determine who has added a row to a table? 44. How can you rebuild an index? 45. Explain what partitioning is and what its benefit is. 46. You have just compiled a PL/SQL package but got errors, how would you view

the errors? 47. How can you gather statistics on a table? 48. How can you enable a trace for a session? 49. What is the difference between the SQL*Loader and IMPORT utilities? 50. Name two files used for network connection to a database.

Technical - UNIX

1. How do you list the files in an UNIX directory while also showing hidden files? 2. How do you execute a UNIX command in the background? 3. What UNIX command will control the default file permissions when files are

created? 4. Explain the read, write, and execute permissions on a UNIX directory. 5. What is the difference between a soft link and a hard link? 6. Give the command to display space usage on the UNIX file system. 7. Explain iostat, vmstat and netstat. 8. How would you change all occurrences of a value using VI? 9. Give two UNIX kernel parameters that effect an Oracle install 10. Briefly, how do you install Oracle software on UNIX.

الثانية المجموعة

SQL AND SQL Plus

1. Which of the following statements contains an error?a.. SELECT * FROM emp WHERE empid = 493945;b. SELECT empid FROM emp WHERE empid= 493945;c. SELECT empid FROM emp;d. SELECT empid WHERE empid = 56949 AND lastname = ‘SMITH’;

2. Which of the following correctly describes how to specify a column alias?a. Place the alias at the beginning of the statement to describe the table.b. Place the alias after each column, separated by white space, to describe the column.

Page 4: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

c. Place the alias after each column, separated by a comma, to describe the column.d. Place the alias at the end of the statement to describe the table.

3. The NVL functiona. Assists in the distribution of output across multiple columns.b. Allows the user to specify alternate output for non-null column values.c. Allows the user to specify alternate output for null column values.d. Nullifies the value of the column output

Ans C

4. Output from a table called PLAYS with two columns, PLAY_NAME and AUTHOR, is shown below.Which of the following SQL statements produced it?

PLAY_TABLE“Midsummer Night’s Dream”, SHAKESPEARE“Waiting For Godot”, BECKETT“The Glass Menagerie”, WILLIAMS

a SELECT play_name || author FROM plays;b SELECT play_name, author FROM plays;c SELECT play_name||’, ‘ || author FROM plays;d SELECT play_name||’, ‘ || author PLAY_TABLE FROM plays;

5. Issuing the DEFINE_EDITOR=”emacs” will produce which outcome?a. The emacs editor will become the SQL*Plus default text editor.b. The emacs editor will start running immediately.c. The emacs editor will no longer be used by SQL*Plus as the default text editor.d. The emacs editor will be deleted from the system.

6. The user issues the following statement. What will be displayed if the EMPID selected is 60494?SELECT DECODE(empid,38475, “Terminated”,60494, “LOA”, “ACTIVE”)FROM emp;a. 60494b. LOAc. Terminatedd. ACTIVE

7. SELECT (TO_CHAR(NVL(SQRT(59483), “INVALID”)) FROM DUAL is a valid SQL statement.a. TRUEb. FALSE

8. The appropriate table to use when performing arithmetic calculations on values defined within the

Page 5: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

SELECT statement (not pulled from a table column) isa. EMPb. The table containing the column valuesc. DUALD. An Oracle-defined table

9. Which of the following is not a group function?a. avg( )c. sqrt( )c. sum( )d. max( )

10. Once defined, how long will a variable remain so in SQL*Plus?a. Until the database is shut downb. Until the instance is shut downc. Until the statement completesd. Until the session completes

11. The default character for specifying runtime variables in SELECT statements isa. Ampersandb. Ellipsesc. Quotation marksd. Asterisk

12. A user is setting up a join operation between tables EMP and DEPT. There are some employees in the EMP tablethat the user wants returned by the query, but the employees are not assigned to departments yet. Which SELECTstatement is most appropriate for this user?a. select e.empid, d.head from emp e, dept d;b. select e.empid, d.head from emp e, dept d where e.dept# = d.dept#;c. select e.empid, d.head from emp e, dept d where e.dept# = d.dept# (+);d. select e.empid, d.head from emp e, dept d where e.dept# (+) = d.dept#;

13. Developer ANJU executes the following statement: CREATE TABLE animals AS SELECT * fromMASTER.ANIMALS; What is the effect of this statement?a. A table named ANIMALS will be created in the MASTER schema with the same data as the ANIMALStable owned by ANJUb. A table named ANJU will be created in the ANIMALS schema with the same data as the ANIMALStable owned by MASTERc. A table named ANIMALS will be created in the ANJU schema with the same data as the ANIMALStable owned by MASTER.d. A table named MASTER will be created in the ANIMALS schema with the same data

Page 6: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

as the ANJUtable owned by ANIMALS.

14. User JANKO would like to insert a row into the EMPLOYEE table, which has three columns: EMPID,LASTNAME, and SALARY. The user would like to enter data for EMPID 59694, LASTNAME Harris,but no salary. Which statement would work best?a. INSERT INTO employee VALUES (59694,’HARRIS’, NULL);b. INSERT INTO employee VALUES (59694,’HARRIS’);c. INSERT INTO employee (EMPID, LASTNAME, SALARY) VALUES (59694,’HARRIS’);d. INSERT INTO employee (SELECT 59694 FROM ‘HARRIS’);

15. Which three of the following are valid database datatypes in Oracle? (Choose three.)a. CHARb. VARCHAR2c. BOOLEANd. NUMBER

16. Omitting the WHERE clause from a DELETE statement has which of the following effects?a. The delete statement will fail because there are no records to delete.b. The delete statement will prompt the user to enter criteria for the deletionc. The delete statement will fail because of syntax error.d. The delete statement will remove all records from the table.

17. Creating a foreign-key constraint between columns of two tables defined with two different datatypes willproduce an error.a. TRUEb. FALSE

18. Dropping a table has which of the following effects on a nonunique index created for the table?a. No effect.b. The index will be dropped.c. The index will be rendered invalid.d. The index will contain NULL values.

19. To increase the number of nullable columns for a table,a. Use the alter table statement.b. Ensure that all column values are NULL for all rows.c. First increase the size of adjacent column datatypes, then add the column.d. Add the column, populate the column, then add the NOT NULL constraint.

Page 7: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

20. Which line of the following statement will produce an error?a. CREATE TABLE goodsb. (good_no NUMBER,c. good_name VARCHAR2 check(good_name in (SELECT name FROM avail_goods)),d. CONSTRAINT pk_goods_01e. PRIMARY KEY (goodno));f. There are no errors in this statement.

21. MAXVALUE is a valid parameter for sequence creation.a. TRUEb. FALSE

22. Which of the following lines in the SELECT statement below contain an error?a SELECT DECODE(empid, 58385, “INACTIVE”, “ACTIVE”) empidb. FROM empc. WHERE SUBSTR(lastname,1,1) > TO_NUMBER(’S')d. AND empid > 02000e. ORDER BY empid DESC, lastname ASC;f. There are no errors in this statement.

23. Which function below can best be categorized as similar in function to an IF-THEN-ELSE statement?a. SQRTb. DECODEc. NEW_TIMEd. ROWIDTOCHAR

24. Which two of the following orders are used in ORDER BY clauses? (choose two)a. ABSb. ASCc. DESCd. DISC

26. Which of the following statements is true about implicit cursors?a. Implicit cursors are used for SQL statements that are not named.b. Developers should use implicit cursors with great care.c. Implicit cursors are used in cursor for loops to handle data processing.d. Implicit cursors are no longer a feature in Oracle.

27. Which of the following is not a feature of a cursor FOR loop?a. Record type declaration.b. Opening and parsing of SQL statements.c. Fetches records from cursor.d. Requires exit condition to be defined.

Page 8: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

28. A developer would like to use referential datatype declaration on a variable. The variable name isEMPLOYEE_LASTNAME, and the corresponding table and column is EMPLOYEE, and LNAME,respectively. How would the developer define this variable using referential datatypes?a. Use employee.lname%type.b. Use employee.lname%rowtype.c. Look up datatype for EMPLOYEE column on LASTNAME table and use that.d. Declare it to be type LONG.

29. Which three of the following are implicit cursor attributes?a. %foundb. %too_many_rowsc. %notfoundd. %rowcounte. %rowtype

30. If left out, which of the following would cause an infinite loop to occur in a simple loop?a. LOOPb. END LOOPc. IF-THENd. EXIT

31. Which line in the following statement will produce an error?a. cursor action_cursor isb. select name, rate, actionc. into action_recordd. from action_table;e. There are no errors in this statement.

32. The command used to open a CURSOR FOR loop isa. openb. fetchc. parsed. None, cursor for loops handle cursor opening implicitly.

33. What happens when rows are found using a FETCH statementa. It causes the cursor to closeb. It causes the cursor to openc. It loads the current row values into variablesd. It creates the variables to hold the current row values

34. CREATE OR REPLACE PROCEDURE find_cpt (v_movie_id {ArgumentMode}NUMBER,v_cost_per_ticket {argument mode} NUMBER)IS

Page 9: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

BEGINIF v_cost_per_ticket > 8.5 THENSELECT cost_per_ticketINTO v_cost_per_ticketFROM gross_receiptWHERE movie_id = v_movie_id;END IF;END;Which mode should be used for V_COST_PER_TICKET?a. INb. OUTc. RETURNd. IN OUT

35. CREATE OR REPLACE TRIGGER update_show_gross {trigger information}BEGIN{additional code}END;The trigger code should only execute when the column, COST_PER_TICKET, is greater than $3.75. Whichtrigger information will you add?a. WHEN (new.cost_per_ticket > 3.75)b. WHEN (:new.cost_per_ticket > 3.75c. WHERE (new.cost_per_ticket > 3.75)d. WHERE (:new.cost_per_ticket > 3.75)

36. What is the maximum number of handlers processed before the PL/SQL block is exited when an exceptionoccurs?a. Only oneb. All that applyc. All referencedd. None

37. For which trigger timing can you reference the NEW and OLD qualifiers?a. Statement and Rowb. Statement onlyc. Row onlyd. Oracle Forms trigger

38. CREATE OR REPLACE FUNCTION get_budget(v_studio_id IN NUMBER) RETURN numberISv_yearly_budget NUMBER;BEGINSELECT yearly_budgetINTO v_yearly_budget

Page 10: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

FROM studioWHERE id = v_studio_id;RETURN v_yearly_budget;END;Which set of statements will successfully invoke this function within SQL*Plus?a VARIABLE g_yearly_budget NUMBER EXECUTE g_yearly_budget := GET_BUDGET(11);b. VARIABLE g_yearly_budget NUMBER EXECUTE :g_yearly_budget := GET_BUDGET(11);c. VARIABLE :g_yearly_budget NUMBER EXECUTE :g_yearly_budget := GET_BUDGET(11);d. VARIABLE g_yearly_budget NUMBER :g_yearly_budget := GET_BUDGET(11);

39.CREATE OR REPLACE PROCEDURE update_theater (v_name IN VARCHAR2, v_theater_id INNUMBER) ISBEGINUPDATE theaterSET name = v_nameWHERE id = v_theater_id;END update_theater;When invoking this procedure, you encounter the error: ORA-00001: Unique constraint(SCOTT.THEATER_NAME_UK) violated.How should you modify the function to handle this error?a. An user defined exception must be declared and associated with the error code and handled in theEXCEPTION section.b. Handle the error in EXCEPTION section by referencing the error code directly.c. Handle the error in the EXCEPTION section by referencing the UNIQUE_ERROR predefined exception.d. Check for success by checking the value of SQL%FOUND immediately after the UPDATE statement.

40.CREATE OR REPLACE PROCEDURE calculate_budget IS v_budget studio.yearly_budget%TYPE;BEGINv_budget := get_budget(11);IF v_budget

الخامسة المجموعة

Oracle DBA Questions

Page 11: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

1. SNAPSHOT is used for [DBA]a. Synonym, b. Table space, c System server, d Dynamic data replication

Answer : D

2. We can create SNAPSHOTLOG for[DBA]a. Simple snapshots, b. Complex snapshots, c. Both A & B, d Neither A nor BAnswer : A3. Transactions per rollback segment is derived from[DBA]a. Db_Block_Buffers, b. Processes, c. Shared_Pool_Size, d. None of the above

Answer : B

4. ENQUEUE resources parameter information is derived from[DBA]a. Processes or DDL_LOCKS and DML_LOCKS, b. LOG_BUFFER,c. DB__BLOCK_SIZE..

Answer : A

5. LGWR process writes information intoa Database files, b Control files, c Redolog files, d All the above.

Answer : C

6. SET TRANSACTION USE ROLLBACK SEGMENT is used to create userobjects in a particular Tablespacea True, b FalseAnswer : False

7. Databases overall structure is maintained in a file calleda Redolog file, b Data file, c Control file, d All of the above.

Answer : C

8. These following parameters are optional in init.ora parameter file DB_BLOCK_SIZE, PROCESSESa True, b FalseAnswer : False

9. Constraints cannot be exported through EXPORT commanda True, b FalseAnswer : False

10. It is very difficult to grant and manage common privileges needed by different groups of database usersusing the roles

Page 12: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

a True, b FalseAnswer : False

11. What is difference between a DIALOG WINDOW and a DOCUMENT WINDOW regardingmoving the window with respect to the application windowa Both windows behave the same way as far as moving the window is concerned.b A document window can be moved outside the application window while a dialog windowcannot be movedc A dialog window can be moved outside the application window while a document windowcannot be moved

Answer : C

12 . What is the difference between a MESSAGEBOX and an ALERTa. A messagebox can be used only by the system and cannot be used in user application while analert can be used in user application also.b A alert can be used only by the system and cannot be use din user application while an messageboxcan be used in user application also.c An alert requires an response from the user while a messagebox just flashes a messageand only requires an acknowledgment from the userd An message box requires an response from the user while a alert just flashes a message an onlyrequires an acknowledgment from the user

Answer : C

13. Which of the following is not an reason for the fact that most of the processing is done at the server ?

a. To reduce network traffic. b For application sharing, c To implement business rules centrally,d None of the above

Answer : D

14. Can a DIALOG WINDOW have scroll bar attached to it ?

a Yes, b NoAnswer : B

15. Which of the following is not an advantage of GUI systems ?

Page 13: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

a. Intuitive and easy to use., b. GUI’s can display multiple applications in multiple windowsc. GUI’s provide more user interface objects for a developer d. None of the above

Answer

16. What is the difference between a LIST BOX and a COMBO BOX ?

a. In the list box, the user is restricted to selecting a value from a list but in a combo box the user cantype in value which is not in the listb A list box is a data entry area while a combo box can be used only for control purposesc In a combo box, the user is restricted to selecting a value from a list but in a list box theuser can type in a value which is not in the listd None of the above

Answer : A

17. In a CLIENT/SERVER environment , which of the following would not be done at the client ?

a User interface part, b Data validation at entry line,c Responding to user events,d None of the above

Answer : D

18. Why is it better to use an INTEGRITY CONSTRAINT to validate data in a table than to use a STOREDPROCEDURE ?

a. Because an integrity constraint is automatically checked while data is inserted into or updated in a tablewhile a stored procedure has to be specifically invokedb Because the stored procedure occupies more space in the database than a integrity constraint definitionc Because a stored procedure creates more network traffic than a integrity constraint definition

Answer : A

19. Which of the following is not an advantage of a client/server model ?

a. A client/server model allows centralized control of data and centralized implementation of business rules.b A client/server model increases developers productivity

Page 14: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

c A client/server model is suitable for all applicationsd None of the above.

Answer : C

20. What does DLL stands for ?

a Dynamic Language Libraryb Dynamic Link Libraryc Dynamic Load Libraryd None of the above

Answer : B

21. POST-BLOCK trigger is aa Navigational triggerb Key triggerc Transactional triggerd None of the above

Answer : A

22. The system variable that records the select statement that SQL * FORMS most recently usedto populate a block isa SYSTEM.LAST_RECORDb SYSTEM.CURSOR_RECORDc SYSTEM.CURSOR_FIELDd SYSTEM.LAST_QUERY

Answer : D

23. Which of the following is TRUE for the ENFORCE KEY fielda ENFORCE KEY field characteristic indicates the source of the value that SQL*FORMS usesto populate the fieldb A field with the ENFORCE KEY characteristic should have the INPUT ALLOWEDcharacteristic turned offa Only 1 is TRUEb Only 2 is TRUEc Both 1 and 2 are TRUEd Both 1 and 2 are FALSE

Answer : A

24. What is the maximum size of the page ?

Page 15: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

a Characters wide & 265 characters lengthb Characters wide & 265 characters lengthc Characters wide & 80 characters lengthd None of the above

Answer : B

25. A FORM is madeup of which of the following objectsa block, fields only,b blocks, fields, pages only,c blocks, fields, pages, triggers and form level procedures,d Only blocks.

Answer : C

26. For the following statements which is true1 Page is an object owned by a form2 Pages are a collection of display information such as constant text and graphics.a Only 1 is TRUEb Only 2 is TRUEc Both 1 & 2 are TRUEd Both are FALSE

Answer : B

27. The packaged procedure that makes data in form permanent in the Database isa Postb Post formc Commit formd None of the above

Answer : C

28. Which of the following is TRUE for the SYSTEM VARIABLE $$date$$a Can be assigned to a global variableb Can be assigned to any field only during design timec Can be assigned to any variable or field during run timed None of the above

Answer : B

9. Which of the following packaged procedure is UNRESTRICTED ?

a CALL_INPUT, b CLEAR_BLOCK, c EXECUTE_QUERY, d USER_EXIT

Answer : D

Page 16: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

30. Identify the RESTRICTED packaged procedure from the followinga USER_EXIT, b MESSAGE, c BREAK, d EXIT_FORM

Answer : D

31. What is SQL*FORMSa SQL*FORMS is a 4GL tool for developing & executing Oracle based interactive applications.b SQL*FORMS is a 3GL tool for connecting to the Database.c SQL*FORMS is a reporting toold None of the above.

Answer : A

32. Name the two files that are created when you generate a form using Forms 3.0a FMB & FMX, b FMR & FDX, c INP & FRM, d None of the above

Answer : C

33. What is a triggera. A piece of logic written in PL/SQLb Executed at the arrival of a SQL*FORMS eventc Both A & Bd None of the above

Answer : C

34. Which of the following is TRUE for a ERASE packaged procedure1 ERASE removes an indicated Global variable & releases the memory associated with it2 ERASE is used to remove a field from a page1 Only 1 is TRUE2 Only 2 is TRUE3 Both 1 & 2 are TRUE4 Both 1 & 2 are FALSE

Answer : 1

35. All datafiles related to a Tablespace are removed when the Tablespace is droppeda TRUEb FALSE

Answer : B

36. Size of Tablespace can be increased bya Increasing the size of one of the Datafilesb Adding one or more Datafiles

Page 17: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

c Cannot be increasedd None of the above

Answer : B

37 . Multiple Tablespaces can share a single datafilea TRUEb FALSE

Answer : B

38 . A set of Dictionary tables are createda Once for the Entire Databaseb Every time a user is createdc Every time a Tablespace is createdd None of the above

Answer : A

39. Datadictionary can span across multiple Tablespacesa TRUEb FALSE

Answer : B

40. What is a DATABLOCKa Set of Extentsb Set of Segmentsc Smallest Database storage unitd None of the above

Answer : C

41. Can an Integrity Constraint be enforced on a table if some existing table data does not satisfy the constrainta Yesb No

Answer : B

42. A column defined as PRIMARY KEY can have NULL’sa TRUEb FALSE

Answer : B

Page 18: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

43. A Transaction endsa Only when it is Committedb Only when it is Rolledbackc When it is Committed or Rolledbackd None of the above

Answer : C

44. A Database Procedure is stored in the Databasea. In compiled formb. As source codec. Both A & Bd. Not stored

Answer : C

45. A database trigger does not apply to data loaded before the definition of the triggera TRUEb FALSE

Answer : A

46. Dedicated server configuration isa One server process - Many user processesb Many server processes - One user processc One server process - One user processd Many server processes - Many user processes

Answer : C

47. Which of the following does not affect the size of the SGAa Database bufferb Redolog bufferc Stored procedured Shared pool

Answer : C

48. What does a COMMIT statement do to a CURSORa Open the Cursorb Fetch the Cursorc Close the Cursord None of the above

Answer : D

Page 19: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

49. Which of the following is TRUE1 Host variables are declared anywhere in the program2 Host variables are declared in the DECLARE sectiona Only 1 is TRUEb Only 2 is TRUEc Both 1 & 2are TRUEd Both are FALSE

Answer : B

50. Which of the following is NOT VALID is PL/SQLa Bool boolean;b NUM1, NUM2 number;c deptname dept.dname%type;d date1 date := sysdate

Answer : B

51. Declarefvar number := null; svar number := 5Begingoto >if fvar is null then>svar := svar + 5end if;End;

What will be the value of svar after the execution ?

a Errorb 10c 5d None of the above

Answer : A

52. Which of the following is not correct about an Exception ?

a Raised automatically / Explicitly in response to an ORACLE_ERRORb An exception will be raised when an error occurs in that blockc Process terminates after completion of error sequence.d A Procedure or Sequence of statements may be processed.

Answer : C

Page 20: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

53. Which of the following is not correct about User_Defined Exceptions ?

a Must be declaredb Must be raised explicitlyc Raised automatically in response to an Oracle errord None of the above

Answer : C

54. A Stored Procedure is aa Sequence of SQL or PL/SQL statements to perform specific functionb Stored in compiled form in the databasec Can be called from all client environmetsd All of the above

Answer : D

55. Which of the following statement is falsea Any procedure can raise an error and return an user message and error numberb Error number ranging from 20000 to 20999 are reserved for user defined messagesc Oracle checks Uniqueness of User defined errorsd Raise_Application_error is used for raising an user defined error.

Answer : C

56. Is it possible to open a cursor which is in a Package in another procedure ?

a Yesb No

Answer : A

57. Is it possible to use Transactional control statements in Database Triggers?

a Yesb No

Answer : B

58. Is it possible to Enable or Disable a Database trigger ?

a Yesb No

Answer : A

Page 21: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

59. PL/SQL supports datatype(s)a Scalar datatypeb Composite datatypec All of the aboved None of the aboveAnswer C

60. Find the ODD datatype outa VARCHAR2b RECORDc BOOLEANd RAW

Answer : B

61. Which of the following is not correct about the “TABLE” datatype ?

a Can contain any no of columnsb Simulates a One-dimensional array of unlimited sizec Column datatype of any Scalar typed None of the above

Answer : A

62. Find the ODD one out of the followinga OPENb CLOSEc INSERTd FETCHAnswer C

63. Which of the following is not correct about Cursor ?

a Cursor is a named Private SQL areab Cursor holds temporary resultsc Cursor is used for retrieving multiple rowsd SQL uses implicit Cursors to retrieve rows

Answer : B

64. Which of the following is NOT VALID in PL/SQL ?

a Select … intob Updatec Created Delete

Page 22: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Answer : C

65. What is the Result of the following ‘VIK’||NULL||’RAM’ ?

a Errorb VIK RAMc VIKRAMd NULL

Answer : C

66. Declarea number := 5; b number := null; c number := 10;Beginif a > b AND a ( Select count(*) from Emp E2 where E1.SAL > E2.SAL ) will retrievea 3500,5000,2500b 5000,2850c 2850,5750d 5000,5750

Answer : A

72. Is it possible to modify a Datatype of a column when column contains data ?

a Yesb NoAnswer B

73. Which of the following is not correct about a View ?

a. To protect some of the columns of a table from other usersb Occupies data storage spacec To hide complexity of a queryd To hide complexity of a calculations

Answer : B

74. Which is not part of the Data Definition Language ?

a CREATEb ALTERc ALTER SESSION

Answer : C

Page 23: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

75. The Data Manipulation Language statements area INSERTb UPDATEc SELECTd All of the above

Answer : D

76. EMPNO ENAME SALA822 RAMASWAMY 3500A812 NARAYAN 5000A973 UMESHA500 BALAJI 5750Using the above dataSelect count(sal) from Emp will retrievea 1b 0c 3d None of the above

Answer : C

77. If an UNIQUE KEY constraint on DATE column is created, will it accept the rows that are inserted withSYSDATE ?

a Willb Won’t

Answer : B

78. What are the different events in Triggers ?

a Define, Createb Drop, Commentc Insert, Update, Deleted All of the above

Answer : C

79. What built-in subprogram is used to manipulate images in image items ?

a Zoom_outb Zoom_in’c Image_zoomd Zoom_image

Page 24: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Answer : C

80. Can we pass RECORD GROUP between FORMS ?

a Yesb No

Answer : A

81. SHOW_ALERT function returnsa Booleanb Numberc Characterd None of the above

Answer : B

82. What SYSTEM VARIABLE is used to refer DATABASE TIME ?

a $$dbtime$$b $$time$$c $$datetime$$d None of the above

Answer : A

83. :SYSTEM.EFFECTIVE.DATE variable isa Read onlyb Read & Writec Write onlyd None of the above

Answer : C

84. How can you CALL Reports from Forms4.0 ?

a Run_Report built_inb Call_Report built_inc Run_Product built_ind Call_Product built_in

Answer : C

85. When do you get a .PLL extension ?

Page 25: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

a Save Library fileb Generate Library filec Run Library filed None of the above

Answer : A

86. What is built_in Subprogram ?

a Stored procedure & Functionb Collection of Subprogramc Collection of Packagesd None of the above

Answer : D

87. GET_BLOCK property is aa Restricted procedureb Unrestricted procedurec Library functiond None of the above

Answer : D

88. A CONTROL BLOCK can sometimes refer to a BASETABLE ?

a TRUEb FALSE

Answer : B

89. What do you mean by CHECK BOX ?

a Two state controlb One state controlc Three state controld none of the above

Answer : C - Please check the Correctness of this Answer ( The correct answers 2 )

90. List of Values (LOV) supportsa Single columnb Multi columnc Single or Multi columnd None of the above

Page 26: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Answer : C

91. What is Library in Forms 4.0 ?

a Collection of External fieldb Collection of built_in packagesc Collection of PL/SQl functions, procedures and packagesd Collection of PL/SQL procedures & triggers

Answer : C

92. Can we use a RESTRICTED packaged procedure in WHEN_TEXT_ITEM trigger ?

a Yesb No

Answer : B

93. Can we use GO_BLOCK package in a PRE_TEXT_ITEM trigger ?

a Yesb No

Answer : B

94. What type of file is used for porting Forms 4.5 applications to various platforms ?

a . FMB fileb . FMX filec . FMT filed . EXE file

Answer : C

95. What built_in procedure is used to get IMAGES in Forms 4.5 ?

a READ_IMAGE_FILEb GET_IMAGE_FILEc READ_FILEd GET_FILEAnswer A

96. When a form is invoked with CALL_FORM does Oracle forms issues SAVEPOINT ?

Page 27: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

a Yesb No

Answer : A

97. Can we attach the same LOV to different fields in Design time ?

a Yesb No

Answer : A

98. How do you pass values from one form to another form ?

a LOVb Parametersc Local variablesd None of the above

Answer : B

99. Can you copy the PROGRAM UNIT into an Object group ?

a Yesb No

Answer : B

100. Can MULTIPLE DOCUMENT INTERFACE (MDI) be used in Forms 4.5 ?

a Yesb No

Answer : A

101. When is a .FMB file extension is created in Forms 4.5 ?

a Generating formb Executing formc Save formd Run form

Answer : C

102. What is a Built_in subprogram ?

Page 28: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

a Libraryb Stored procedure & Functionc Collection of Subprogramsd None of the above

Answer : D

103. What is a RADIO GROUP ?

a Mutually exclusiveb Select more than one columnc Above all TRUEd Above all FALSE

Answer : A

104. Identify the Odd one of the following statements ?

a Poplistb Tlistc List of valuesd Combo box

Answer : C

105. What is an ALERT ?

a Modeless windowb Modal windowc Both are TRUEd None of the above

Answer : B

106. Can an Alert message be changed at runtime ?

a Yesb No

Answer : A

107. Can we create an LOV without an RECORD GROUP ?

a Yesb No

Page 29: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Answer : B

108. How many no of columns can a RECORD GROUP have ?

a 10b 20c 50d None of the aboveAnswer D

109. Oracle precompiler translates the EMBEDDED SQL statements intoa Oracle FORMSb Oracle REPORTSc Oracle LIBRARYd None of the above

Answer : D

110. Kind of COMMENT statements placed within SQL statements ?

a Asterisk(*) in column ?

b ANSI SQL style statements(…)c C-Style comments (/*……*/)d All the above

Answer : D

111. What is the appropriate destination type to send the output to aprinter ?

a Screenb Previewerc Either of the aboved None of the above

Answer : D

112. What is TERM ?

a TERM is the terminal definition file that describes the terminal from which you are using R20RUN( Reports run time )b TERM is the terminal definition file that describes the terminal from which you are using R20DES( Reports designer )

Page 30: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

c There is no Parameter called TERM in Reports 2.0d None of the above

Answer : A

113. If the maximum records retrieved property of a query is set to 10, then a summary value willbe calculateda Only for 10 recordsb For all the records retrievedc For all the records in the referenced tabled None of the above

Answer : A

114. With which function of a summary item in the COMPUTE AT optio required ?

a Sumb Standard deviationc Varianced % of Total function

Answer : D

115. For a field in a repeating frame, can the source come from a column which does not exist inthe datagroup which forms the base of the frame ?

a Yesb No

Answer : A

116. What are the different file extensions that are created by Oracle Reports ?

a . RDF file & .RPX fileb . RDX file & .RDF filec . REP file & .RDF filed None of the above

Answer : C

117. Is it possible to Disable the Parameter form while running the report?

a Yesb No

Page 31: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Answer : A

118.What are the SQL clauses supported in the link property sheet ?

a. WHERE & START WITHb WHERE & HAVINGc START WITH & HAVINGd WHERE, START WITH & HAVING

Answer : D

119. What are the types of Calculated columns available ?

a Summary, Place holder & Procedure columnb Summary, Procedure & Formula columnsc Procedure, Formula & Place holder columnsd Summary, Formula & Place holder columnsAns.: D

120. If two groups are not linked in the data model editor, what is the hierarchy between them?

a. There is no hierarchy between unlinked groupsb The group that is right ranks higher than the group that is to the leftc The group that is above or leftmost ranks higher than the group that is to right or below itd None of the above

Answer : C

121. Sequence of events takes place while starting a Database isa Database opened, File mounted, Instance startedb Instance started, Database mounted & Database openedc Database opened, Instance started & file mountedd Files mounted, Instance started & Database opened

Answer : B

122. SYSTEM TABLESPACE can be made off-linea Yesb No

Answer : B

123. ENQUEUE_RESOURCES parameter information is derived froma PROCESS or DDL_LOCKS & DML_LOCKS

Page 32: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

b LOG BUFFERc DB_BLOCK_SIZEd DB_BLOCK_BUFFERS

Answer : A

124. SMON process is used to write into LOG filesa TRUEb FALSE

Answer : B

125. EXP command is useda To take Backup of the Oracle Databaseb To import data from the exported dump filec To create Rollback segmentsd None of the above

Answer : A

126. SNAPSHOTS cannot be refreshed automaticallya TRUEb FALSE

Answer : B

127. The User can set Archive file name formats

a TRUEb FALSE

Answer : A

128. The following parameters are optional in init.ora parameter file DB_BLOCK_SIZE, PROCESS

a TRUEb FALSE

Answer : B129. NOARCHIEVELOG parameter is used to enable the database in Archive modea TRUEb FALSE

Answer : B

Page 33: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

130. Constraints cannot be exported through Export command?

a TRUEb FALSE

Answer : B

131. It is very difficult to grant and manage common privileges needed bydifferent groups of database users using rolesa TRUEb FALSE

Answer : B

132. The status of the Rollback segment can be viewed througha DBA_SEGMENTSb DBA_ROLESc DBA_FREE_SPACESd DBA_ROLLBACK_SEG

Answer : D

133. Explicitly we can assign transaction to a rollback segmenta TRUEb FALSE

Answer : A

134. What file is read by ODBC to load drivers ?

a ODBC.INIb ODBC.DLLc ODBCDRV.INId None of the above

Answer : A

السادسة المجموعة

Tell us about yourself, your background.What are the three major characteristics that you bring to thiscompany?What version of Oracle were you running?

Page 34: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

How many databases did the organization have and what sizes?What motivates you to do a good job?What two or three things are most important to you at work?What qualities do you think are essential to be successful in thiskind of work?What courses did you attend? What job certifications do you hold?What subjects/courses did you excel in? Why?What subjects/courses gave you trouble? Why?How does your previous work experience prepare you for thisposition?How do you define success?What has been your most significant accomplishment to date?Describe a challenge you encountered and how you dealt with it.Describe a failure and how you dealt with it.Describe the ideal job the ideal supervisor.What leadership roles have you held?What prejudices do you hold?What do you like to do in your spare time?What are your career goals (a) 3 years from now; (b) 10 years fromnow?

السابعة المجموعة

Different Oracle And Database Questions

1. WHAT IS DATA OR INFORMATION?Answer: The Matter that we feed into the Computer is called Data orInformation.2. WHAT IS DATABASE?Answer: The Collection of Interrelated Data is called Data Base.3. WHAT IS A DATABASE MANAGEMENT SYSTEM (DBMS) PACKAGE?Answer: The Collection of Interrelated Data and some Programs to accessthe Data is Called Data Base ManagementSystem (DBMS).4. WHEN CAN WE SAY A DBMS PACKAGE AS RDBMS?Answer: For a system to Qualify as RELATIONAL DATABASE MANAGEMENT system,it must use itsRELATIONAL facilities to MANAGE the DATABASE.5. WHAT IS ORDBMS?Answer: Object (oriented) Relational Data Base Management System is onethat can store data, the relationship of thedata, and the behavior of the data (i.e., the way it interacts withother data).

Page 35: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

6. NAME SOME CODD’S RULES.Answer: Dr. E.F. Codd presented 12 rules that a database must obey if itis to be considered truly relational. Out those,some are as followsa) The rules stem from a single rule- the ‘zero rule’: For a system toQualify as RELATIONALDATABASE MANAGEMENT system, it must use its RELATIONAL facilitiesto MANAGE the DATABASE.b) Information Rule: Tabular Representation of Information.c) Guaranteed Access Rule: Uniqueness of tuples for guaranteedaccessibility.d) Missing Information Rule: Systematic representation of missinginformation as NULL values.e) Comprehensive Data Sub-Language Rule: QL to support Data definition,View definition,Data manipulation, Integrity, Authorization andSecurity.7. WHAT ARE HIERARCHICAL, NETWORK, AND RELATIONAL DATABASE MODELS?Answer: a) Hierarchical Model: The Hierarchical Model was introduced inthe Information Management System (IMS)developed by IBM in 1968. In this data is organized as a treestructure. Each tree is made of nodes and branches.The nodes of the tree represent the record types and it is a collectionof data attributes entity at that point. Thetopmost node in the structure is called the root. Nodes succeedinglower levels are called children.b) Network Model: The Network Model, also called as the CODSYL databasestructure, is an improvement over theHierarchical mode, in this model concept of parent and child isexpanded to have multiple parent-childrelationships, i.e. any child can be subordinate to many differentparents (or nodes). Data is represented bycollection of records, and relationships among data are represented bylinks. A link is an association betweenprecisely two records. Many-to-many relationships can exists betweenthe parent and child.c) Relational Model: The Relational Database Model eliminates the needfor explicit parent-child relationships.In RDBMS, data is organized in two-dimensional tables consisting ofrelational, i.e. no pointers are maintainedbetween tables.8. WHAT IS DATA MODELING?Answer: Data Modeling describes relationship between the data objects. Therelationships between the collections ofdata in a system may be graphically represented using data modeling.

Page 36: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

9. DEFINE ENTITY, ATTRIBUTE AND RELATIONSHIP.Answer: Entity: An Entity is a thing, which can be easily identified. Anentity is any object, place, person, concept oractivity about which an enterprise records data.Attribute: An attribute is the property of a given entity.Relationship: Relationship is an association among entities.10. WHAT IS ER-MODELING?Answer: The E-R modeling technique is the Top Down Approach. Entityrelationship is technique for analysis andlogical modeling of a system’s data requirements. It is the most widelyused and has gained acceptance as theideal database design. It uses three basic units: entities, theirattributes and the relationship that exists betweenthe entities. It uses a graphical notation for representing these.11. WHAT IS NORMALIZATION?Answer: Normalization is a step-by-step decomposition of complex recordsinto simple records.12. WHAT ARE VARIOUS NORMAL FORMS OF DATA?Answer: The First Normal Form 1NF,The Second Normal Form 2NF,The Third Normal Form 3NF,The Boyce and Codd Normal Form BC NF.13. WHAT IS DENORMALIZATION?Answer: The intentional introduction of redundancy to a table to improveperformance is calledDENORMALIZATION.14. WHAT ARE 1-TIER, 2-TIER, 3-TIER OR N-TIER DATABASE ARCHITECTURES?Answer: 1-Tier Database Architecture is based on single system, which actsas both server and client.2-Tier Architecture is based on one server and client.3-Tier Architecture is based on one server and client out that onclient act as a remote system.N-Tier Architecture is based on N no. Of servers and N no. Of clients.15. WHAT ARE A TABLE, COLUMN, AND RECORD?Answer: Table: A Table is a database object that holds your data. It ismade up of many columns. Each of thesecolumns has a data type associated with it.Column: A column, referred to as an attribute, is similar to a field inthe file system.Record: A row, usually referred to as tuple, is similar to record inthe file system.16. WHAT IS DIFFERENCE BETWEEN A PROCEDURAL LANGUAGE AND ANON-PROCEDURAL LANGUAGE?Answer:Procedural Language NON-Procedural Language

Page 37: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

A program in this implements a step-by-step algorithm to solve theproblem. It contains what to do but not how to do17.WHAT TYPE OF LANGUAGE “SQL” IS?Answer: SQL is a Non-procedural, 4th generation Language,/ which concertswhat to do rather than how to do anyprocess.18. CLASSIFICATION OF SQL COMMANDS?Answer:DDL (Data Definition Language) DML (Data Manipulating Language) DCL(Data ControlLanguage) DTL(Data Transaction Language)Create Alter Drop Select Insert Update Delete Rollback Commit GrantRevoke

19. WHAT IS DIFFERENCE BETWEEN DDL AND DML COMMANDS?Answer: For DDL commands auto commit is ON implicitly whereas For DMLcommands auto commit is to be turnedON explicitly.20. WHAT IS DIFFERENCE BETWEEN A TRANSACTION AND A QUERY?Answer: A Transaction is unit of some commands where as Query is a singleline request for the information from thedatabase.21. WHAT IS DIFFERENCE BETWEEN TRUNCATE AND DELETE COMMANDS?Answer: Truncate Command will delete all the records where as DeleteCommand will delete specified or all therecords depending only on the condition given.22. WHAT IS DIFFERENCE BETWEEN UPDATE AND ALTER COMMANDS?Answer: Alter command is used to modify the database objects where as theUpdate command is used to modify thevalues of a data base objects.23. WHAT ARE COMMANDS OF TCL CATEGORY?Answer: Grant and Revoke are the two commands belong to the TCL Category.

24. WHICH IS AN EFFICIENT COMMAND - TRUNCATE OR DELETE? WHY?Answer: Delete is the efficient command because using this command we candelete only those records that are notreally required.25. WHAT ARE RULES FOR NAMING A TABLE OR COLUMN?Answer: 1) Names must be from 1 to 30 bytes long.2) Names cannot contain quotation marks.3) Names are not case sensitive.4) A name must begin with an alphabetic character from your databasecharacter set and the characters $ and #.But these characters are discouraged.5) A name cannot be ORACLE reserved word.6) A name must be unique across its namespace. Objects in the name

Page 38: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

space must have different names.7) A name can be enclosed in double quotes.26. HOW MANY COLUMNS CAN A TABLE HAVE?Answer: A Table can have 1000 columns.27. WHAT ARE DIFFERENT DATATYPES SUPPORTED BY SQL?Answer: Char (size), Nchar (size), Varchar2 (size), Nvarchar2 (size) datatypes for character values,Number (precision, scale), Number, Number (n), Float, Float (binaryprecision) data types for numerical values,Date data type for date values,Long, Raw (size), Long Raw, Clob, Blob, Nclob, Bfile for large objects.28. WHAT IS DIFFERENCE BETWEEN LONG AND LOB DATATYPES?Answer:LOB LONG1) The maximum size is 4GB.2) LOBs (except NCLOB) can be attributes of an object type.3) LOBs support random access to data.4) Multiple LOB columns per table or LOB attributes in an object type.1) The maximum size is 2GB. 2) LONGs cannot. 3) LONGs support onlysequential access.4) Only one LONG column was allowed in a table29. WHAT IS DIFFERENCE BETWEEN CHAR AND VARCHAR2 DATATYPES?Answer: Varchar2 is similar to Char but can store variable no. Ofcharacters and while querying the table varchar2trims the extra spaces from the column and fetches the rows thatexactly match the criteria.30. HOW MUCH MEMORY IS ALLOCATED FOR DATE DATATYPE? WHAT IS DEFAULTDATEFORMAT IN ORACLE?Answer: For Date data type oracle allocates 7 bytes Memory.Default Date Format is: DD-MON-YY.31. WHAT IS RANGE FOR EACH DATATYPE OF SQL?Answer:Datatype RangeChar Varchar2 Number Float LONG, RAW, LONGRAW Large Objects(LOB’s) 2000 bytes 4000 bytesPrecision 1 to 38 Scale -84 to 127 Precision 38 decimals Or 122 binaryprecision 2 GB 4GB32. HOW TO RENAME A COLUMN?Answer: We can’t rename a Column of a table directly. So we follow thefollowing steps.To Rename a Column:a) Alter the table specifying new column name to be given and datatype.b) Then copy the values in the column to be renamed into new column.

Page 39: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

c) drop the old column.33. HOW TO DECREASE SIZE OR CHANGE DATATYPE OF A COLUMN?Answer: To Decrease the size of a Data type of a columni. Truncate the table first.ii. Alter the table column whose size is to be decreased using the samename and data type but new size.34. WHAT IS A CONSTRAINT? WHAT ARE ITS VARIOUS LEVELS?Answer: Constraint: Constraints are representators of the column toenforce data entity and consistency.There r twolevels1)Column-level constraints 2)Table-level constraints.

35. LIST OUT ALL THE CONSTRAINTS SUPPORTED BY SQL.Answer: Not Null, Unique, Check, Primary Key and Foreign Key orReferential Integrity.36. WHAT IS DIFFERENCE BETWEEN UNIQUE+NOT NULL AND PRIMARY KEY?Answer: Unique and Not Null is a combination of two Constraints that canbe present any number of times in a tableand can’t be a referential key to any column of an another table whereas Primary Key is single Constraint thatcan be only once for table and can be a referential key to a column ofanother table becoming a referential integrity.37. WHAT IS A COMPOSITE PRIMARY KEY?Answer: A Primary key created on combination of columns is calledComposite Primary Key.38. WHAT IS A CANDIDATE COLUMN? HOW MANY CANDIDATE COLUMNS CAN BEPOSSIBLEPER COMPOSITE PRIMARY KEY?Answer:

39. HOW TO DEFINE A NULL VALUE?Answer: A NULL value is something which is unavailable, it is neither zeronor a space and any mathematicalcalculation with NULL is always NULL.40. WHAT IS NULL? A CONSTRAINT OR DEFAULT VALUE?Answer: It is a default value.41. WHAT IS DEFAULT VALUE FOR EVERY COLUMN OF A TABLE?Answer: NULL.42. WHAT IS CREATED IMPLICITLY FOR EVERY UNIQUE AND PRIMARY KEYCOLUMNS?Answer: Index.43. WHAT ARE LIMITATIONS OF CHECK CONSTRAINT?Answer: In this we can’t specify Pseudo Columns like sysdate etc.44. WHAT IS DIFFERENCE BETWEEN REFERENCES AND FOREIGN KEY

Page 40: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

CONSTRAINT?Answer: References is used as column level key word where as foreign keyis used as table level constraint.45. WHAT IS “ON DELETE CASCADE”?Answer: when this key word is included in the definition of a child tablethen whenever the records from the parenttable is deleted automatically the respective values in the child tablewill be deleted.46. WHAT IS PARENT-CHILD OR MASTER-DETAIL RELATIONSHIP?Answer: A table which references a column of another table(usingReferences)is called as a child table(detail table) and a table whichis being referred is called Parent (Master)Table .47. HOW TO DROP A PARENT TABLE WHEN IT’S CHILD TABLE EXISTS?Answer: Using “on delete cascade”.48. IS ORACLE CASE SENSITIVE?Answer: NO49. HOW ORACLE IDENTIFIES EACH RECORD OF TABLE UNIQUELY?Answer: By Creating indexes and reference IDs.50. WHAT IS A PSEUDO-COLUMN? NAME SOME PSEUDO-COLUMNS OF ORACLE?Answer: Columns that are not created explicitly by the user and can beused explicitly in queries are calledPseudo-Columns.Ex:currval, nextval, sysdate….51. WHAT FOR “ORDER BY” CLAUSE FOR A QUERY?Answer: To arrange the query result in a specifiedorder(ascending, descending) by default it takes ascending order.52. WHAT IS “GROUP BY” QUERIES?Answer: To group the query results based on condition.53. NAME SOME AGGREGATE FUNCTIONS OF SQL?Answer: AVG, MAX, SUM, MIN,COUNT.54. WHAT IS DIFFERENCE BETWEEN COUNT (), COUNT (*) FUNCTIONS?Answer: Count () will count the specified column whereas count (*) willcount total no. of rows in a table.55. WHAT FOR ROLLUP AND CUBE OPERATORS ARE?Answer: To get subtotals and grand total of values of a column.56. WHAT IS A SUB-QUERY?Answer: A query within a query is called a sub query where the result ofinner query will be used by the outer query.57. WHAT ARE SQL OPERATORS?Answer: Value (), Ref () is SQL operator.58. EXPLAIN “ANY”,”SOME”,”ALL”,”EXISTS” OPERATORS?Answer: Any: The Any (or it’s synonym SOME) operator computes the lowestvalue from the set and compares avalue to each returned by a sub query.

Page 41: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

All: ALL compares a value to every value returned by SQL.Exists: This operator produces a BOOLWAN results. If a sub queryproduces any result then it evaluates it toTRUE else it evaluates it to FALSE.59. WHAT IS A CORRELATED SUB QUERY, HOW IT IS DIFFERENT FROM A NORMALSUB QUERY?Answer: A correlated subquery is a nested subquery, which is executed oncefor each ‘Candidate row’ by the mainquery, which on execution uses a value from a column in the outerquery. In normal sub query the result of innerquery is dynamically substituted in the condition of the outer querywhere as in a correlated subquery, the columnvalue used in inner query refers to the column value present in theouter query forming a correlated subquery.60. WHAT IS A JOIN - TYPES OF JOINS?Answer: A join is used to combine two or more tables logically to getquery results.There are four types of Joins namelyEQUI JoinNON-EQUI JoinSELF JoinOUTER Join.61. WHAT ARE MINIMUM REQUIREMENTS FOR AN EQUI-JOIN?Answer: There should be at least one common column between the joiningtables.62. WHAT IS DIFFERENCE BETWEEN LEFT, RIGHT OUTER JOIN?Answer: If there r any values in one table that do not have correspondingvalues in the other, in an equip join that rowwill not be selected. Such rows can be forcefully selected by usingouter join symbol(+) on either of the sides(leftor right) based on the requirement.63. WHAT IS DIFFERENCE BETWEEN EQUI AND SELF JOINS?Answer: SELF JOIN is made within the table whereasEQUI JOIN is made between different tables having common column.64. WHAT ARE “SET” OPERATORS?Answer: UNION, INTERSECT or MINUS is called SET OPERATORS.65. WHAT IS DIFFERENCE BETWEEN “UNION” AND “UNION ALL”OPERATORS?Answer: UNION will return the values distinctly whereas UNION ALL willreturn even duplicate values.66. NAME SOME NUMBER, CHARACTER, DATE, CONVERSION, OTHERFUNCTIONS.Answer: Number Functions:Round (m, [n]),Trunc (m, [n]),

Page 42: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Power (m, n),Sqrt,Abs (m),Ceil (m),Floor (m),Mod (m, n)Character Functions:Chr (x)Concert (string1, string2)Lower (string)Upper (string)Substr (string, from_str, to_str)ASCII (string)Length (string)Initcap (string).Date Functions:sysdateMonths between (d1, d2)To_char (d, format)Last day (d)Next_day (d, day).Conversion Functions:To_charTo_dateTo_number67. WHAT IS DIFFERENCE BETWEEN MAX () AND GREATEST () FUNCTIONS?Answer: MAX is an aggregate function which takes only one column name of atable as parameter whereas Greatest isa general function which can take any number of values and columnnames from dual and table respectively.68. WHAT FOR NVL () FUNCTION IS?Answer: NVL Function helps in substituting a value in place of a NULL.69. WHAT FOR DECODE () FUNCTION IS?Answer: It is substitutes value basis and it actually does an‘if-then-else’ test.70. WHAT IS DIFFERENCE BETWEEN TRANSLATE () AND REPLACE ()FUNCTIONS?Answer: Translate() is a superset of functionality provided byReplace().71. WHAT IS DIFFERENCE BETWEEN SUBSTR () AND INSTR () FUNCTIONS?Answer: Substr() will return the specified part of a string whereasInstr() return the position of the specified part of the string.72. WHAT IS A JULIAN DAY NUMBER?Answer: It will return count of the no. Of days between January 1, 4712 BCand the given date.73. HOW TO DISPLAY TIME FROM A DATE DATA?

Page 43: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Answer: By using time format as ‘hh [hh24]: mi: ss’ in to_char() function.74. HOW TO INSERT DATE AND TIME INTO A DATE COLUMN?Answer: By using format ‘dd-mon-yy hh [hh24]: mi: ss’ in to_date()function.75. WHAT IS DIFFERENCE BETWEEN TO_DATE () AND TO_CHAR () CONVERSIONFUNCTIONS?Answer: To_date converts character date to date format whereasTo_char function converts date or numerical values to characters.76. WHAT IS A VIEW? HOW IT IS DIFFERENT FROM A TABLE?Answer: View is database object, which exists logically but contains nophysical data and manipulates the base table.View is saved as a select statement in the database and contains nophysical data whereas Table exists physically.77. WHAT IS DIFFERENCE BETWEEN SIMPLE AND COMPLEX VIEWS?Answer: Simple views can be modified whereas Complex views(created basedon more than one table) cannot bemodified.78. WHAT IS AN INLINE VIEW?Answer: Inline view is basically a subquery with an alias that u can uselike a view inside a SQL statement. It is not aschema object like SQL-object.79. HOW TO UPDATE A COMPLEX VIEW?Answer: Using ‘INSTEAD OF’ TRIGGERS Complex views can be Updated.80. WHAT FOR “WITH CHECK OPTION” FOR A VIEW?Answer: “WITH CHECK OPTION” clause specifies that inserts and updates rperformed through the view r notallowed to create rows which the view cannot select and thereforeallows integrity constraints and data validationchecks to be enforced on data being inserted or updated.81. WHAT IS AN INDEX? ADVANTAGE OF AN INDEXAnswer: An Index is a database object used n Oracle to provide quickaccess to rows in a table. An Index increases theperformance of the database.82. WHAT IS A SEQUENCE? PSEUDO-COLUMNS ASSOCIATED WITH SEQUENCE?Answer: Sequence is a Database Object used to generate unique integersto use as primary keys. Nextval, Currval are the Pseudo Columnsassociated with the sequence.**83. WHAT IS A CLUSTER? WHEN TO USE A CLUSTER? HOW TO DROP A CLUSTERWHENCLUSTERED TABLE EXISTS?Answer: Cluster and Indexes are transparent to the user. Clustering is amethod of storing tables that are intimatelyrelated and are often joined together into the same area on the disk.

Page 44: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

When cluster table exists then to dropcluster we have to drop the table first then only cluster is to bedropped.84. WHAT IS A SNAPSHOT OR MATERIALIZED VIEW?Answer: Materialized views can be used to replicate data. Earlier the datawas replicated through CREATESNAPSHOT command. Now CREATE MATERIALIZED VIEW can be used as synonymfor CREATESNAPSHOT. Query performance is improved using the materialized view asthese views pre calculate expensivejoins and aggregate operations on the table.85. WHAT IS A SYNONYM?Answer: A Synonym is a database object that allows you to createalternate names for Oracle tables and views. It is analias for a table, view, snapshot, sequence, procedure, function orpackage.86. WHAT IS DIFFERENCE BETWEEN PRIVATE AND PUBLIC SYNONYM?Answer: Only the user or table owner can reference Private synonym whereasany user can reference the Publicsynonym.87. WHAT IS DIFFERENCE BETWEEN “SQL” AND “SQL*PLUS” COMMANDS?Answer: SQL commands are stored in the buffer whereas SQL*PLUS are not.**88. NAME SOME SQL*PLUS COMMANDS?Answer: DESC [CRIBE], START, GET, SAVE, / are SQL*PLUS COMMANDS.89. WHAT ARE “SQL*PLUS REPORTING” COMMANDS?Answer: SPOOL file-name, SPOOL OUT, TTITLE, BTITLE, BREAK ON, COMPUTEOF [break] ON etc are SQL*PLUS REPORTINGCOMMANDS.90. WHAT ARE SYSTEM AND OBJECT PRIVILEGES?Answer: Connect and Resource etc are System Privileges.Create , Select, Insert, Alter etc are Object Privileges.

91. WHAT FOR DCL COMMANDS ARE?Answer: Commit, Rollback are DCL commands.92. WHAT FOR GRANT COMMAND WITH “WITH GRANT OPTION”?Answer: “With Grant Option” with Grant Command gives privileges to theuser to grant privileges to other user(s)among the privileges he/she has.93. HOW TO CHANGE PASSWORD OF A USER?Answer: Using Password command orUsing ALTER USER IDENTIFIED BY COMAND.94. WHAT IS A SCHEMA AND SCHEMA OBJECTS?Answer: A schema is a collection of logical structures of data, or schemaobjects. A schema is owned by the databaseuser and has the same name as that of user. Each user owns a single

Page 45: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

schema. Schema objects include followingtype of objects Clusters, Database Links, Functions, Indexes, Packages,Procedures, Sequences, Synonyms, Tables,Database Triggers, Views.**95. HOW TO STARTUP AND SHUTDOWN ORACLE DATABASE?Answer: Startup and Shutdown Oracle database can be done by only theadministrator. Startup is done by usingSTARTUP command and Shutdown is done by SHUTDOWN command96. WHAT IS A SESSION?Answer: The period between Login and Logoff on schema.97. WHAT IS A CLIENT PROCESS? WHAT IS A SERVER PROCESS?Answer: ref: 172 Q & A.98. HOW TO MAKE EVERY DML OPERATION AS AUTO COMMIT?Answer: By using SET AUTOCOMMIT ON command.99. HOW TO DISPLAY DATA PAGE WISE IN SQL?Answer: By using SET PAUSE ON command.100. HOW TO CHANGE LINE SIZE, PAGE SIZE AND SQL PROMPT?Answer: By using SET LINESIZE , SET PAGESIZE ,SET SQLPROMPT .101. HOW PL/SQL IS DIFFERENT FROM SQL?Answer: SQL is non-procedural language whereas PL/SQL is procedurallanguage that includes features and designof programming language.102. WHAT IS ARCHITECTURE OF PL/SQL?Answer:103. WHAT IS A PL/SQL BLOCK?Answer: DECLARE

BEGIN

EXCEPTION

END;104. WHAT ARE DIFFERENT TYPES OF PL/SQL BLOCKS?Answer: DECLARE BLOCK: In this block all the declarations of the variableused in the program is made. If novariables are used this block will become optional.

BEGIN BLOCK: In this block all the executable statements areplaced.This block is Mandatory.

EXCEPTION BLOCK: In this block all the exceptions are handled.This block is also very optional.

Page 46: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

END: Every begin must be ended with this END; statement.105. WHAT ARE COMPOSITE DATA TYPES?Answer: Records, Tables are two Composite data types.106. WHAT IS SCOPE OF A VARIABLE IN PL/SQL BLOCK?Answer: The visibility and accessibility of a variable within theblock(s) is called scope of a variable.107. WHAT IS A NESTED BLOCK?Answer: A block within a block is called Nested Block.108. WHAT IS A PL/SQL ENGINE?Answer: The PL/SQL engine accepts any valid PL/SQL block as input,executes the procedural part of the statementsand sends the SQL statements to the SQL statement executor in theOracle server.109. WHAT IS DEFAULT VALUE FOR A NUMERIC PL/SQL VARIABLE?Answer: NULL110. WHAT IS DIFFERENCE BETWEEN SIMPLE LOOP AND A FOR LOOP?Answer: Simple requires declaration of variables used in it and exitcondition but For Loop doesn’t require this.111. WHAT IS A CURSOR? STEPS TO USE A CURSOR?Answer: Cursor is Private SQL area in PL/SQL.Declare the Cursor,Open the Cursor,Fetch values from SQL into the local Variables,Close the Cursor.112. HOW MANY TYPES OF CURSORS ARE SUPPORTED BY ORACLE?Answer: There are two types of cursors namely Implicit Cursor, ExplicitCursor.113. WHAT IS A CURSOR FOR LOOP?Answer: Cursor For Loop is shortcut process for Explicit Cursors becausethe Cursor is Open, Rows are fetched oncefor each iteration and the cursor is closed automatically when all therows have been processed.114. WHAT ARE CURSOR ATTRIBUTES?Answer: %Found%NotFound%IsOpen%RowCount are the cursor attributes.115. WHAT IS USE OF CURSOR WITH “FOR UPDATE OF” CLAUSE?Answer: This Clause stop accessing of other users on the particularcolumns used by the cursor until the COMMIT isissued.116. WHAT IS AN EXCEPTION? HOW IT IS DIFFERENT FROM ERROR?Answer: Whenever an error occurs Exception raises.Error is a bug whereas the Exception is a warning or errorcondition.117. NAME SOME BUILT-IN EXCEPTIONS.

Page 47: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Answer: Too_Many_RowsNo_Data_FoundZero_DivideNot_Logged_OnStorage_ErrorValue_Error etc.118. HOW TO CREATE A USER-DEFINED EXCEPTION?Answer: User-Defined Exception is created as follows:DECLAREEXCEPTION;- - - - - - - - - ;- - - - - - - - -;BEGIN- - - - - - - - -;- - - - - - - - -;RAISE ;EXCEPTIONWHEN THEN- - - - - - - - -;- - - - - - - - -;END;119. WHAT IS “OTHERS” EXCEPTION?Answer: It is used to along with one or more exception handlers.This will handle all the errors not already handled in the block.120. WHAT IS SCOPE OF EXCEPTION HANDLING IN NESTED BLOCKS?Answer: Exception scope will be within that block in which exceptionhandler is written.121. WHAT IS A SUB-PROGRAM?Answer: A SUBPROGRAM IS A PL/SQL BLOCK, WHICH WILL BE INVOKED BY TAKINGPARAMATERS.122. WHAT ARE DIFFERENT TYPES OF SUB-PROGRAMS?Answer: THEY R TWO TYPES: 1) PROCEDURE 2) FUNCION.

123. HOW A PROCEDURE IS DIFFERENT FROM A FUNCTION?Answer: Function has return key word and returns a value whereas aProcedure doesn’t return any value.124. WHAT ARE TYPES OF PARAMETERS THAT CAN BE PASSED TO FUNCTION ORPROCEDURE?Answer: IN, IN OUT, OUT.125. WHAT IS “IN OUT” PARAMETER?Answer: A parameter, which gets value into the Procedure or Function andtakes the value out of the Procedure orFunction area, is called IN OUT parameter.126. DOES ORACLE SUPPORTS PROCEDURE OVERLOADING?

Page 48: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Answer: NO.127. WHAT IS A PACKAGE AND PACKAGE BODY?Answer: Package is declarative part of the functions and procedures storedin that package and package body isthe definition part of the functions and procedures of that package.128. WHAT IS ADVANTAGE OF PACKAGE OVER PROCEDURE OR FUNCTION?Answer: Packages provides Functions or Procedures Overloading facility andsecurity to those Functions orProcedures.129. IS IT POSSIBLE TO HAVE A PROCEDURE AND A FUNCTION WITH THE SAMENAME?Answer: NO if it is outside a Package, YES if it is within a Package.130. DOES ORACLE SUPPORTS RECURSIVE FUNCTION CALLS?Answer: YES.131. WHAT IS A TRIGGER? HOW IT IS DIFFERENT FROM A PROCEDURE?Answer: Trigger: A Trigger is a stored PL/SQL program unit associatedwith a specific database table.Procedure: A Procedure is to be explicitly called by the userwhereas Triggers are automatically called implicitlyby Oracle itself whenever event Occurs.132. WHAT IS DIFFERENCE BETWEEN A TRIGGER AND A CONSTRAINT?Answer: Constraints are always TRUE whereas Triggers are NOT always TRUEand Constraints has some limitationswhereas Trigger has no limitations.133. WHAT ARE DIFFERENT EVENTS FOR A TRIGGER AND THEIR SCOPES?Answer: Insert, Update or Delete.134. WHAT IS DIFFERENCE BETWEEN TABLE LEVEL AND ROW LEVEL TRIGGERS?Answer: Table level Triggers execute once for each table based transactionwhereas Row level Triggers will executeonce FOR EACH ROW.** 135. WHAT ARE AUTONOMOUS TRIGGERS?Answer:136. WHAT IS AN “INSTEAD OF” TRIGGER?Answer: These Triggers are used with the Complex Views only to makepossible of Insert, Update and Delete on thoseViews.** 137. HOW MANY TRIGGERS CAN BE CONFIGURED ON A TABLE AND VIEW?Answer:138. WHAT IS “TABLE MUTATING” ERROR? HOW TO SOLVE IT?Answer: ORA-04091: Table name is mutating, trigger/function may not see itCause : A trigger or a user-defined PL/SQL function that is referencedin the statement attempted to query ormodify a table that was in the middle of being modified by the

Page 49: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

statement that fired the trigger.Action : Rewrite the trigger or function so it does not read the table.139. WHEN TO USE “:NEW” AND “:OLD” SPECIFIERS?Answer: The prefix :old is used to refer to values already present in thetable. The prefix :new is a correlation namethat refers to the new value that is inserted / updated.** 140. WHAT IS A CONDITIONAL TRIGGER?Answer:** 141. HOW TO CREATE A USER-DEFINED VARIABLE IN PL/SQL?Answer:142. HOW TO CREATE AN ARRAY VARIABLE IN PL/SQL?Answer: Using CREATE [OR REPLACE] TYPEAS VARRAY (size) OF ELEMENT_TYPE (NOT NULL) Command;**143. HOW TO MAKE A USER-DEFINED DATA TYPE GLOBAL IN PL/SQL?Answer:144. HOW TO CREATE AN OBJECT IN ORACLE?Answer: Using CREATE [OR REPLACE] TYPE AS OBJECT (ATTRIBUTENAME DATA TYPE,..)Command145. WHAT IS A TRANSIENT AND PERSISTENT OBJECT?Answer: The Object created in a table is called Persistent Object.Object created on execution of PL/SQL block is called TransientObject.**146. WHAT IS A COLUMN OBJECT AND TABLE OBJECT?Answer: A Column Object is only a Column of a table.

147. HOW TO GRANT PERMISSION ON AN OBJECT TO OTHER USER?Answer: GRANT ON TO .148. WHAT IS A COLLECTION OF ORACLE?Answer: Varray, Nested Table is a collection of Oracle.149. WHAT IS DIFFERENCE BETWEEN VARRAY AND NESTED TABLE?Answer: Varray has a fixed size.Nested tables can carry any number of values.150. HOW TO MODIFY CONTENTS OF A VARRAY IN ORACLE?Answer: To modify a stored VARRAY it has to selected into aPL/SQL variable and then inserted back into the table.151. WHAT IS USE OF “THE” OPERATOR FOR NESTED TABLE?Answer: THE operator allows nested tables to be manipulated using DML whenit is stored in a Table.152. WHICH PACKAGE IS USED FOR FILE INPUT/OUTPUT IN ORACLE?Answer: UTL_FILE Package is used for File input/output in Oracle.153. NAME SOME METHODS AND PROCEDURES OF FILE I/O PACKAGE?Answer: FOPENFCLOSEFFLUSHIS_OPEN

Page 50: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

GET_LINEPUT_LINEPUTFNEW_LINE

**154. WHAT IS SQLJ? HOW IT IS DIFFERENT FROM JDBC CONNECTIVITY?Answer: SQLJ is basically a Java program containing embedded static SQLstatements that are compatible withJava design philosophy.155. WHAT IS AN ITERATOR? Name some TYPES OF ITERATORS?Answer: SQLJ Iterators are basically record groups generated duringtransaction, which requires manipulation ofmore than one records from one or more tables. There are two typesIterators namely Named Iterator andPositional Iterator.** 156. WHAT ARE DIFFERENT STEPS TO WRITE A DYNAMIC SQL PROGRAM?Answer:Eg: char c_sqlstring[]={“DELETE FROM sailors WHERE rating>5”};EXEC SQL PREPARE readytogo FROM :c_sqlstring;EXEC SQL EXECUTE readytogo;157. WHAT IS TABLE PARTITIONING AND INDEX PARTITIONING?Answer: Oracle8 allows tables and Indexes to be partitioned or broken upinto smaller parts based on range of keyvalues. Partitioning is a “divide and conquer” strategy that improvesadministration and performance in datawarehouse and OLTP systems.158. WHAT IS PARALLEL PROCESSING?Answer:159. WHAT IS PHYSICAL MEMORY STRUCTURE OF ORACLE?Answer: The basic oracle memory structure associated with Oracle includes:Software Code AreasThe System Global Area (SGA)The Database Buffer CacheThe shared PoolThe Program Global Areas (PGA)Stack AreasData AreasSort Areas160. WHAT IS LOGICAL MEMORY STRUCTURE OF ORACLE?DB_STGSTUDENT SYSTEMEMP DEPT EMP_IND ….. ..DATA DATA INDEXAnswer: DatabaseTablespace

Page 51: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

DB ObjectSegmentExtends

161. WHAT IS SGA?Answer: A System Global Area is a group of shared memory allocated byOracle that contains data and controlinformation for one Oracle database instance. IF the multiple users areconcurrently connected to the sameinstance, the data in the instance’s SGA is “shared” among the users.Consequently, the SGA isoften referred to as either the “system Global Area” or the “SharedGlobal Area”.162. WHAT IS PGA?Answer: The Program Global Area is a memory buffer that contains data andcontrol information fora server process. A PGA is created by Oracle when a server process isstarted. The information in a PGAdepends on the configuration of Oracle.163. WHAT IS AN ORACLE INSTANCE?Answer: Every time a database is started, an SGA is allocated and Oraclebackground processes are started.The combination of these processes and memory buffers is called anOracle instance.164. WHAT ARE DIFFERENT ORACLE PROCESSES?Answer: A process is a “thread of control” or a mechanism in an operatingsystem that can be execute a seriesof steps. Some operating systems use terms jobs or task. A processnormally has its own private memory areain which it runs. An Oracle database system has general types ofprocess: User Processes and Oracle Processes.**165. WHAT IS DIFFERENCE BETWEEN PMON AND SMON?Answer: SMON (System Monitor) performs instance recovery at instance ofstartup. In a multiple instance system(one that uses the parallel server), SMON of one instance can alsoperform instance recoveryother instance that have failed whereas The PMON (Process Monitor)performs process recovery whena user process fails.**166. WHAT IS DIFFERENCE BETWEEN DATABASE AND TABLESPACE?Answer:167. WHAT IS JOB OF DATABASE WRITER (DBWR) PROCESS?Answer: The Data Base Writer writes modified blocks from the databasebuffer cache to the data files.168. WHAT IS JOB OF LOG WRITER (LGWR) PROC*SS?Answer: The Log Writer writes redo log files to disk. Redo log data is

Page 52: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

generated in the redo log buffer of the SGA.As transactions commit and log buffer fills, LGWR writes redo entriesinto an online redo log file.169. WHAT IS RECOVERER?Answer: The Recover (RECO) is used to resolve distributed transactionsthat are pending due to network orsystem failure in a distributed database. At timed intervals, the localRECO attempts to concept to remotedatabase and automatically complete the commit or rollback of the localportion of any pending distributedtransactions.170. WHAT IS ARCHIVER?Answer: The Archiver (ARCH) copies the online redo log files to archivalstorage when they are full.ARCH is active only when a database’s redo log is used ARCHILOG mode.

** 171. WHAT IS A STORED QUERY?Answer: VIEW172. WHAT IS USER PROCESS AND SERVER PROCESS?Answer: A User process is created and maintained to execute the softwarecode of an application program (such asPRO * Program) or an ORACLE tool (such as SQL * DBA). The User processalso manages the communicationwith server processes. User processes communication with the serverprocesses through the program interface.Other processes call ORACLE processes. In a dedicated serverconfiguration, a serverProcess handles requests for a single user process. A multithreadserver configuration allows many user processesto share a small number of server processes, minimizing the utilizationof available system resources.**173. WHAT IS A SELF REFERENTIAL INTEGRITY?Answer: Table related to itself .Foreign key of the table links to primarykey of the same table.174. WHAT IS A “RAISE” STATEMENT?Answer: It is used to Raise Exceptions.175. WHAT IS ROWID? HOW IT IS DIFFERENT FROM ROWNUM?Answer: Rowid is the address of the row at where it is stored in thedatabase. Rownum is count of records whereasRowid is identification of the each row.

الثامنة المجموعة

DBA, SQL, PL/SQL, Forms questions:

1. What is Log Switch ?

Page 53: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

The point at which ORACLE ends writing to one online redo log fileand begins writing to another is called a log switch.

2. What is On-line Redo Log?

The On-line Redo Log is a set of two or more on-line redo files thatrecord all committed changes made to the database. Whenever atransaction is committed, the corresponding redo entries temporarilystores in redo log buffers of the SGA are written to an on-line redolog file by the background process LGWR. The on-line redo log filesare used in cyclical fashion.

3. Which parameter specified in the DEFAULT STORAGE clause of CREATETABLESPACE cannot be altered after creating the tablespace?

All the default storage parameters defined for the tablespace can bechanged using the ALTER TABLESPACE command. When objects are createdtheir INITIAL and MINEXTENS values cannot be changed.

4. What are the steps involved in Database Startup ?

Start an instance, Mount the Database and Open the Database.

5. What are the steps involved in Instance Recovery?

Rolling forward to recover data that has not been recorded in datafiles yet has been recorded in the on-line redo log, including thecontents of rollback segments. Rolling back transactions that havebeen explicitly rolled back or have not been committed as indicatedby the rollback segments regenerated in step a. Releasing anyresources (locks) held by transactions in process at the time of thefailure. Resolving any pending distributed transactions undergoing atwo-phase commit at the time of the instance failure.

6. Can Full Backup be performed when the database is open?

No.

7. What are the different modes of mounting a Database with theParallel Server?

Exclusive Mode If the first instance that mounts a database does soin exclusive mode, only that Instance can mount the database.Parallel Mode If the first instance that mounts a database isstarted in parallel mode, other instances that are started inparallel mode can also mount the database.

Page 54: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

What are the advantages of operating a database in ARCHIVELOG modeover operating it in NO ARCHIVELOG mode? Complete database recoveryfrom disk failure is possible only in ARCHIVELOG mode. Onlinedatabase backup is possible only in ARCHIVELOG mode.8. What are the steps involved in Database Shutdown?

Close the Database, Dismount the Database and Shutdown the Instance.

9. What is Archived Redo Log ?

Archived Redo Log consists of Redo Log files that have archivedbefore being reused.

10. What is Restricted Mode of Instance Startup ?

An instance can be started in (or later altered to be in) restrictedmode so that when the database is open connections are limited onlyto those whose user accounts have been granted the RESTRICTEDSESSION system privilege.

11. What is Partial Backup ?

A Partial Backup is any operating system backup short of a fullbackup, taken while the database is open or shut down.

12. What is Mirrored on-line Redo Log ?

A mirrored on-line redo log consists of copies of on-line redo logfiles physically located on separate disks, changes made to onemember of the group are made to all members.

13. What is Full Backup ?

A full backup is an operating system backup of all data files, on-line redo log files and control file that constitute ORACLE databaseand the parameter.

14. Can a View based on another View ?

Yes.

15. Can a Tablespace hold objects from different Schemes ?

Yes.

16. Can objects of the same Schema reside in different tablespaces.?

Page 55: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Yes.

17. What is the use of Control File ?

When an instance of an ORACLE database is started, its control fileis used to identify the database and redo log files that must beopened for database operation to proceed. It is also used indatabase recovery.

18. Do View contain Data ?

Views do not contain or store data.

19. What are the Referential actions supported by FOREIGN KEYintegrity constraint ?

UPDATE and DELETE Restrict - A referential integrity rule thatdisallows the update or deletion of referenced data. DELETE Cascade -When a referenced row is deleted all associated dependent rows aredeleted.

20. What are the type of Synonyms?

There are two types of Synonyms Private and Public

21. What is a Redo Log ?

The set of Redo Log files YSDATE,UID,USER or USERENV SQL functions,or the pseudo columns LEVEL or ROWNUM.

22. What is an Index Segment ?

Each Index has an Index segment that stores all of its data.

23. Explain the relationship among Database, Tablespace and Datafile.?

Each databases logically divided into one or more tablespaces one ormore data files are explicitly created for each tablespace

24. What are the different type of Segments ?

Data Segment, Index Segment, Rollback Segment and Temporary Segment.

25. What are Clusters ?

Page 56: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Clusters are groups of one or more tables physically stores togetherto share common columns and are often used together.

26. What is an Integrity Constrains ?

An integrity constraint is a declarative way to define a businessrule for a column of a table.

27. What is an Index ?

An Index is an optional structure associated with a table to havedirect access to rows, which can be created to increase theperformance of data retrieval. Index can be created on one or morecolumns of a table.

28. What is an Extent ?

An Extent is a specific number of contiguous data blocks, obtainedin a single allocation, and used to store a specific type ofinformation.

29. What is a View ?

A view is a virtual table. Every view has a Query attached to it.(The Query is a SELECT statement that identifies the columns androws of the table(s) the view uses.)

30. What is Table ?

A table is the basic unit of data storage in an ORACLE database. Thetables of a database hold all of the user accessible data. Tabledata is stored in rows and columns.

31. What is a Synonym ?

A synonym is an alias for a table, view, sequence or program unit.

32. What is a Sequence ?

A sequence generates a serial list of unique numbers for numericalcolumns of a database’s tables.

33. What is a Segment ?

A segment is a set of extents allocated for a certain logicalstructure.

Page 57: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

34. What is schema?

A schema is collection of database objects of a User.

35. Describe Referential Integrity ?

A rule defined on a column (or set of columns) in one table thatallows the insert or update of a row only if the value for thecolumn or set of columns (the dependent value) matches a value in acolumn of a related table (the referenced value). It also specifiesthe type of data manipulation allowed on referenced data and theaction to be performed on dependent data as a result of any actionon referenced data.

36. What is Hash Cluster ?

A row is stored in a hash cluster based on the result of applying ahash function to the row’s cluster key value. All rows with the samehash key value are stores together on disk.

37. What is a Private Synonyms ?

A Private Synonyms can be accessed only by the owner.

40. What is Database Link ?

A database link is a named object that describes a “path” from onedatabase to another.

41. What is a Tablespace?

A database is divided into Logical Storage Unit called tablespaces.A tablespace is used to grouped related logical structures together

42. What is Rollback Segment ?

A Database contains one or more Rollback Segments to temporarilystore “undo” information.

43. What are the Characteristics of Data Files ?

A data file can be associated with only one database. Once created adata file can’t change size. One or more data files form a logicalunit of database storage called a tablespace.

44. How to define Data Block size ?

Page 58: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

A data block size is specified for each ORACLE database when thedatabase is created. A database users and allocated free databasespace in ORACLE datablocks. Block size is specified in INIT.ORA fileand can’t be changed latter.

45. What does a Control file Contain ?

A Control file records the physical structure of the database. Itcontains the following information.Database NameNames and locations of a database’s files and redolog files.Time stamp of database creation.

46.What is difference between UNIQUE constraint and PRIMARY KEYconstraint ?

A column defined as UNIQUE can contain Nulls while a column definedas PRIMARY KEY can’t contain Nulls.

47.What is Index Cluster ?

A Cluster with an index on the Cluster Key

48.When does a Transaction end ?

When it is committed or Rollbacked.

49. What is the effect of setting the value “ALL_ROWS” forOPTIMIZER_GOAL parameter of the ALTER SESSION command ? What are thefactors that affect OPTIMIZER in choosing an Optimization approach ?

Answer The OPTIMIZER_MODE initialization parameter Statistics in theData Dictionary the OPTIMIZER_GOAL parameter of the ALTER SESSIONcommand hints in the statement.

50. What is the effect of setting the value “CHOOSE” forOPTIMIZER_GOAL, parameter of the ALTER SESSION Command ?

The Optimizer chooses Cost_based approach and optimizes with thegoal of best throughput if statistics for at least one of the tablesaccessed by the SQL statement exist in the data dictionary.Otherwise the OPTIMIZER chooses RULE_based approach.

51. What is the function of Optimizer ?

Page 59: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

The goal of the optimizer is to choose the most efficient way toexecute a SQL statement.

52. What is Execution Plan ?

The combinations of the steps the optimizer chooses to execute astatement is called an execution plan.

53. What are the different approaches used by Optimizer in choosingan execution plan ?

Rule-based and Cost-based.

54. What does ROLLBACK do ?

ROLLBACK retracts any of the changes resulting from the SQLstatements in the transaction.

55. What is SAVE POINT ?

For long transactions that contain many SQL statements, intermediatemarkers or savepoints can be declared which can be used to divide atransaction into smaller parts. This allows the option of laterrolling back all work performed from the current point in thetransaction to a declared savepoint within the transaction.

56. What are the values that can be specified for OPTIMIZER MODEParameter ?

COST and RULE.

57. What is COST-based approach to optimization ?

Considering available access paths and determining the mostefficient execution plan based on statistics in the data dictionaryfor the tables accessed by the statement and their associatedclusters and indexes.

58. What does COMMIT do ?

COMMIT makes permanent the changes resulting from all SQL statementsin the transaction. The changes made by the SQL statements of atransaction become visible to other user sessions transactions thatstart only after transaction is committed.

59. What is RULE-based approach to optimization ?

Page 60: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Choosing an executing plan based on the access paths available andthe ranks of these access paths.

60. What are the values that can be specified for OPTIMIZER_GOALparameter of the ALTER SESSION Command ?

CHOOSE,ALL_ROWS,FIRST_ROWS and RULE.

61. Define Transaction ?

A Transaction is a logical unit of work that comprises one or moreSQL statements executed by a single user.

62. What is Read-Only Transaction ?

A Read-Only transaction ensures that the results of each queryexecuted in the transaction are consistent with respect to the samepoint in time.

63. What is a deadlock ? Explain .

Two processes waiting to update the rows of a table which are lockedby the other process then deadlock arises. In a database environmentthis will often happen because of not issuing proper row lockcommands. Poor design of front-end application may cause thissituation and the performance of server will reduce drastically.These locks will be released automatically when a commit/rollbackoperation performed or any one of these processes being killedexternally.

64. What is a Schema ?

The set of objects owned by user account is called the schema.

65. What is a cluster Key ?

The related columns of the tables are called the cluster key. Thecluster key is indexed using a cluster index and its value is storedonly once for multiple tables in the cluster.

66. What is Parallel Server ?

Multiple instances accessing the same database (Only In Multi-CPUenvironments)

Page 61: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

67. What are the basic element of Base configuration of an oracleDatabase ?

It consists ofone or more data files.One or more control files.Two or more redo log files.The Database containsmultiple users/schemasone or more rollback segmentsone or more tablespacesData dictionary tablesUser objects (table, indexes, views etc.,)The server that access the database consists ofSGA (Database buffer, Dictionary Cache Buffers, Redo log buffers,Shared SQL pool)SMON (System MONitor)PMON (Process MONitor)LGWR (LoG Write)DBWR (Data Base Write)ARCH (ARCHiver)CKPT (Check Point)RECODispatcherUser Process with associated PGS

68. What is clusters ?

Group of tables physically stored together because they share commoncolumns and are often used together is called Cluster.

69. What is an Index ? How it is implemented in Oracle Database ?

An index is a database structure used by the server to have directaccess of a row in a table. An index is automatically created when aunique of primary key constraint clause is specified in create tablecommand (Ver. 7.0)

70. What is a Database instance ? Explain

A database instance (Server) is a set of memory structure andbackground processes that access a set of database files.The process can be shared by all users. The memory structure thatare used to store most queried data from database. This helps up toimprove database performance by decreasing the amount of I/Operformed against data file.

Page 62: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

71. What is the use of ANALYZE command ?

To perform one of these functions on an index, table, or cluster:- To collect statistics about object used by the optimizer and storethem in the data dictionary.- To delete statistics about the object used by object from thedata dictionary.- To validate the structure of the object..- To identify migrated and chained rows off the table or cluster.

72. What is default tablespace ?

The Tablespace to contain schema objects created without specifyinga tablespace name.

73. What are the system resources that can be controlled throughProfile ?

The number of concurrent sessions the user can establish the CPUprocessing time available to the user’s session the CPU processingtime available to a single call to ORACLE made by a SQL statementthe amount of logical I/O available to the user’s session the amountof logical I/O available to a single call to ORACLE made by a SQLstatement the allowed amount of idle time for the user’s session theallowed amount of connect time for the user’s session.

74. What is Tablespace Quota ?

The collective amount of disk space available to the objects in aschema on a particular tablespace.

76. What are the different Levels of Auditing ?

Statement Auditing, Privilege Auditing and Object Auditing.

77. What is Statement Auditing ?

Statement auditing is the auditing of the powerful system privilegeswithout regard to specifically named objects

78. What are the database administrators utilities available ?

SQL * DBA - This allows DBA to monitor and control an ORACLEdatabase. SQL * Loader - It loads data from standard operatingsystem files (Flat files) into ORACLE database tables. Export (EXP)

Page 63: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

and Import (imp) utilities allow you to move existing data in ORACLEformat to and from ORACLE database.

79. How can you enable automatic archiving ?

Shut the databaseBackup the databaseModify/Include LOG_ARCHIVE_START_TRUE in init.ora file.Start up the database.

80. What are roles? How can we implement roles ?

Roles are the easiest way to grant and manage common privilegesneeded by different groups of database users. Creating roles andassigning provides to roles. Assign each role to group of users.This will simplify the job of assigning privileges to individualusers.

81. What are Roles ?

Roles are named groups of related privileges that are granted tousers or other roles.

82. What are the use of Roles ?

REDUCED GRANTING OF PRIVILEGES - Rather than explicitly granting thesame set of privileges to many users a database administrator cangrant the privileges for a group of related users granted to a roleand then grant only the role to each member of the group.DYNAMIC PRIVILEGE MANAGEMENT - When the privileges of a group mustchange, only the privileges of the role need to be modified. Thesecurity domains of all users granted the group’s role automaticallyreflect the changes made to the role.SELECTIVE AVAILABILITY OF PRIVILEGES - The roles granted to a usercan be selectively enable (available for use) or disabled (notavailable for use). This allows specific control of a user’sprivileges in any given situation.APPLICATION AWARENESS - A database application can be designed toautomatically enable and disable selective roles when a userattempts to use the application.

83. What is Privilege Auditing ?

Privilege auditing is the auditing of the use of powerful systemprivileges without regard to specifically named objects.

Page 64: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

84. What is Object Auditing ?

Object auditing is the auditing of accesses to specific schemaobjects without regard to user.

85. What is Auditing ?

Monitoring of user access to aid in the investigation of databaseuse.

86. What are the responsibilities of a Database Administrator ?

Installing and upgrading the Oracle Server and application tools.Allocating system storage and planning future storage requirementsfor the database system. Managing primary database structures(tablespaces) Managing primary objects (table, views, indexes)Enrolling users and maintaining system security. Ensuring compliancewith Oracle license agreement Controlling and monitoring user accessto the database. Monitoring and optimizing the performance of thedatabase. Planning for backup and recovery of database information.Maintain archived data on tape Backing up and restoring thedatabase. Contacting Oracle Corporation for technical support.

87. What is a trace file and how is it created ?

Each server and background process can write an associated tracefile. When an internal error is detected by a process or userprocess, it dumps information about the error to its trace. This canbe used for tuning the database.

88. What is a profile ?

Each database user is assigned a Profile that specifies limitationson various system resources available to the user.

89. How will you enforce security using stored procedures?

Don’t grant user access directly to tables within the application.Instead grant the ability to access the procedures that access thetables. When procedure executed it will execute the privilege ofprocedures owner. Users cannot access tables except via theprocedure.

90. What are the dictionary tables used to monitor a databasespaces ?

Page 65: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

DBA_FREE_SPACEDBA_SEGMENTSDBA_DATA_FILES.

91. What are the roles and user accounts created automatically withthe database?

DBA - role Contains all database system privileges.SYS user account - The DBA role will be assigned to this account.All of the base tables and views for the database’s dictionary arestore in this schema and are manipulated only by ORACLE. SYSTEM useraccount - It has all the system privileges for the database andadditional tables and views that display administrative informationand internal tables and views used by oracle tools are created usingthis username.

92. What are the minimum parameters should exist in the parameterfile (init.ora) ?

DB NAME - Must set to a text string of no more than 8 characters andit will be stored inside the datafiles, redo log files and controlfiles and control file while database creation.DB_DOMAIN - It is string that specifies the network domain where thedatabase is created. The global database name is identified bysetting these parameters(DB_NAME & DB_DOMAIN) CONTORL FILES - List of control filenames ofthe database. If name is not mentioned then default name will beused.DB_BLOCK_BUFFERS - To determine the no of buffers in the buffercache in SGA.PROCESSES - To determine number of operating system processes thatcan be connected to ORACLE concurrently. The value should be 5(background process) and additional 1 for each user.ROLLBACK_SEGMENTS - List of rollback segments an ORACLE instanceacquires at database startup. Also optionallyLICENSE_MAX_SESSIONS,LICENSE_SESSION_WARNING and LICENSE_MAX_USERS.

93. How can we specify the Archived log file name format anddestination?

By setting the following values in init.ora file. LOG_ARCHIVE_FORMAT= arch %S/s/T/tarc (%S - Log sequence number and is zero left padded,%s - Log sequence number not padded. %T - Thread number left-zero-padded and %t - Thread number not padded). The file name created isarch 0001 are if %S is used. LOG_ARCHIVE_DEST = path.

Page 66: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

94. What is user Account in Oracle database?

A user account is not a physical structure in Database but it ishaving important relationship to the objects in the database andwill be having certain privileges. 95. When will the data in thesnapshot log be used?

We must be able to create a after row trigger on table (i.e., itshould be not be already available) After giving table privileges.We cannot specify snapshot log name because oracle uses the name ofthe master table in the name of the database objects that supportits snapshot log. The master table name should be less than or equalto 23 characters. (The table name created will be MLOGS_tablename,and trigger name will be TLOGS name).

96. What dynamic data replication?

Updating or Inserting records in remote database through databasetriggers. It may fail if remote database is having any problem.

97. What is Two-Phase Commit ?

Two-phase commit is mechanism that guarantees a distributedtransaction either commits on all involved nodes or rolls back onall involved nodes to maintain data consistency across the globaldistributed database. It has two phase, a Prepare Phase and a CommitPhase.

98. How can you Enforce Referential Integrity in snapshots ?

Time the references to occur when master tables are not in use.Perform the reference the manually immediately locking the mastertables. We can join tables in snapshots by creating a complexsnapshots that will based on the master tables.

99. What is a SQL * NET?

SQL *NET is ORACLE’s mechanism for interfacing with thecommunication protocols used by the networks that facilitatedistributed processing and distributed databases. It is used inClint-Server and Server-Server communications.

100. What is a SNAPSHOT ?

Snapshots are read-only copies of a master table located on a remotenode which is periodically refreshed to reflect changes made to the

Page 67: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

master table.

101. What is the mechanism provided by ORACLE for tablereplication ?

Snapshots and SNAPSHOT LOGs

102. What is snapshots?

Snapshot is an object used to dynamically replicate data betweendistribute database at specified time intervals. In ver. 7.0 they areread only.

103. What are the various type of snapshots?

Simple and Complex.

104. Describe two phases of Two-phase commit ?

Prepare phase - The global coordinator (initiating node) ask aparticipants to prepare (to promise to commit or rollback thetransaction, even if there is a failure) Commit - Phase - If allparticipants respond to the coordinator that they are prepared, thecoordinator asks all nodes to commit the transaction, if allparticipants cannot prepare, the coordinator asks all nodes to rollback the transaction.

105. What is snapshot log ?

It is a table that maintains a record of modifications to the mastertable in a snapshot. It is stored in the same database as mastertable and is only available for simple snapshots. It should becreated before creating snapshots.

106. What are the benefits of distributed options in databases?

Database on other servers can be updated and those transactions canbe grouped together with others in a logical unit.Database uses a two phase commit.

107. What are the options available to refresh snapshots ?

COMPLETE - Tables are completely regenerated using the snapshotsquery and the master tables every time the snapshot referenced.FAST - If simple snapshot used then a snapshot log can be used tosend the changes to the snapshot tables.

Page 68: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

FORCE - Default value. If possible it performs a FAST refresh;Otherwise it will perform a complete refresh.

108. What is a SNAPSHOT LOG ?

A snapshot log is a table in the master database that is associatedwith the master table. ORACLE uses a snapshot log to track the rowsthat have been updated in the master table. Snapshot logs are usedin updating the snapshots based on the master table.

109. What is Distributed database ?

A distributed database is a network of databases managed by multipledatabase servers that appears to a user as single logical database.The data of all databases in the distributed database can besimultaneously accessed and modified.

110. How can we reduce the network traffic?

- Replication of data in distributed environment.- Using snapshots to replicate data.- Using remote procedure calls.

111. Differentiate simple and complex, snapshots ?

- A simple snapshot is based on a query that does not containsGROUP BY clauses, CONNECT BY clauses, JOINs, sub-query or snapshot ofoperations.- A complex snapshots contain at least any one of the above.

112. What are the Built-ins used for sending Parameters to forms?

You can pass parameter values to a form when an application executesthe call_form, New_form, Open_form or Run_product.

113. Can you have more than one content canvas view attached with awindow?

Yes. Each window you create must have at least one content canvasview assigned to it. You can also create a window that hasmanipulated content canvas view. At run time only one of the contentcanvas views assign to a window is displayed at a time.

114. Is the After report trigger fired if the report executionfails?

Page 69: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Yes.

115. Does a Before form trigger fire when the parameter form issuppressed?

Yes.116. Is it possible to split the print reviewer into more than oneregion?

Yes

117. Is it possible to center an object horizontally in a repeatingframe that has a variable horizontal size?

Yes

118. For a field in a repeating frame, can the source come from thecolumn which does not exist in the data group which forms the basefor the frame?

Yes

119. Can a field be used in a report without it appearing in anydata group?

Yes

120. The join defined by the default data link is an outer join yesor no?

Yes

121. Can a formula column referred to columns in higher group?

Yes

122. Can a formula column be obtained through a select statement?

Yes

123. Is it possible to insert comments into sql statements return inthe data model editor?

Yes

Page 70: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

124. Is it possible to disable the parameter from while running thereport?

Yes

126. When a form is invoked with call_form, Does oracle forms issuesa save point?

Yes

127. Can a property clause itself be based on a property clause?

Yes

128. If a parameter is used in a query without being previouslydefined, what diff. exist between. report 2.0 and 2.5 when the query isapplied?

While both reports 2.0 and 2.5 create the parameter, report 2.5gives a message that a bind parameter has been created.

129. What are the sql clauses supported in the link property sheet?

Where start with having.

130. What is trigger associated with the timer?

When-timer-expired.

131. What are the trigger associated with image items?

When-image-activated fires when the operators double clicks on animage item when-image-pressed fires when an operator clicks or doubleclicks on an image item

132. What are the different windows events activated at runtimes?

When_window_activatedWhen_window_closedWhen_window_deactivatedWhen_window_resizedWithin this triggers, you can examine the built in system variablesystem. event_window to determine the name of the window for whichthe trigger fired.

133. When do you use data parameter type?

Page 71: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

When the value of a data parameter being passed to a called productis always the name of the record group defined in the current form.Data parameters are used to pass data to products invoked with therun_product built-in subprogram.

134. What is difference between open_form and call_form?

when one form invokes another form by executing open_form the firstform remains displayed, and operators can navigate between the formsas desired. when one form invokes another form by executingcall_form, the called form is modal with respect to the callingform. That is, any windows that belong to the calling form aredisabled, and operators cannot navigate to them until they firstexit the called form.

135. What is new_form built-in?

When one form invokes another form by executing new_form oracle formexits the first form and releases its memory before loading the newform calling new form completely replace the first with the second.If there are changes pending in the first form, the operator will beprompted to save them before the new form is loaded.

136. What is the “LOV of Validation” Property of an item? What isthe use of it?

When LOV for Validation is set to True, Oracle Forms compares thecurrent value of the text item to the values in the first columndisplayed in the LOV. Whenever the validation event occurs. If thevalue in the text item matches one of the values in the first columnof the LOV, validation succeeds, the LOV is not displayed, andprocessing continues normally. If the value in the text item doesnot match one of the values in the first column of the LOV, OracleForms displays the LOV and uses the text item value as the searchcriteria to automatically reduce the list.

137. What is the diff. when Flex mode is mode on and when it is off?

When flex mode is on, reports automatically resizes the parent whenthe child is resized.

138. What is the diff. when confine mode is on and when it is off?

When confine mode is on, an object cannot be moved outside itsparent in the layout.

Page 72: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

139. What are visual attributes?

Visual attributes are the font, color, pattern proprieties that youset for form and menu objects that appear in your applicationinterface.

140. Which of the two views should objects according to possession?

view by structure.

141. What are the two types of views available in the objectnavigator(specific to report 2.5)?

View by structure and view by type .

142. What are the vbx controls?

Vbx control provide a simple method of building and enhancing userinterfaces. The controls can use to obtain user inputs and displayprogram outputs.vbx control where originally develop as extensionsfor the ms visual basic environments and include such items assliders, rides and knobs.

143. What is the use of transactional triggers?

Using transactional triggers we can control or modify the defaultfunctionality of the oracle forms.

144. How do you create a new session while open a new form?

Using open_form built-in setting the session option Ex. Open_form(’Stocks ‘, active, session). when invoke the multiple forms withopen form and call_form in the same application, state whether thefollowing are true/False

145. What are the ways to monitor the performance of the report?

Use reports profile executable statement. Use SQL trace facility.

146. If two groups are not linked in the data model editor, What isthe hierarchy between them?

Two group that is above are the left most rank higher than the groupthat is to right or below it.

Page 73: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

147. An open form cannot be execute the call_form procedure if youchain of called forms has been initiated by another open form?

True

148. Explain about horizontal, Vertical tool bar canvas views?

Tool bar canvas views are used to create tool bars for individualwindows. Horizontal tool bars are display at the top of a window,just under its menu bar. Vertical Tool bars are displayed along theleft side of a window

149. What is the purpose of the product order option in the columnproperty sheet?

To specify the order of individual group evaluation in a crossproducts.

150. What is the use of image_zoom built-in?

To manipulate images in image items.

151. How do you reference a parameter indirectly?

To indirectly reference a parameter use the NAME IN, COPY ‘built-insto indirectly set and reference the parameters value’ Examplename_in (’capital parameter my param’), Copy (’SURESH’, 'Parameter my_param’)

152. What is a timer?

Timer is an “internal time clock” that you can programmaticallycreate to perform an action each time the times.

153. What are the two phases of block coordination?

There are two phases of block coordination: the clear phase and thepopulation phase. During, the clear phase, Oracle Forms navigatesinternally to the detail block and flushes the obsolete detailrecords. During the population phase, Oracle Forms issues a SELECTstatement to repopulate the detail block with detail recordsassociated with the new master record. These operations areaccomplished through the execution of triggers.

154. What are Most Common types of Complex master-detailrelationships?

Page 74: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

There are three most common types of complex master-detailrelationships:master with dependent detailsmaster with independent detailsdetail with two masters

155. What is a text list?

The text list style list item appears as a rectangular box whichdisplays the fixed number of values. When the text list containsvalues that cannot be displayed, a vertical scroll bar appears,allowing the operator to view and select undisplayed values.

156. What is term?

The term is terminal definition file that describes the terminalform which you are using r20run.

157. What is use of term?

The term file which key is correspond to which oracle reportfunctions.

158. What is pop list?

The pop list style list item appears initially as a single field(similar to a text item field). When the operator selects the listicon, a list of available choices appears.

159. What is the maximum no of chars the parameter can store?

The maximum no of chars the parameter can store is only valid forchar parameters, which can be up to 64K. No parameters default to23Bytes and Date parameter default to 7Bytes.

160. What are the default extensions of the files created by librarymodule?

The default file extensions indicate the library module type andstorage format .pll - pl/sql library module binary

161. What are the Coordination Properties in a Master-Detailrelationship?

The coordination properties areDeferred

Page 75: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Auto-QueryThese Properties determine when the population phase of blockcoordination should occur.

162. How do you display console on a window ?

The console includes the status line and message line, and isdisplayed at the bottom of the window to which it is assigned. Tospecify that the console should be displayed, set the console windowform property to the name of any window in the form. To include theconsole, set console window to Null.

163. What are the different Parameter types?

Text ParametersData Parameters

164. State any three mouse events system variables?

System.mouse_button_pressed System.mouse_button_shift

165. What are the types of calculated columns available?

Summary, Formula, Placeholder column.

166. Explain about stacked canvas views?

Stacked canvas view is displayed in a window on top of, or “stacked”on the content canvas view assigned to that same window. Stackedcanvas views obscure some part of the underlying content canvasview, and or often shown and hidden programmatically.

167. What are the built-ins used the display the LOV?

Show_lovList_values

168. What is the difference between SHOW_EDITOR and EDIT_TEXTITEM?

Show editor is the generic built-in which accepts any editor nameand takes some input string and returns modified output string.Whereas the edit_textitem built-in needs the input focus to be inthe text item before the built-in is executed.

169. What are the built-ins that are used to Attach an LOVprogrammatically to an item?

Page 76: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

set_item_propertyget_item_property(by setting the LOV_NAME property)

170. How do you call other Oracle Products from Oracle Forms?

Run_product is a built-in, Used to invoke one of the supportedoracle tools products and specifies the name of the document ormodule to be run. If the called product is unavailable at the timeof the call, Oracle Forms returns a message to the operator.

171. What is the main diff. bet. Reports 2.0 & Reports 2.5?

Report 2.5 is object oriented.

172. What are the different file extensions that are created byoracle reports?

Rep file and Rdf file.

173. What is strip sources generate options?

Removes the source code from the library file and generates alibrary files that contains only pcode. The resulting file can beused for final deployment, but cannot be subsequently edited in thedesigner.ex. f45gen module=old_lib.pll userid=scott/tigerstrip_source YES output_file

176. What is the basic data structure that is required for creatingan LOV?

Record Group.

177. What is the Maximum allowed length of Record group Column?

Record group column names cannot exceed 30 characters.

178. Which parameter can be used to set read level consistencyacross multiple queries?

Read only

179. What are the different types of Record Groups?

Query Record GroupsNonQuery Record Groups

Page 77: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

State Record Groups

180. From which designation is it preferred to send the output tothe printed?

Previewer

181. what are difference between post database commit and post-formcommit?

Post-form commit fires once during the post and commit transactionsprocess, after the database commit occurs. The post-form-committrigger fires after inserts, updates and deletes have been posted tothe database but before the transactions have been finalized in theissuing the command. The post-database-commit trigger fires afteroracle forms issues the commit to finalized transactions.

182. What are the different display styles of list items?

Pop_listText_listCombo box

183. Which of the above methods is the faster method?

performing the calculation in the query is faster.

184. With which function of summary item is the compute at optionsrequired?

percentage of total functions.

185. What are parameters?

Parameters provide a simple mechanism for defining and setting thevalues of inputs that are required by a form at startup. Formparameters are variables of type char, number, date that you define atdesign time.

186. What are the three types of user exits available ?

Oracle Precompiler exits, Oracle call interface, NonOracle userexits.

187. How many windows in a form can have console?

Only one window in a form can display the console, and you cannotchange the console assignment at runtime

Page 78: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

188.If the maximum record retrieved property of the query is set to10 then a summary value will be calculated?

Only for 10 records.

189.What are the two repeating frame always associated with matrixobject?

One down repeating frame below one across repeating frame.

190. What are the master-detail triggers?\

On-Check_delete_masterOn_clear_detailsOn_populate_details

191. What are the different objects that you cannot copy orreference in object groups?

Objects of different modulesAnother object groupsIndividual block dependent itemsProgram units.

192. What is an OLE?

Object Linking & Embedding provides you with the capability tointegrate objects from many Ms-Windows applications into a singlecompound document creating integrated applications enables you touse the features form .

193. Is it possible to modify an external query in a report whichcontains it?

No.

194. Does a grouping done for objects in the layout editor affectthe grouping done in the data model editor?

No.

195. Can a repeating frame be created without a data group as abase?

No

196. If a break order is set on a column would it affect columnswhich are under the column?

Page 79: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

No

197. Is it possible to set a filter condition in a cross productgroup in matrix reports?

No

198. Do user parameters appear in the data modal editor in 2.5?

No

199. Can you pass data parameters to forms?

No

200. Is it possible to link two groups inside a cross products afterthe cross products group has been created?

no

201. What are the different modals of windows?

Modalless windowsModal windows

202. What are modal windows?

Modal windows are usually used as dialogs, and have restrictedfunctionality compared to modalless windows. On some platforms forexample operators cannot resize, scroll or iconify a modal window.

203. What are the different default triggers created when MasterDeletes Property is set to Non-isolated?

Master Deletes Property Resulting Triggers—————————————————–Non-Isolated(the default) On-Check-Delete-MasterOn-Clear-DetailsOn-Populate-Details

204. What are the different default triggers created when MasterDeletes Property is set to isolated?

Master Deletes Property Resulting Triggers—————————————————-

Page 80: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Isolated On-Clear-DetailsOn-Populate-Details

205. What are the different default triggers created when MasterDeletes Property is set to Cascade?

Master Deletes Property Resulting Triggers—————————————————-Cascading On-Clear-DetailsOn-Populate-DetailsPre-delete

206. What is the diff. bet. setting up of parameters in reports 2.0reports2.5?

LOVs can be attached to parameters in the reports 2.5 parameterform.

207. What are the difference between lov & list item?

Lov is a property where as list item is an item. A list item canhave only one column, lov can have one or more columns.

208. What is the advantage of the library?

Libraries provide a convenient means of storing client-side programunits and sharing them among multiple applications. Once you createa library, you can attach it to any other form, menu, or librarymodules. When you can call library program units from triggers menuitems commands and user named routine, you write in the modules towhich you have attach the library. When a library attaches anotherlibrary, program units in the first library can reference programunits in the attached library. Library support dynamic loading-thatis library program units are loaded into an application only whenneeded. This can significantly reduce the run-time memoryrequirements of applications.

209. What is lexical reference? How can it be created?

Lexical reference is place_holder for text that can be embedded in asql statements. A lexical reference can be created using & beforethe column or parameter name.

210. What is system.coordination_operation?

Page 81: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

It represents the coordination causing event that occur on themaster block in master-detail relation.

211. What is synchronize?

It is a terminal screen with the internal state of the form. Itupdates the screen display to reflect the information that oracleforms has in its internal representation of the screen.

212. What use of command line parameter cmd file?

It is a command line argument that allows you to specify a file thatcontain a set of arguments for r20run.

213. What is a Text_io Package?

It allows you to read and write information to a file in the filesystem.

214. What is forms_DDL?

Issues dynamic Sql statements at run time, including server sidepl/SQl and DDL

215. How is link tool operation different bet. reports 2 & 2.5?

In Reports 2.0 the link tool has to be selected and then two fieldsto be linked are selected and the link is automatically created. In2.5 the first field is selected and the link tool is then used tolink the first field to the second field.

216. What are the different styles of activation of ole Objects?

In place activation External activation

217. How do you reference a Parameter?

In Pl/Sql, You can reference and set the values of form parametersusing bind variables syntax. Ex. PARAMETER name = ” or :block.item= PARAMETER Parameter name

218. What is the difference between object embedding & linking inOracle forms?

In Oracle forms, Embedded objects become part of the form module,and linked objects are references from a form module to a linked

Page 82: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

source file.

219. Name of the functions used to get/set canvas properties?

Get_view_property, Set_view_property

220. What are the built-ins that are used for setting the LOVproperties at runtime?

get_lov_propertyset_lov_property

221. What are the built-ins used for processing rows?

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)

222. What are built-ins used for Processing rows?

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)

223. What are the built-in used for getting cell values?

Get_group_char_cell(function)Get_groupcell(function)Get_group_number_cell(function)

224. What are the built-ins used for Getting cell values?

GET_GROUP_CHAR_CELL (function)GET_GROUPCELL(function)GET_GROUP_NUMBET_CELL(function)

225. At least how many set of data must a data model have before adata model can be base on it?

Four

Page 83: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

226. To execute row from being displayed that still use column inthe row which property can be used?

Format trigger.

227. What are different types of modules available in oracle form?

Form module - a collection of objects and code routines Menumodules - a collection of menus and menu item commands that togethermake up an application menu library module - a collection of usernamed procedures, functions and packages that can be called fromother modules in the application

228. What is the remove on exit property?

For a modalless window, it determines whether oracle forms hides thewindow automatically when the operators navigates to an item in theanother window.

229. What is WHEN-Database-record trigger?

Fires when oracle forms first marks a record as an insert or anupdate. The trigger fires as soon as oracle forms determines throughvalidation that the record should be processed by the next post orcommit as an insert or update. c generally occurs only when theoperators modifies the first item in the record, and after theoperator attempts to navigate out of the item.

230. What is a difference between pre-select and pre-query?

Fires during the execute query and count query processing afteroracle forms constructs the select statement to be issued, butbefore the statement is actually issued. The pre-query trigger firesjust before oracle forms issues the select statement to the databaseafter the operator as define the example records by entering thequery criteria in enter query mode.Pre-query trigger fires beforepre-select trigger.

231. What are built-ins associated with timers?

find_timer create_timer delete_timer

232. What are the built-ins used for finding object ID functions?

Find_group(function)Find_column(function)

Page 84: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

233. What are the built-ins used for finding Object ID function?

FIND_GROUP(function)FIND_COLUMN(function)

234. Any attempt to navigate programmatically to disabled form in acall_form stack is allowed?

False

235. Use the Add_group_row procedure to add a row to a static recordgroup 1. true or false?

False

236. Use the add_group_column function to add a column to recordgroup that was created at a design time?

False

237. What are the various sub events a mouse double click eventinvolves? What are the various sub events a mouse double click eventinvolves?

Double clicking the mouse consists of the mouse down, mouse up,mouse click, mouse down & mouse up events.

238. How can a break order be created on a column in an existinggroup? What are the various sub events a mouse double click eventinvolves?

By dragging the column outside the group.

239. What is the use of place holder column? What are the varioussub events a mouse double click event involves?

A placeholder column is used to hold calculated values at aspecified place rather than allowing is to appear in the actual rowwhere it has to appear.

240. What is the use of hidden column? What are the various subevents a mouse double click event involves?

A hidden column is used to when a column has to embed intoboilerplate text.

Page 85: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

241. What is the use of break group? What are the various sub eventsa mouse double click event involves?

A break group is used to display one record for one group ones.While multiple related records in other group can be displayed.

242. What is an anchoring object & what is its use? What are thevarious sub events a mouse double click event involves?

An anchoring object is a print condition object which used toexplicitly or implicitly anchor other objects to itself.

243. What are the various sub events a mouse double click eventinvolves? What are the various sub events a mouse double click eventinvolves?

Double clicking the mouse consists of the mouse down, mouse up,mouse click, mouse down & mouse up events.

245. What are the default parameter that appear at run time in theparameter screen? What are the various sub events a mouse doubleclick event involves?

Destype and Desname.

246. What are the built-ins used for Creating and deleting groups?

CREATE-GROUP (function)CREATE_GROUP_FROM_QUERY(function)DELETE_GROUP(procedure)

247. What are different types of canvas views?

Content canvas viewsStacked canvas viewsHorizontal toolbarvertical toolbar.

248. What are the different types of Delete details we can establishin Master-Details?

CascadeIsolateNon-isolate

249. What is relation between the window and canvas views?

Page 86: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Canvas views are the back ground objects on which you place theinterface items (Text items), check boxes, radio groups etc.,) andboilerplate objects (boxes, lines, images etc.,) that operatorsinteract with us they run your form . Each canvas views displayed ina window.

250. What is a User_exit?

Calls the user exit named in the user_exit_string. Invokes a 3Glprogram by name which has been properly linked into your currentoracle forms executable.

251. How is it possible to select generate a select set for thequery in the query property sheet?

By using the tables/columns button and then specifying the table andthe column names.

252. How can values be passed bet. precompiler exits & Oracle callinterface?

By using the statement EXECIAFGET & EXECIAFPUT.

253. How can a square be drawn in the layout editor of the reportwriter?

By using the rectangle tool while pressing the (Constraint) key.

254. How can a text file be attached to a report while creating inthe report writer?

By using the link file property in the layout boiler plate propertysheet.

255. How can I message to passed to the user from reports?

By using SRW.MESSAGE function.

256. How is possible to restrict the user to a list of values whileentering values for parameters?

By setting the Restrict To List property to true in the parameterproperty sheet.

257. How can a button be used in a report to give a drill downfacility?

Page 87: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

By setting the action associated with button to Execute pl/sqloption and using the SRW.Run_report function.

258. How can a cross product be created?

By selecting the cross products tool and drawing a new groupsurrounding the base group of the cross products.

259. What are different types of images?

Boiler plate images Image Items

260. What is the difference between boiler plat images and imageitems?

Boiler plate Images are static images (Either vector or bit map)that you import from the file system or database to use a graphicalelements in your form, such as company logos and maps. Image itemsare special types of interface controls that store and displayeither vector or bitmap images. Like other items that store values,image items can be either base table items(items that relatedirectly to database columns) or control items. The definition of animage item is stored as part of the form module FMB and FMX files,but no image file is actually associated with an image item untilthe item is populate at run time.

261. What is bind reference and how can it be created?

Bind reference are used to replace the single value in sql, pl/sqlstatements a bind reference can be created using a (:) before acolumn or a parameter name.

262. What are the triggers available in the reports?

Before report, Before form, After form , Between page, After report.

263. Give the sequence of execution of the various report triggers?

Before form , After form , Before report, Between page, Afterreport.

264. Why is a Where clause faster than a group filter or a formattrigger?

Because, in a where clause the condition is applied during dataretrieval than after retrieving the data.

Page 88: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

265. Why is it preferable to create a fewer no. of queries in thedata model?

Because for each query, report has to open a separate cursor and hasto rebind, execute and fetch data.

266. Where is the external query executed at the client or theserver?

At the server.

267. Where is a procedure return in an external pl/sql libraryexecuted at the client or at the server?

At the client.

268. What is coordination Event?

Any event that makes a different record in the master block thecurrent record is a coordination causing event.

269. What is the difference between OLE Server & Ole Container?

An Ole server application creates ole Objects that are embedded orlinked in ole Containers ex. Ole servers are ms_word & ms_excel. OLEcontainers provide a place to store, display and manipulate objectsthat are created by ole server applications. Ex. oracle forms is anexample of an ole Container.

270. What is an object group?

An object group is a container for a group of objects; you define anobject group when you want to package related objects, so that youcopy or reference them in other modules.

271. What is an LOV?

An LOV is a scrollable popup window that provides the operator witheither a single or multi column selection list.

272. At what point of report execution is the before Report triggerfired?

After the query is executed but before the report is executed andthe records are displayed.

Page 89: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

273. What are the built -ins used for Modifying a groups structure?

ADD-GROUP_COLUMN (function)ADD_GROUP_ROW (procedure)DELETE_GROUP_ROW(procedure)

274. What is an user exit used for?

A way in which to pass control (and possibly arguments ) form Oraclereport to another Oracle products of 3 GL and then return control (and ) back to Oracle reports.

275. What is the User-Named Editor?

A user named editor has the same text editing functionality as thedefault editor, but, because it is a named object, you can specifyeditor attributes such as windows display size, position, and title.

276. What are the Built-ins to display the user-named editor?

A user named editor can be displayed programmatically with the builtin procedure SHOW-EDITOR, EDIT_TETITEM independent of any particulartext item.

277. What is a Static Record Group?

A static record group is not associated with a query, rather, youdefine its structure and row values at design time, and they remainfixed at runtime.

278. What is a record group?

A record group is an internal Oracle Forms that structure that has acolumn/row framework similar to a database table. However, unlikedatabase tables, record groups are separate objects that belong tothe form module which they are defined.

279. How many number of columns a record group can have?

A record group can have an unlimited number of columns of type CHAR,LONG, NUMBER, or DATE provided that the total number of column doesnot exceed 64K.

280. What is a Query Record Group?

Page 90: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

A query record group is a record group that has an associated SELECTstatement. The columns in a query record group derive their defaultnames, data types, had lengths from the database columns referencedin the SELECT statement. The records in query record group are therows retrieved by the query associated with that record group. Whatis a Non Query Record Group?

281. What is a property clause?

A property clause is a named object that contains a list ofproperties and their settings. Once you create a property clause youcan base other object on it. An object based on a property caninherit the setting of any property in the clause that makes sensefor that object.

282. What is a physical page ? & What is a logical page ?

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 asseen in the Previewer.

283. What does the term panel refer to with regard to pages?

A panel is the no. of physical pages needed to print one logicalpage.

284. What is a master detail relationship?

A master detail relationship is an association between two basetable blocks- a master block and a detail block. The relationshipbetween the blocks reflects a primary key to foreign keyrelationship between the tables on which the blocks are based.

285.What is a library?

A library is a collection of subprograms including user namedprocedures, functions and packages.

286. How can a group in a cross products be visually distinguishedfrom a group that does not form a cross product?

A group that forms part of a cross product will have a thickerborder.

287. What is the frame & repeating frame?

Page 91: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

A frame is a holder for a group of fields. A repeating frame is usedto display a set of records when the no. of records that are todisplayed is not known before.

288. What is a combo box?

A combo box style list item combines the features found in list andtext item. Unlike the pop list or the text list style list items,the combo box style list item will both display fixed values andaccept one operator entered value.

289. What are three panes that appear in the run time pl/sqlinterpreter?

1. Source pane.2. interpreter pane.3. Navigator pane.

290. What are the two panes that Appear in the design time pl/sqlinterpreter?

1. Source pane.2. Interpreter pane

291. What are the two ways by which data can be generated for aparameters list of values?

1. Using static values.2. Writing select statement.

292. What are the various methods of performing a calculation in areport ?

1. Perform the calculation in the SQL statements itself.2. Use a calculated / summary column in the data model.

293. What are the default extensions of the files created by menumodule?

.mmb,

.mmx

294. What are the default extensions of the files created by formsmodules?

Page 92: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

.fmb - form module binary

.fmx - form module executable

295. To display the page no. for each page on a report what would bethe source & logical page no. or & of physical page no.?

& physical page no.

296. It is possible to use raw devices as data files and what is theadvantages over file. system files ?

Yes. The advantages over file system files. I/O will be improvedbecause Oracle is bye-passing the kernel which writing into disk.Disk Corruption will be very less.

297. What are disadvantages of having raw devices ?

We should depend on export/import utility for backup/recovery (fullyreliable) The tar command cannot be used for physical file backup,instead we can use dd command which is less flexible and has limitedrecoveries.

298. What is the significance of having storage clause ?

We can plan the storage for a table as how much initial extents arerequired, how much can be extended next, how much % should leavefree for managing row updating etc.,

299. What is the use of INCTYPE option in EXP command ?

Type export should be performed COMPLETE,CUMULATIVE,INCREMENTAL.List the sequence of events when a large transaction that exceedsbeyond its optimal value when an entry wraps and causes the rollbacksegment to expand into anotion Completes. e. will be written.

300. What is the use of FILE option in IMP command ?

The name of the file from which import should be performed.

301. What is a Shared SQL pool?

The data dictionary cache is stored in an area in SGA called theShared SQL Pool. This will allow sharing of parsed SQL statementsamong concurrent users.

302. What is hot backup and how it can be taken?

Page 93: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set

Taking backup of archive log files when database is open. For thisthe ARCHIVELOG mode should be enabled. The following files need tobe backed up. All data files. All Archive log, redo log files. Allcontrol files.

303. List the Optional Flexible Architecture (OFA) of Oracledatabase? or How can we organize the tablespaces in Oracle databaseto have maximum performance ?

SYSTEM - Data dictionary tables.DATA - Standard operational tables.DATA2- Static tables used for standard operationsINDEXES - Indexes for Standard operational tables.INDEXES1 - Indexes of static tables used for standard operations.TOOLS - Tools table.TOOLS1 - Indexes for tools table.RBS - Standard Operations Rollback Segments,RBS1,RBS2 - Additional/Special Rollback segments.TEMP - Temporary purpose tablespaceTEMP_USER - Temporary tablespace for users.USERS - User tablespace.

304. How to implement the multiple control files for an existingdatabase ?

Shutdown the database Copy one of the existing control file to newlocation Edit Config ora file by adding new control file. nameRestart the database.

305. What is advantage of having disk shadowing/ Mirroring ?

Shadow set of disks save as a backup in the event of disk failure.In most Operating System if any disk failure occurs it automaticallyswitchover to place of failed disk. Improved performance becausemost OS support volume shadowing can direct file I/O request to usethe shadow set of files instead of the main set of files. Thisreduces I/O load on the main set of disks.

306. How will you force database to use particular rollbacksegment ?

SET TRANSACTION USE ROLLBACK S

Page 94: DBA Interview Q&A

Sep . 17

DBA interview Questions and answers second set