Most Important Frequently Asked Accenture Db2 Interview Questions
-
Question 1. Explain How Would You Retrieve Rows From A Db2 Table In Embedded Sql?
Answer :
can achieve it by either by using the single row SELECT statements, or by using the CURSOR
-
Answer :
By using Single row SELECT.
IBM - VSAM Interview Questions -
Question 3. Explain How Can You Specify And Use A Cursor In A Cobol Program?
Answer :
Try to use DECLARE CURSOR statement either in working storage or in procedure division, to specify the SELECT statement Then use OPEN, FETCH rows in a loop and finally CLOSE.
-
Question 4. Can You Tell Me What Will Happen When You Say Open Cursor?
Answer :
If there is an ORDER BY clause, rows are fetched, sorted and made available for the FETCH statement Other wise simply the cursor is placed on the first row.
IBM-CICS Tutorial -
Question 5. Is It Possible More Than One Cursor Open At Any One Time In A Program?
Answer :
Yes, we can open more than one cursor at a time
IBM-CICS Interview Questions -
Question 6. Can You Tell If Declare Cursor Is Executable?
Answer :
No, DECLARE CURSOR is not executable.
-
Question 7. Explain In Brief How Do You Leave The Cursor Open After Issuing A Commit?
Answer :
Use WITH HOLD option in DECLARE CURSOR statement, it has not effect in psuedo-conversational CICS programs.
IBM DB2 Tutorial IBM DB2 Interview Questions -
Question 8. When You Do A Database Commit, Is The Cursor Closed In Db2?
Answer :
Yes, the cursor will be closed.
-
Question 9. Describe The Cobol Definition Of A Varchar Field?
Answer :
A VARCHAR column REMARKS would be defined as follows: 10 REMARKS 49 REMARKS-LEN PIC S9(4) USAGE COMP 49 REMARKS-TEXT PIC X(1920)
Core Java Interview Questions -
Answer :
DATE, TIME, TIMESTAMP and its picture clause in COBOL. DATE: 4bytes DATE: PIC X(10) TIME: 3bytes TIME PIC X(08) TIMESTAMP: 10bytes TIMESTAMP: PIC X(26)
Core Java Tutorial -
Question 11. Explain What Are The Contents Of A Dclgen In Db2?
Answer :
EXEC SQL DECLARE TABLE statement which gives the layout of the table/view in terms of DB2 datatypes. A host language copy book that gives the host variable definitions for the column Names.
COBOL Interview Questions -
Question 12. In Db2, Is It Always Mandatory To Use Dclgen? If Not, Why Would You Use It At All?
Answer :
It is not always mandatory to use DCLGEN Using DCLGEN, helps detect wrongly spelt column names etc during the pre- compile stage itself ( because of the DECLARE TABLE ) DCLGEN being a tool, would generate accurate host variable definitions for the table reducing chances of error.
IBM - VSAM Interview Questions -
Question 13. Is Is Always Mandatory To Use Declare Table In Dclgen ? Can You Tell Why It Used?
Answer :
It not mandatory to have DECLARE TABLE statement in DCLGEN This is used by the pre-compiler to validate the table-name, view-name, column name etc, during pre-compile.
COBOL Tutorial -
Question 14. Explain In Brief How Is A Typical Db2 Batch Program Gets Executed ?
Answer :
You should Use DSN utility to run a DB2 batch program from native TSO An example is shown: DSN SYSTEM(DSP3) RUN PROGRAM(EDD470BD) PLAN(EDD470BD) LIB('ED01TOBJLOADLIB') END Use IKJEFT01 utility program to run the above DSN command in a JCL
-
Question 15. List Some Fields From Sqlca.?
Answer :
SQLCODE, SQLERRM, SQLERRD
IBM-JCL Interview Questions -
Question 16. Can You Tell Me How Can You Find Out The # Of Rows Updated After An Update Statement?
Answer :
You need to check the value stored in SQLERRD(3)
IBM-JCL Tutorial -
Question 17. Can You Tell What Do You Need To Do Before You Do Explain?
Answer :
You have to ensure that the PLAN_TABLE is created under the AUTHID
DB2 Using SQL Interview Questions -
Question 18. Can You Tell Where Is The Output Of Explain Stored?
Answer :
In user id PLAN_TABLE
IBM-CICS Interview Questions -
Question 19. What Does It Mean - Explain Has Output With Matchcols = 0?
Answer :
A non matching index scan if ACCESSTYPE = I
DB2 Using SQL Tutorial -
Question 20. Explain How Can You Do The Explain Of A Dynamic Sql Statement?
Answer :
- Use SPUFI or MF to EXPLAIN the dynamic SQL statement
- Include EXPLAIN command in the embedded dynamic SQL statements
IBM-JCL&VSAM Interview Questions -
Question 21. Explain What Are The Various Isolation Levels Possible ?
Answer :
The isolation levels are CS: Cursor Stability RR: Repeatable Read
-
Question 22. Differentiate Between Cs And Rr Isolation Levels?where Do You Specify Them?
Answer :
CS: Releases the lock on a page after use
RR: Retains all locks acquired till end of transaction. ISOLATION LEVEL is a parameter for the bind process
-
Question 23. When Do You Specify The Isolation Level?
Answer :
During the BIND process ISOLATION ( CS/RR )
Java-Multithreading Interview Questions -
Question 24. Name The Various Locking Levels Available?
Answer :
PAGE, TABLE, TABLESPACE
IBM DB2 Interview Questions -
Question 25. Explain In Brief How Does Db2 Determine What Lock-size To Use?
Answer :
- Based on the lock-size given while creating the tablespace
- Programmer can direct the DB2 what lock-size to use
- If lock-size ANY is specified, DB2 usually choses a lock-size of PAGE
-
Question 26. Explain What Are The Disadvantages Of Page Level Lock In Db2?
Answer :
The main disadvantage is the high resource utilization if large updates are to be done.
DB2 SQL Programming Interview Questions
Topic: Accenture Db2 Interview Questions
No comments:
Post a Comment