DB2 Interview Questions and Answers

DB2 is the database management system that delivers a flexible and cost-effective database platform to build robust on demand business applications. DB2 further leverages your resources with broad support for open standards and popular development platforms like J2EE and Microsoft .NET. The DB2 family also includes solutions tailored for specific needs like business intelligence and advanced tooling. Whether your business is large or small, DB2 has a solution built and priced to meet your unique needs.

DB2 Interviews are getting tough these days as the technology grows faster. To get through the DB2 interview one needs to update him/herself in a regular manner. Having said that, just before the interview, it is very important to have a quick glance of the reputed DB2 questions and answers to make yourself comfortable during the interview process. This is where DoAnswers.com helps you in renewing yourself on DB2 and various other technologies interview preparation.



<< Previous                Next >>

 

11. Can you have more than one cursor open at any one time in a program ? ?

Yes.


12. Can you use MAX on a CHAR column?

YES.


13. Consider the employee table with column PROJECT nullable. How can you get a list of employees who are not assigned to any project?

SELECT EMPNO FROM EMP WHERE PROJECT IS NULL;


14. Describe the elements of the SELECT query syntax. SELECT element FROM table WHERE conditional statement.

SELECT statement is used for selecting a particular items or all items from a table...it is as desired by the user. FROM statement is used to to tell the table name. WHERE statement is used to specify a particular condition while choosing the values When u will use curser with hold option? On executing a COMMIT statement in the Program all the open cursors are closed. In order to avoid this we use the WITH HOLD option. If i have a cursor in program and there is a commit statement it will close the cursor, so in order to avoid that u use a cursor with hold option to retain the cursor position We use cursor only when we updating existing records or Inserting Some Records to the Table. When you Using commit, in DB2 every single row will be commited after the process. If abend occurs only the cursor will be closed, we can start from last position(Where it abended) of cursor , using Restart


15. Does your query involve column functions?

If your query involves column functions, make sure that they are coded as simply as possible; this increases the chances that they will be evaluated when the data is retrieved, rather than afterward. In general, a column function performs best when evaluated during data access and next best when evaluated during DB2 sort.

Least preferable is to have a column function evaluated after the data has been retrieved. For column functions to be evaluated during data retrieval, the following conditions must be met for all column functions in the query:

There must be no sort needed for GROUP BY. Check this in the EXPLAIN output.

There must be no stage 2 (residual) predicates. Check this in your application. There must be no distinct set functions such as COUNT(DISTINCT C1).

If the query is a join, all set functions must be on the last table joined. Check this by looking at the EXPLAIN output.

All column functions must be on single columns with no arithmetic expressions. Difference between Embedded SQL and Dynamic SQL.

The difference is the time at which the BIND occurs. In static mode, the bind is done prior to the execution and is stored in a PLAN. In dynamic mode, the BIND occurs at execution time. This results in additional overhead which degrades performance. This form of dynamic SQL will NOT be used in our environment The difference is the time at which the BIND occurs.


Your Ad Here

16. EXPLAIN has output with MATCHCOLS = 0. What does it mean?

 
a nonmatching index scan if ACCESSTYPE = I.


17. EXPLAIN has output with MATCHCOLS = 0. What does it mean? ?

a nonmatching index scan if ACCESSTYPE = I.


18. Explain the use of the WHERE clause. WHERE is used with a relational statement to isolate the object element or row. where clause is use to extrct only one record.it is used with GROUP BY CLAUSE.

EG:-SELECT DNO FROM EMP WHERE SAL=4200 GROUP BY DNO; DISCRIPTION:- where dno is (dept. no) emp is (employi table), here we are retriving dept.no whose salary is 4200 & these dept no's are arrenged in acending order.


19. Give some example of statistics collected during RUNSTATS?

# of rows in the table Percent of rows in clustering sequence # of distinct values of indexed column # of rows moved to a nearby/farway page due to row length increase


20. Give the COBOL definition of a VARCHAR field.

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).


Your Ad Here

<< Previous                Next >>

 
Databases Questions and Answers
 
DB2 Interview Questions and Answers
IMS Interview Questions and Answers
MYSQL Interview Questions and Answers
Oracle Interview Questions and Answers
PL/SQL Interview Questions And Answers
Quel Interview Questions and Answers
SQL Interview Questions and Answers

 
 
.NET Interview Questions and Answers
 
ASP Interview Questions and Answers
C# Interview Questions and Answers
Visual Basic Interview Questions and Answers
 
J2EE Interview Questions and Answers
 
Enterprise Java Beans (EJB) Interview Questions And Answers
Hibernate Interview Questions And Answers
Jave Messaging Service (JMS) Interview Questions And Answers
Jave Server Faces (JSF) Interview Questions And Answers
Java Server Pages (JSP) Interview Questions And Answers
Servlets Interview Questions And Answers
Spring Framework Interview Questions And Answers
Struts Framework Interview Questions And Answers
 
JAVA Interview Questions and Answers
 
Core Java Interview Questions and Answers
Java Platform, Micro Edition (Java ME) Interview Questions And Answers
JAVA GUI Interview Questions and Answers
Java Performance Tuning Interview Questions And Answers
JUnit Interview Questions And Answers
Remote Method Invocation (RMI) Interview Questions And Answers
Unified Modeling Language (UML) Interview Questions And Answers
 
Java Application Server Interview Questions And Answers
 
Tomcat Application Server Interview Questions And Answers
WebLogic Application Server Interview Questions And Answers
 
Mainframe Interview Questions and Answers
 
CICS Interview Questions and Answers
COBOL Interview Questions and Answers
IMS Interview Questions and Answers
JCL Interview Questions and Answers
REXX Interview Questions and Answers
TELON Interview Questions and Answers
VSAM Interview Questions and Answers
 
Object Oriented Language Questions and Answers
 
C Interview Questions and Answers
C++ Interview Questions and Answers
Eiffel Interview Questions and Answers
J2EE Interview Questions and Answers
JAVA Interview Questions and Answers
Sather Interview Questions and Answers
Small talk Interview Questions and Answers
 
Operation Systems Interview Questions and Answers
 
MS DOS Interview Questions and Answers
Unix OS Interview Questions and Answers
Windows Interview Questions and Answers
 
Scripting languages Interview Questions and Answers
 
Java Script Interview Questions and Answers
Practical Extraction and Reporting Language Interview Questions and Answers
PHP Interview Questions and Answers
VBScript Interview Questions and Answers
 
UserInterfaces Questions and Answers
 
Foxit Interview Questions and Answers
Glade Interview Questions and Answers
Tweak Interview Questions and Answers
 
WEB Technologies Questions and Answers
 
AJAX Interview Questions and Answers
HTML Interview Questions and Answers
WML Interview Questions and Answers
XML Interview Questions and Answers
 
Interview Tips And Some Common Questions
 
Behavioral Interview Questions And Answers


Your Ad Here