InterviewSolution
This section includes InterviewSolutions, each offering curated multiple-choice questions to sharpen your knowledge and support exam preparation. Choose a topic below to get started.
| 1. |
How will you achieve record level locking in DB2 versions where record level locking is not allowed? |
|
Answer» We can ACHIEVE the record LEVEL locking in DB2 versions where the record level locking is not ALLOWED by having the length of the record greater than that of a page itself. Now that we have so much knowledge from the questions that we have studied, LET US now move to practice some of the MCQs that will help test your knowledge too. Useful Interview Resources
|
|
| 2. |
What is DSNDB07? What does it do? |
|
Answer» DSNDB07 is a database where the DB2 performs its sorting operations. It includes the SORT work-area of DB2 and EXTERNAL STORAGE. |
|
| 3. |
Is there any specific reason why SELECT is not preferred in embedded SQL programs? |
|
Answer» The SELECT statement is not preferred in EMBEDDED SQL programs for 3 reasons:
|
|
| 4. |
What is the RUN STATS that was mentioned in the previous answer? |
|
Answer» RUN STATS is a DB2 utility used to collect statistics about the data value in TABLES. It is used by the optimizer to decide the access PATH. RUN STATS ALSO collects statistics that are used for space management. These statistics are stored in the DB2 catalog tables. Usually, the RUN STATS is run after the FOLLOWING: |
|
| 5. |
Let us say that I have a program it uses dynamic SQL. It has been working fine till now, however, lately, I have found that the performance has been affected and deteriorated. Can you guess what can be the reason behind this? |
|
Answer» There can be 2 POSSIBILITIES: |
|
| 6. |
What are SPUFI and QMF? What is the difference between them? |
Answer»
|
|
| 7. |
In a COBOL-DB2 program, where are all the SQL statements coded? |
|
Answer» In a COBOL-DB2 PROGRAM, all the STATEMENTS are CODED in AREA B. |
|
| 8. |
What are ACQUIRE and RELEASE in BIND? |
|
Answer» A certain POINT in a PROGRAM when DB2 ACQUIRES or releases the locks against the TABLES and/or tablespaces. These include the intent locks as WELL. |
|
| 9. |
Let us say that we have a Student Database in which we have the details of the students like their names, address, attendance percentage, etc. Now we run an SQL Query that says: SELECT AVG ATTENDANCE FROM STUDENTS. |
|
Answer» Can you tell me any issues that may be here? Yes, there might be an ISSUE. For instance, if there is such a case where we have set that the ATTENDANCE of any student cannot be NULL and at the same time we have some students in the table whose attendance we don’t know, the AVG FUNCTION will calculate these students as well. Hence, we will get an answer but, it might not be correct. |
|
| 10. |
Is it possible for you to alter the table (adding a column to it) while some other person is accessing the table and even updating some values in it? |
|
Answer» To be short and CRISP, the answer is yes, we can alter the table at the same time when some other transaction is taking place but this does not exactly happen as it SOUNDS to be. The DB2 table will not change its structure in any form till a transaction or MULTIPLE TRANSACTIONS are taking place. The table-altering commands will be stored by the database engine and will not be executed till all the transactions are complete. After one user has MODIFIED the values in the table, then the column will be added. |
|
| 12. |
Do you know any programming language where more than one SQLCA is used? |
|
Answer» YES, FORTRAN APPLICATIONS REQUIRE more than one SQLCA. |
|
| 13. |
How many SQLCA must be provided to an application that contains SQL statements (executable)? |
|
Answer» Only one SQLCA is needed for an application that CONTAINS executable SQL STATEMENTS. HOWEVER, SQLCA is not applicable to Java applications. |
|