Determining which source file member was used to create an object
When an object is created from source, the information about the source file, library, and member is held in the object. The date and time when the source member was last changed before object creation is also saved in the object.
The information in the object can be displayed with the Display Object Description (DSPOBJD) command and specifying DETAIL(*SERVICE).
This information can help you in determining which source member was used and if the existing source member was changed since the object was created. You can also ensure that the source used to create an object is the same as the source that is currently in the source member using the following commands:
- The Display File Description (DSPFD) command using TYPE(*MBR). This display shows both date and time for the source member. The Last source update date/time value should be used to compare to the Source file date/time value displayed from the DSPOBJD command.
- The Display Object Description (DSPOBJD) command using DETAIL(*SERVICE). This display shows the date and time of the source member used to create the object.
If you are using the data written to output files to determine if the source and object dates are the same, then you can compare the ODSRCD (source date) and ODSRCT (source time) fields from the output file of the DSPOBJD DETAIL(*SERVICE) command to the MBUPDD (member update date) and MBUPDT (member update time) fields from the output file of the DSPFD TYPE(*MBR) command.
Parent topic:
Creating an object using a source file
Related reference
Display Object Description (DSPOBJD) command
Display File Description (DSPFD) command