Follow Our FB Page << >> for Daily Laughter. We Post Funny, Viral, Comedy Videos, Memes, Vines...

DB2 Interview Questions
Questions Answers Views Company eMail

How to resolve -917 sql code in DB2?

Cap Gemini,

3 12160

How to resolve -407 sql code in DB2?

Cap Gemini,

9 23787

How to resolve -504 sql code in DB2?

Cap Gemini,

2 15172

What is the purpose of the SDSNLOAD dataset in the STEPLIB while running DB2 programs?

2 10743

What is the purpose of coding FETCH in a SQL SELECT query? Explain with an example in Detail?

4 5103

if suppose i am having an ACCOUNT table with 3 coloumns ACC. NO,ACC. NAME,ACC. AMOUNT . If a unique index is also defined on ACC.NO and ACC.NAME then write a query to retrieve account holders records who have more than 1 ACC.


8 6859

What are db2 error codes -305 and -407. What is the difference between these 2 error codes ?

1 6205

5 rows are inserted to a DB2 Table. Next 3 of those are updated, then a rollback is issued. What would happen when the rollback is issued?

2 4086

if there is a table with huge number of records and if i want to extract only first 3 records from the table, what query i have to provide to retreive first 3 records


4 4992

i hav created a program and moved to production but failed to create the table which is been used in the program. the program shows error as soon as it is moved or installed in production or shows error during its runtime. what is the sqlcode for this error


3 4599

a cursor normally gets closed once we provide a commit . If u try to close the same cursor with close cursor command later after providing the commit will there be any sql-error.

3 4959

in the CURSOR declare statement, if i am using an where clause and trying to compare the value with a host-varialble. EXEC SQL DECLARE C1 CURSOR FOR SELECT DEPTNO, DEPTNAME, MGRNO FROM DEPARTMENT WHERE ADMRDEPT = :ADM-DEPT Where would i need to provide value to this host-variable in the where clause. how could i pass value to this host-variable to check it.


2 6368

how can we find nth max salary from A table


5 20679

how to take the back up of the DB2 table.

7 16659

Can a array declared with an index be displayed(readable format) in spool?

Syntel, UST,

4 4152

Post New DB2 Questions

Un-Answered Questions { DB2 }

What is runstats and reorg in db2?


How connect db2 database to datastage?


Why db2 is called db2?


What is a buffer in memory?


I am having n number of records in a table which consists of emp-name is one of the field among them. Now i want to change the first letter of every name with capital.


Explain in detail about buffer manager and its functionalities?


i tried to copy some records from microsoft excel to as-400 physical file through "Bosanova" emulation. Out of 14000 records only 12000 records copies and subsequently programe started to hang. Then, i closed the program forcefully. I did' under stand the problem. Also when i try to compile the physical file it is showing as "The file in use". How to overcome this problem?


What is the use of dclgen in db2?


What is cursor with hold option in db2?


What are the full forms of spufi and dclgen and why are they used?


When do you specify the isolation level?


When reorg is used?


Mention a credible reason why select* is never given preference in an sql program that has been embedded.


SET is the ANSI standard for variable assignment, SELECT is not. SET can only assign one variable at a time, SELECT can make multiple assignments at once. If assigning from a query, SET can only assign a scalar value. If the query returns multiple values/rows then SET will raise an error. SELECT will assign one of the values to the variable and hide the fact that multiple values were returned (so you'd likely never know why something was going wrong elsewhere - have fun troubleshooting that one) When assigning from a query if there is no value returned then SET will assign NULL, where SELECT will not make the assignment at all (so the variable will not be changed from it's previous value) As far as speed differences - there are no direct differences between SET and SELECT. However SELECT's ability to make multiple assignments in one shot does give it a slight speed advantage over SET.


What is alias in db2?