IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

IMS DB-How to update a record (a single field value) via JCL


IBM Mainframe Forums -> IMS DB/DC
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
gthmrj

New User


Joined: 22 Feb 2017
Posts: 8
Location: India

PostPosted: Thu Mar 09, 2017 4:38 pm
Reply with quote

I'm trying to update a record in IMS database - a single field value using JCL. The JCL isn't working yet.

//SYSIN DD *
S11111 DXTPD01
L GHU TXMASTM (TXZPCTK EQCA95100 AAAAAAAAA )
L REPL TXMASTM (TXZPCTK EQCA95100 BBBBBBBBB )
/*


Please let me know how to correct the above query. I'm trying to replace the value 'AAAAAAAAA' with 'BBBBBBBBB'
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2455
Location: Hampshire, UK

PostPosted: Thu Mar 09, 2017 5:19 pm
Reply with quote

Well, apart from the ??SYSIN DD * and the /* there is no JCL there but control cards for some program but we know not what as you have not told us.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10872
Location: italy

PostPosted: Thu Mar 09, 2017 6:32 pm
Reply with quote

You did not tell anything useful...
You simply whined that some control cards for a program You told nothing about
did not provide the expected results
what do You expect from us ? icon_evil.gif
Back to top
View user's profile Send private message
gthmrj

New User


Joined: 22 Feb 2017
Posts: 8
Location: India

PostPosted: Thu Mar 09, 2017 6:33 pm
Reply with quote

Let me post the complete JCL here.. Please have a look

Code:
//RS155PXX JOB (9100),'DLT0 INRT XT',CLASS=W,MSGCLASS=E,             
//     REGION=4M,NOTIFY=&SYSUID,SCHENV=CBBH                           
//**                                                                 
//STEP02   EXEC PGM=DFSRRC00,                                         
//         PARM='BMP,DFSDDLT0,DBADDLT0,,,,,,,,,,,PRD1'               
//**                                                                 
//**                          DBADDLT0 IS A PSB WITH PROCOPT=A       
//**                                        FOR EVERY DPSS IMS SEGMENT
//**                                                                 
//STEPLIB  DD DSN=RS155P.SDFSRESL,DISP=SHR                           
//*        DD DSN=RS155P.DYNLIB,DISP=SHR                             
//         DD DSN=RS155P.RANDLIB,DISP=SHR                             
//         DD DSN=RS155P.UTIL.LOADLIB,DISP=SHR                       
//DFSRESLB DD DSN=RS155P.SDFSRESL,DISP=SHR                           
//IMS      DD DSN=DPSSC@.PRD1.DBDLIB,DISP=SHR                         
//         DD DSN=DPSSC@.PROD.PSBLIB,DISP=SHR                         
//IEFDRER  DD DUMMY                                                   
//SYSUDUMP DD SYSOUT=*                                               
//PRINTDD  DD SYSOUT=*                                               
//DFSVSAMP DD DSN=RS155P.OO2987.DBAM.SWCH.PIT4(VSAMP),DISP=SHR       
//SYSIN    DD *                                                       
S 1 1 1 1 1    DXTPD01                                               
L        GHU   TXMASTM (TXZPCTK EQCA95100    AAAAAAAAA        )   
L        REPL  TXMASTM (TXZPCTK EQCA95100    BBBBBBBBB        )   
/*                                                                   
/*
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10872
Location: italy

PostPosted: Thu Mar 09, 2017 6:40 pm
Reply with quote

still You did not post enough information

Quote:
The JCL isn't working yet.


How it is not working ...

jcl error
abend
error message
results different from the expected ones

post the job output

the IMS manual has a pretty good explanation on how to use the DLi test program ( DFSDDLT0)
Back to top
View user's profile Send private message
gthmrj

New User


Joined: 22 Feb 2017
Posts: 8
Location: India

PostPosted: Thu Mar 09, 2017 6:54 pm
Reply with quote

JCL runs fine. RC=00.
Though I'm not getting the expected results.

That is 'AAAAAAA' stays there. I need it to be replaced with 'BBBBBBB'.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10872
Location: italy

PostPosted: Thu Mar 09, 2017 6:59 pm
Reply with quote

the manual contains all You need to find out the error by Yourself

www.ibm.com/support/knowledgecenter/en/SSEPH2_13.1.0/com.ibm.ims13.doc.apr/ims_dlitestprogram.htm
Back to top
View user's profile Send private message
gthmrj

New User


Joined: 22 Feb 2017
Posts: 8
Location: India

PostPosted: Thu Mar 09, 2017 7:06 pm
Reply with quote

Thank you. I'll go through the manual and try.
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2455
Location: Hampshire, UK

PostPosted: Thu Mar 09, 2017 8:02 pm
Reply with quote

If the field that you are trying to change is the key then I am not sure that you can change it. You would need to create a new record.
Back to top
View user's profile Send private message
Gary Jacek

New User


Joined: 17 Dec 2007
Posts: 64
Location: Victoria, BC, Canada

PostPosted: Thu Mar 16, 2017 5:21 am
Reply with quote

Excellent pointer Enrico.

Nic...our friend gthmrj should also be aware that if the field to be replaced is a key field, and a GHU/DLET then ISRT/DATA are used, any segnments in the tree underneath the original segment will be lost. No doubt you already know this. icon_biggrin.gif

A PSBMAP of PSB DBADDLT0 would be helpful to visualize where in the database this segment lives, what child segments are under it, and what fields are key fields.

A DBDMAP of the database would be even better, since the PSBMAP may not present a schema that shows all possible child segments that might be discarded by a DLET of the parent segment.

Finally, that last entry in the DFSRRC00 parm list ... "PRD1" is very disturbing, since this is a BMP job. Any first timer using the DLI test program should not be running it against production data until their job is proven in a test region.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> IMS DB/DC

 


Similar Topics
Topic Forum Replies
No new posts SFTP Issue - destination file record ... All Other Mainframe Topics 2
No new posts FINDREP - Only first record from give... DFSORT/ICETOOL 3
No new posts Replace Multiple Field values to Othe... DFSORT/ICETOOL 12
No new posts To find whether record count are true... DFSORT/ICETOOL 6
No new posts Validating record count of a file is ... DFSORT/ICETOOL 13
Search our Forums:

Back to Top