What does message DB004097 indicate?

Document ID : KB000018498
Last Modified Date : 14/02/2018
Show Technical Document Details

Description:

During a generate of a DMCL, it is possible that a DB004097 message will be issued. This document describes what DB004097 means.

Solution:

When generating a DMCL, it is possible that you will see this error:-


 CONNECT TO SYSTEM;                                                              
 Status = 0        SQLSTATE = 00000                                              
 GENERATE DMCL CV65DMCL;                                                         
 Status = -4       SQLSTATE = 64000        Messages follow:                      
 DB004097 T61 C-4M6015: EMPDEMO.EMP-DEMO-REGION SYMBOL EMPNAME index displacement invalid.
 DB004099 T61 C-4M6015: ERRORS DETECTED DURING GENERATE - GENERATE DISALLOWED 

The DB004097 indicates that the number of pages in the DISPLACEMENT is greater than or equal to the number of pages in the area. This physical area is defined like this:


 CREATE                                              
 PHYSICAL AREA EMPDEMO.EMP-DEMO-REGION               
     PRIMARY SPACE 50 PAGES  FROM PAGE 75001         
     MAXIMUM SPACE 100 PAGES                         
     PAGE SIZE 4276 CHARACTERS                       
     INCLUDE SYMBOLIC INDEX EMPNAME                  
         BLOCK CONTAINS 5 KEYS DISPLACEMENT 50 PAGES 
     WITHIN FILE EMPDEMO                             
         FROM 1 FOR ALL BLOCKS                       
     ;

This situation was tolerated in earlier releases of CA-IDMS and no error generated. If a displacement greater than the number of pages was specified, the displacement as used

at run time simply "wrapped" around the end of the area and started from the beginning again. In particular, this meant that if a displacement was specified as equal to (or a multiple of) the number if pages, then it would have no effect at all.

The effect of this situation is most likely not what the user intended, so it was decided to issue an error when it was detected at DMCL generate time. Release 16.0 APAR QO88651 was written to implement this change and it was fixed in source in r17.0 and above.

Therefore, it is possible that you may have this condition existing in your DMCL, and not realize it until the first time you generate that DMCL after upgrading to r17.0 (if you never applied QO88651 in r16.0).

The solution in any case is to reduce the DISPLACEMENT to something less than the number of pages in the area.

This change does not require any action against the actual index. The displacement is only there to influence where individual index records (SR8s) are stored. The index can still be successfully navigated and updated regardless of what the displacement is.

However, if you want the new displacement value to be accurately reflected in the index, you will need to rebuild it with the MAINTAIN INDEX utility.

The definition of the DB004097 message is as follows:


 ADD                                                                    
 MESSAGE NAME IS DB004097                                               
     MESSAGE SEVERITY IS 0                                              
     TEXT LINE IS 1                                                     
         SEVERITY IS 0                                                  
         MESSAGE IS                                                     
             'T&$0 C&01M&02: &03 &04 index displacement invalid.'       
     DEFINITION                                                         
         ' DB004097   index displacement' 
   -     ' invalid.'                                                    
   -     ' '                                                            
   -     ' The displacement specified in the named Symbolic Index'      
   -     ' is greater than or equal to the number of pages in'          
   -     ' the Area.'                                                   
   -     ' '                                                            
     COMMENTS                                                           
         'Module(s) =  IDMSDDMG'