Practice Question and Answer

Q: How do you display last 5 records in DB2? 1884 0

  • Show AnswerHide Answer
  • Workspace

Answer :
Explanation :

SELECT * FROM table_name ORDER BY column_name desc Fetch first 5 rows only;

Q: Difference between Embeded SQL and Dynamic SQL? 1825 0

  • Show AnswerHide Answer
  • Workspace

Answer :
Explanation :

Static (embedded) SQL: 1.In static SQL how database will be accessed is predetermined in the embedded SQL statement. 2.It is more swift and efficient. 3.SQL statements are compiled at compile time. 4.Parsing, validation, optimization, and generation of application plan are done at compile time. 5.It is generally used for situations where data is distributed uniformly. 6.EXECUTE IMMEDIATE, EXECUTE and PREPARE statements are not used. 7. It is less flexible    Dynamic (interactive) SQL: 1.In dynamic SQL, how database will be accessed is determined at run time. 2.It is less swift and efficient. 3.SQL statements are compiled at run time. 4.Parsing, validation, optimization, and generation of application plan are done at run time. 5.It is generally used for situations where data is distributed non-uniformly. 6.EXECUTE IMMEDIATE, EXECUTE and PREPARE statements are used. 7.It is more flexible.

Q: What is DBRM? What it contains? When it will be created? 1325 0

  • Show AnswerHide Answer
  • Workspace

Answer :
Explanation :

- DBRM stands for Database Request Module - The output of pre-compile process is represented as DBRM - The SQL statements are extracted from the host language by the pre-compiler

Q: How does DB2 use multiple table indexes? 971 0

  • Show AnswerHide Answer
  • Workspace

Answer :
Explanation :

DB2 use the multiple indexes to satisfy multiple predicates in a SELECT statement that are joined by an AND or OR.

Q: What is SPUFI? 1010 0

  • Show AnswerHide Answer
  • Workspace

Answer :
Explanation :

SPUFI stands for SQL processing using file input. It is the DB2 interactive menu-driven tool used by developers to create database objects.

Q: What is Mainframe Testing? 1950 0

  • Show AnswerHide Answer
  • Workspace

Answer :
Explanation :

Mainframe Testing is similar to client-server applications testing, but you have to know how to operate basic TSO and ISPF commands and menus, view mainframe files, look at and use SDSF or other output tool, log on CICS and transactions, use FTP or another transfer protocol, submit the batch job - it's for QA testing of mainframe applications.

Q: What is SQLCA? 1853 0

  • Show AnswerHide Answer
  • Workspace

Answer :
Explanation :

- SQLCA stands for SQL Communication Area - SQLCA is a structure of variables which are updated after every SQL statement’s execution - Exactly only one SQLCA need to be provided to an application that contains executable SQL statements - SQLCA is not applicable to JAVA application - More than one SQLCA need to be provided for FORTRAN application

Q: What is COPY PENDING status? 1048 0

  • Show AnswerHide Answer
  • Workspace

Answer :
Explanation :

- A status occurs when image copy on a table needs to be taken - The table is available only for queries and can not be updated - COPY PENDING status can be removed by taking away the image copy or by using REPAIR utility

      Report Error

    Please Enter Message
    Error Reported Successfully

      Report Error

    Please Enter Message
    Error Reported Successfully

      Report Error

    Please Enter Message
    Error Reported Successfully

      Report Error

    Please Enter Message
    Error Reported Successfully

      Report Error

    Please Enter Message
    Error Reported Successfully

      Report Error

    Please Enter Message
    Error Reported Successfully

      Report Error

    Please Enter Message
    Error Reported Successfully

      Report Error

    Please Enter Message
    Error Reported Successfully