Corporate Training
Request Demo
Click me
Let's Talk
Request Demo

IMS DB Interview Questions and Answers

by Mohammed, on May 19, 2018 3:21:30 PM

IMS DB Interview Questions and Answers

Q1. What is IMS (DB/DC)?

Ans: IMS (Information Management System) is IBMs hierarchical database management system. It has mainly two components: IMS DB and IMS DC (Also know as IMS TM)
IMS DB - IMS/Database Manager as the name implies manages the IMS databases. It is used for physical storage creation and management and data retrieval.
IMS DC / IMS TM - IMS/Data Communications or IMS/Transaction Manager handles online transaction processing system

Q2. What are the main control blocks available in IMS DB?

Ans: There are three control blocks (also known as DL/I control blocks)
1.Database Description (DBD)
2.Program Specification Block (PSB)
3.Application Control Block (ACB)

Q3. What kind of databases IMS supports?

Ans: Full-function database and Fast path database

Q4. What are the objectives of DBMS in IMS?

Ans: Increases data independence
Reduces data redundancy
Provides data communication facilities
Reduces data maintenance
Provides data integrity and security
Provides indexing capabilities

Q5. What is DL/I?

Ans: DL/I is a command-level language to manipulate IMS databases. DL/I forms a bridge between application program and IMS database. It is used in batch and online programs to access data stored in IMS databases.
Every access to an IMS database is through DL/I. The DL/I interface must be called to update or read a IMS database. DL/I allows both sequential and random processing of a database.

Q6. How data is stored in both IMSDB and DB2 databases?

Ans: Some business applications require that the data is kept in both IMS and DB2 for z/OS databases. One such scenario is a high-performance production application that works with the data in an IMS database and a business decision support application that works with the same data in a DB2 for z/OS database. Production applications running in IMS Transaction Manager (IMS TM) can update data that is stored in a DB2 for z/OS database and data that is stored in an IMS database. If not performed in a single, logical unit of work, coordinating these updates can be complex

Q7. What is a root segment?

Ans: A segment that lies at the top of the hierarchy is called the root segment. It is the only segment through which all dependent segments are accessed.

Q8. What are twin segments?

Ans: Two or more segment occurrences of a particular segment type under a single parent segment occurrence are called twin segments.

Q9. What are common DLI functions?

Ans: The common functions are GU, GN, GNP, GHU, GHN, REPL, ISRT, and DLET.

Q10. What is PSB and PCB?

Ans: PSB is Program Specification Block which is a collection of one or more PCBs.
PCB is Program Control Block which represents the application program's view of the database.

Q11. What is PROCOPT?

Ans: PROCOPT is processing option defined in PCB, which specifies the operations that can be performed on the database. Different PROCOPTs that can be used are
G - Get segment from DB
I - Insert segment into DB
R - Replace segment
D - Delete segment
A - All the above operations
LS - Load Sequential in GSAM (HIDAM)
GS - Get Sequential in GSAM

Q12. What information does a DBD contain?

Ans: DBD information includes:
1.Database name, Access method
2.Dataset name
3.Segment name, length, parent
4.Key field name, length, location, type
5. Search field name, length, location, type.

Q13. What is a segment in IMS?

Ans: Segment is the smallest unit of information that IMS transfers to and from database. Segment may contain one or more fields.

Q14. Which languages does IMS support / application program languages?

Ans: COBOL, PL/1, C, VS Pascal, REXX, Ada and Assembler.

Q15. What are the two types of fields available in IMS DB?

Key Fields - (PROCOPT=K)

  • Used to sequence the database and can't be changed
  • It�s the field within a segment, used to identify the occurrence of the segment
  • used to maintain the IMS segments in ascending sequence.

Search Fields - (PROCOPT=G)

  • Used to search for a segment, without the segment being sequenced on that field
  • A segment need not have a key or search field.

Both types of fields can be used to search the database.

Q16. What is the function of a GU call?

Ans: ‘GU’ or Get Unique works similar to the random read statement in COBOL. It is used to fetch a particular segment occurrence based on the field values which can be provided using Segment Search Arguments.

Q17. What is the function of a GHU call?

Ans: ‘GHU’ or Get Hold Unique specifies that we are going to update a segment after retrieval. GHU corresponds to the GU call.

Q18. What is reorganization in IMSDB?

Ans: To reclaim and consolidate free space that has become fragmented due to repeated insertion and deletion of segments.
To optimize the physical storage of the database segments for maximum performance (get dependent segments that are in distant blocks, which increases physical I/O, back in the same block as the parent or root), a situation that is normally the result of high update activity on the database.
To alter the structure of the database, change the size of the database data sets, alter the hierarchical direct access method (HDAM) root addressable area, and add or delete segment types.

Q19. What is SSA?

Ans: SSA is segment search argument. It is used to retrieve a particular segment or segment type from the DB.

Q20. What are qualified and unqualified calls?

Ans: IMS call with SSA is called qualified call. IMS call without SSA is unqualified call.

Q21. What are qualified and unqualified SSAs?

Ans: SSA which contains only the segment name is Unqualified SSA. SSA which contains segment name, field name, relational operator and search value for the field name is qualified SSA.

Q22. What are command codes?

Ans: Command codes are used along with SSAs to perform additional operations. Common command codes used are
'P' - used to set parentage on a particular segment
'D' - used for path calls, to retrieve the entire hierarchical path

Q23. What are the processing modes available in IMS DB?

Ans: MPP Mode - (Message Processing Program)
BMP Mode - (Batch Message Processing)

Q24. Explain IMS Software Environment?

Ans: IMS Software Environment consists of the below five main components:

  • IMS DB
  • DL/I
  • DL/I Control Blocks
  • IMS DC
  • Application Programs

Q25. What is DBD?

Ans: DBD (Database Definition) is used to define the physical structure of the database.
One DBD for each database Created by a series of control statements - by a process called DBDGEN
Used by DL/I whenever database is used

Q26. Explain DBDGEN process?

Ans: DBDGEN control statements consists of Assembler Language macro statements. The macros are supplied by IBM in a library named IMSVS.MACLIB. DBDGEN control statements are normally coded by the DBA and submitted to the system with JCL. That invokes a cataloged procedure usually called DBDGEN. The DBDGEN procedure causes the DBDGEN control statements to the processed by the assembler producing the object module. The object module is then passed to the linkage editor which, in turn, stores a load module in another IMS Library called as IMS.DBDLIB or IMSVS.DBDLIB.
The DBD process is normally preformed only once for a database. All applications use the DBD in accessing the information on the database. A new DBD is normally created only if the physical nature of the database changes.

Q27.  Which parameter specifies the language in which the application program is written in PSBGEN?

Ans: The LANG parameter specifies the language in which the application program is written, e.g., COBOL.

Q28. Which is used to pass the control back to the IMS control program?

Ans: GOBACK is used to pass the control back to the IMS control program.

Q29. Which function is used to get a unique record for update purpose?

Ans: ‘GHU’ code is used for Get Hold Unique. Hold function specifies that we are going to update the segment after retrieval. The Get Hold Unique function corresponds to the Get Unique call.

Q30. Which function is used to retrieve segment occurrences in sequence subordinate to an established parent segment?

Ans: ‘GNP’ code is used for Get Next within Parent. This function is used to retrieve segment occurrences in sequence subordinate to an established parent segment

Topics:Information Technologies (IT)



Top Courses in Python

Top Courses in Python

We help you to choose the right Python career Path at myTectra. Here are the top courses in Python one can select. Learn More →

aathirai cut mango pickle