Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

How UPDATE is different then READ+REPL?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IMS DB/DC
View previous topic :: :: View next topic  
Author Message
asifaddy
Warnings : 1

New User


Joined: 06 Feb 2007
Posts: 5
Location: Bangalore

PostPosted: Tue Feb 13, 2007 12:00 pm    Post subject: How UPDATE is different then READ+REPL?
Reply with quote

hi all,




can any body tell me the difference between the following:

for updating any of the record in the IMS data base we will use READ with HOLD and then REPL Calls but instead of that we can use just UPDATE which internally call two functions like GHU and REPL but before or after calling up i have pass the new values to the fields which are to be updated but row is not getting updated can any body explain how actually it works?


regards

Aseef,
Back to top
View user's profile Send private message

Devzee

Active Member


Joined: 20 Jan 2007
Posts: 684
Location: Hollywood

PostPosted: Tue Feb 13, 2007 1:32 pm    Post subject:
Reply with quote

You are correct in IMS to update a segment first we need to do GET segment with hold option and do a REPLace.

In IMS there is no UPDATE function, may be this is an interface program developed specifically at your site.

In IMS unit of I/O is always segments, not sure why you are referring as rows.

Please give more details like status code if failing to REPL?
Back to top
View user's profile Send private message
asifaddy
Warnings : 1

New User


Joined: 06 Feb 2007
Posts: 5
Location: Bangalore

PostPosted: Tue Feb 13, 2007 2:28 pm    Post subject: HI Devzee
Reply with quote

ya Devzee

sorry what you said is correct always segment not rows, sory for that



while compiling it gives maxcc=00,

but when i run the program it is abended with sdc s000 u3504

and produced ceedump here is a code of the update functions please have a look and reply

============================= ================
SEQ==> CWTS8I01
REC=> CWTS8I01 @DEFINE
0001 AUTOEXEC TRANSACT
============================= ================
PCB==> BQ2PM00 BQ2PM00
SEG=> SQ2RT @DEFINE CW-SUPP-ID
0001 UPDATE
================bottom of data=====================

the paragraph which is generated by the update function is below:



********************************* TOP OF DATA***************
* DEFAULT GENERATED USER I/O
* DEFAULT CALL: ** U-100-UPDATE-SQ2RT ****

* ** SSAS IN STORAGE


* ** ASSIGNMENT STATEMENT FOR KEY



CALL 'CBLTDLI' USING GHU-FUNC
BQ2PM00-PCB
UPDATE-AREA

CALL 'CBLTDLI' USING REPL-FUNC
BQ2PM00-PCB
Q2RT-SUPP-SAT-RT-SEG-GRP.

********************************* BOTTOM OF DATA************



regards
aseef


[/url]
Back to top
View user's profile Send private message
Bitneuker

CICS Moderator


Joined: 07 Nov 2005
Posts: 1105
Location: The Netherlands at Hole 19

PostPosted: Tue Feb 13, 2007 4:49 pm    Post subject:
Reply with quote

The update-generator doesn't show the SSA of which segmenttype to get and hold. I would expect the following information in your call repesenting the SSA; segmenttype = SQ2RT with value passed for key CW-SUPP-ID.
Quote:
SEG=> SQ2RT @DEFINE CW-SUPP-ID


Funny though there's no status-code icon_neutral.gif
Back to top
View user's profile Send private message
asifaddy
Warnings : 1

New User


Joined: 06 Feb 2007
Posts: 5
Location: Bangalore

PostPosted: Tue Feb 13, 2007 5:36 pm    Post subject:
Reply with quote

hi George


with update instead of giving the key(CW-SUPP-ID)of file read
if we give the key of the database and also we have to move the
CW-SUPP-ID to the key field of the database(Q2RT-RA-SUPP-ID) then we will make it work other wise its giving the same abend code during run time
i got that by doing so if you have any other methods of doing it please kindly inform


here is the code

====== ======== ==============================
SEQ==> CWTS8I01
REC=> CWTS8I01 @DEFINE
0001 AUTOEXEC TRANSACT
============================== ================
PCB==> BQ2PM00 BQ2PM00
SEG=> SQ2RT @DEFINE Q2RT-RA-SUPPID
0001 UPDATE Q2RT-RA-SUPP-ID
****** ******** ************ BOTTOM OF DATA ***************

and in the proctran


MOVE CW-SUPP-ID TO Q2RT-RA-SUPP-ID
MOVE "UU" TO Q2RT-CCY-CDE
PERFORM U-100-UPDATE-SQ2RT.
Back to top
View user's profile Send private message
Bitneuker

CICS Moderator


Joined: 07 Nov 2005
Posts: 1105
Location: The Netherlands at Hole 19

PostPosted: Tue Feb 13, 2007 5:52 pm    Post subject:
Reply with quote

I am a bit lost here icon_rolleyes.gif Do I understand correct that after you supplied the SSA-information it works, and when you don't it abends? Please clearify. And what do you mean with:
Quote:
i got that by doing so if you have any other methods of doing it please kindly inform
Back to top
View user's profile Send private message
asifaddy
Warnings : 1

New User


Joined: 06 Feb 2007
Posts: 5
Location: Bangalore

PostPosted: Tue Feb 13, 2007 6:00 pm    Post subject: Re: How UPDATE is different then READ+REPL?
Reply with quote

hi


i mean if you have other way of doing the task post that.


according to me it has to work man i dont know y its not working.


i dont know y its not taking variables other than the key variable of the database i to confused ya let you know soon?
Back to top
View user's profile Send private message
Bitneuker

CICS Moderator


Joined: 07 Nov 2005
Posts: 1105
Location: The Netherlands at Hole 19

PostPosted: Tue Feb 13, 2007 6:13 pm    Post subject:
Reply with quote

The stuff you are using looks like a generator to me. It generates the DLI-calls for a GHU and a REPL. The regular calls are:
Code:

GHU
PCB
IO-AREA <-- SEGMENT FOUND
SSA-QUALIFIED

REPL
PCB
IO-AREA-MODIFIED <-- NEW DATA (KEY CHANGE NOT ALLOWED)
SSA-UNQUALIFIED


I don't know this generator (looks like home-built) but if you want this thing to operate correctly it has to generate the above calls. Did you check any available documentation? Are there any other applications using this thing? Is it proven technology? If you can't get this generator working find the author for more information/correction and last but not least: you can also code the DLI-calls by yourself.
Back to top
View user's profile Send private message
asifaddy
Warnings : 1

New User


Joined: 06 Feb 2007
Posts: 5
Location: Bangalore

PostPosted: Wed Feb 14, 2007 9:10 am    Post subject: Re: How UPDATE is different then READ+REPL?
Reply with quote

hi,

if we specify database key field while declaring in the data group it will generate the calls wat you have specified but if you dont and declaring the other variables it is not generating a ssa for GHU call that was the problem i dont know y its not working i only used for the first time i have given that to my senior team mates and presently they are using that and i dont have docs for that and yesterday i have given you the abended code right that was accured during replacing or updating i dnt get any info in dump master also if i get i will get back to u

[/quote]
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IMS DB/DC All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts IMS DB-How to update a record (a sing... Nic Clouston IMS DB/DC 9 Thu Mar 09, 2017 4:38 pm
No new posts -913/-911 Deadlock during UPDATE stat... NoSleep319 DB2 5 Fri Nov 18, 2016 12:37 am
No new posts How to update a portion of text in a ... Bill Woodger DFSORT/ICETOOL 25 Wed Nov 09, 2016 9:41 pm
No new posts Updating Cursor row withour using FOR... chandan.inst DB2 15 Tue Nov 08, 2016 11:17 am
No new posts CICS VSAM RLS READ akodakka CICS 3 Tue Oct 04, 2016 3:09 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us