<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Tahoma
}
--></style></head>
<body class='hmmessage'><div dir='ltr'>
<br>Hi ken.langendock<br><br><br><br>Your advice with the preupdate worked . I am officially recommending a pay raise for you.Thanks. <br><br><br><div><div id="SkyDrivePlaceholder"></div><hr id="stopSpelling">From: ken.langendock@rogers.com<br>To: cassinih@hotmail.com; powerh-l@lists.sowder.com<br>Subject: RE: [Bulk] FW: updating relational file<br>Date: Wed, 22 Aug 2012 17:29:47 -0400<br><br><style><!--
.ExternalClass .ecxshape
{;}
--></style><style><!--
.ExternalClass p.ecxMsoNormal, .ExternalClass li.ecxMsoNormal, .ExternalClass div.ecxMsoNormal
{margin-bottom:.0001pt;font-size:12.0pt;font-family:"Times New Roman","serif";}
.ExternalClass a:link, .ExternalClass span.ecxMsoHyperlink
{color:blue;text-decoration:underline;}
.ExternalClass a:visited, .ExternalClass span.ecxMsoHyperlinkFollowed
{color:purple;text-decoration:underline;}
.ExternalClass p
{margin-right:0cm;margin-left:0cm;font-size:12.0pt;font-family:"Times New Roman","serif";}
.ExternalClass p.ecxMsoAcetate, .ExternalClass li.ecxMsoAcetate, .ExternalClass div.ecxMsoAcetate
{margin-bottom:.0001pt;font-size:8.0pt;font-family:"Tahoma","sans-serif";}
.ExternalClass p.ecxecxmsonormal, .ExternalClass li.ecxecxmsonormal, .ExternalClass div.ecxecxmsonormal
{margin-right:0cm;margin-left:0cm;font-size:12.0pt;font-family:"Times New Roman","serif";}
.ExternalClass p.ecxecxmsochpdefault, .ExternalClass li.ecxecxmsochpdefault, .ExternalClass div.ecxecxmsochpdefault
{margin-right:0cm;margin-left:0cm;font-size:12.0pt;font-family:"Times New Roman","serif";}
.ExternalClass span.ecxecxmsohyperlink
{;}
.ExternalClass span.ecxecxmsohyperlinkfollowed
{;}
.ExternalClass span.ecxecxemailstyle18
{;}
.ExternalClass p.ecxecxmsonormal1, .ExternalClass li.ecxecxmsonormal1, .ExternalClass div.ecxecxmsonormal1
{margin-right:0cm;margin-bottom:0cm;margin-left:0cm;margin-bottom:.0001pt;font-size:12.0pt;font-family:"Times New Roman","serif";}
.ExternalClass span.ecxecxmsohyperlink1
{color:blue;text-decoration:underline;}
.ExternalClass span.ecxecxmsohyperlinkfollowed1
{color:purple;text-decoration:underline;}
.ExternalClass span.ecxecxemailstyle181
{font-family:"Calibri","sans-serif";color:#1F497D;}
.ExternalClass p.ecxecxmsochpdefault1, .ExternalClass li.ecxecxmsochpdefault1, .ExternalClass div.ecxecxmsochpdefault1
{margin-right:0cm;margin-left:0cm;font-size:10.0pt;font-family:"Times New Roman","serif";}
.ExternalClass span.ecxBalloonTextChar
{font-family:"Tahoma","sans-serif";}
.ExternalClass span.ecxEmailStyle30
{font-family:"Calibri","sans-serif";color:#1F497D;}
.ExternalClass .ecxMsoChpDefault
{font-size:10.0pt;}
@page WordSection1
{size:612.0pt 792.0pt;}
.ExternalClass div.ecxWordSection1
{page:WordSection1;}
--></style><div class="ecxWordSection1"><p class="ecxMsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Make sure you remove the LET statements for the FILE3, they are redundant if you are using the NEED ALL.</span></p><p class="ecxMsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span></p><p class="ecxMsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">As long as the record status changes via a LET somewhere in the procedures you do not need the NEED ALL. If you want a record created for every FILE2 regardless of the record status, then you either have to do a FOR X LET something or the record status will not change and the records will not be written out (as was the case you were having).</span></p><p class="ecxMsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span></p><p class="ecxMsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">You can always do this in the preupdate procedure instead of the LETS and the NEED ALL.</span></p><p class="ecxMsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Courier New";color:#1F497D">FOR MY_OR</span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Courier New";color:#1F497D"> BEGIN</span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Courier New";color:#1F497D"> IF NEWRECORD OF MY_OR AND &</span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Courier New";color:#1F497D"> NOT DELETEDRECORD OF MY_OR</span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Courier New";color:#1F497D"> THEN BEGIN</span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Courier New";color:#1F497D"> LET </span><span style="font-size:10.0pt;font-family:"Courier New"">EMPLOYER OF MY_OR SECONDARY = EMPLOYER OF FILE2</span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Courier New""> LET DATE OF MY_OR SECONDARY = DATE OF FILE2 </span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Courier New""> END</span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Courier New""> END</span></p><p class="ecxMsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span></p><p class="ecxMsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span></p><div><div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm"><p class="ecxMsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> powerh-l-bounces+ken.langendock=rogers.com@lists.sowder.com [mailto:powerh-l-bounces+ken.langendock=rogers.com@lists.sowder.com] <b>On Behalf Of </b>GREG GREG<br><b>Sent:</b> Wednesday, August 22, 2012 5:17 PM<br><b>To:</b> powerh-l@lists.sowder.com<br><b>Subject:</b> [Bulk] FW: updating relational file</span></p></div></div><p class="ecxMsoNormal"> </p><div><p class="ecxMsoNormal" style="margin-bottom:12.0pt"><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""><br><br>Hi,<br> The only problem now is that when trying to delete a record in the screen the error "Record has been changed since you found it." appears, which now means that <br> the record/s cannot be deleted.<br><br><br><br></span></p><div><div class="ecxMsoNormal" style="text-align:center" align="center"><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""><hr id="ecxstopSpelling" align="center" size="2" width="100%"></span></div><p class="ecxMsoNormal" style="margin-bottom:12.0pt"><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""><br>Subject: RE: updating relational file<br>Date: Wed, 22 Aug 2012 16:56:57 -0400</span></p><div><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">Hi ken.langendock<br><br>Your idea worked with the NEED ALL etc however the "Leave the preupdate and update procedures out." didn't. So by including the UPDATE procedure<br>every thing went through perfectly. All four cluster records updated simultaneously. Thanks a million.<br><br> </span></p><div><div class="ecxMsoNormal" style="text-align:center" align="center"><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""><hr id="ecxstopSpelling" align="center" size="2" width="100%"></span></div><p class="ecxMsoNormal" style="margin-bottom:12.0pt"><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> </span></p><div><p class="ecxMsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Do you always want to write out the oracle record?</span><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""></span></p><p class="ecxMsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">If you do, put a NEED ALL on the file statement.</span><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""></span></p><p class="ecxMsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""></span></p><p class="ecxMsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Your preupdate is initializing the fields but not on a FOR loop, so only the first record is being altered and written.</span><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""></span></p><p class="ecxMsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""></span></p><p class="ecxMsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Try this instead</span><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""></span></p><p class="ecxMsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"> </span><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""></span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Courier New"">SCREEN MYSCREEN RECEIVING FILE1 ON LINE 10 FOR 14 LINES<br><br>FILE FILE1 MASTER ; INDEXED<br>FILE FILE2 OCCURS 8 ;INDEXED<br>FILE FILE3 IN MY_ORACLE &</span><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""></span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Courier New""> ALIAS MY_OR SECONDARY &</span><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""></span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Courier New""> NOITEMS &</span><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""></span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Courier New""> OCCURS WITH FILE2 &</span><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""></span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Courier New""> NEED ALL</span><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""></span></p><p class="ecxMsoNormal" style="margin-bottom:12.0pt"><span style="font-size:10.0pt;font-family:"Courier New""> ACCESS VIA EMPLOYER,DATE &<br> USING EMPLOYER OF FILE2,DATE OF FILE2 </span><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""></span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Courier New""> ITEM EMPLOYER OF MY_OR SECONDARY INITIAL EMPLOYER OF FILE2 FIXED</span><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""></span></p><p class="ecxMsoNormal" style="margin-bottom:12.0pt"><span style="font-size:10.0pt;font-family:"Courier New""> ITEM DATE OF MY_OR SECONDARY INITIAL DATE OF FILE2 </span><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""></span></p><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> </span></p><p class="ecxMsoNormal" style="margin-bottom:12.0pt"><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">Leave the preupdate and update procedures out.</span></p><div><div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm"><p class="ecxMsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> <a href="mailto:powerh-l-bounces+ken.langendock=rogers.com@lists.sowder.com">powerh-l-bounces+ken.langendock=rogers.com@lists.sowder.com</a> [<a href="mailto:powerh-l-bounces+ken.langendock=rogers.com@lists.sowder.com">mailto:powerh-l-bounces+ken.langendock=rogers.com@lists.sowder.com</a>] <b>On Behalf Of </b>GREG GREG<br><b>Sent:</b> Wednesday, August 22, 2012 2:29 PM<br><b>To:</b> <a href="mailto:powerh-l@lists.sowder.com">powerh-l@lists.sowder.com</a><br><b>Subject:</b> [Bulk] Re updating relational file</span></p></div></div><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> </span></p><div><p class="ecxMsoNormal" style="margin-bottom:12.0pt"><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">Hi,<br><br> I am trying to update a relational file via an Indexed file , but only the first record is being updated in the relational file if two or more records are updated at once.<br> I have to updare the screen twice for the second record to be updated. Probably because the PUT verb updates one record at a time The Indexed file <br> contains an OCCURS 10 . Can anyone assists me. Thanks in advance.<br><br>eg: <br><br>SCREEN MYSCREEN RECEIVING FILE1 ON LINE 10 FOR 14 LINES<br><br>FILE FILE1 MASTER ; INDEXED<br>FILE FILE2 OCCURS 8 ;INDEXED<br>FILE FILE3 IN MY_ORACLE ALIAS MY_OR SECONDARY NOITEMS OCCURS WITH FILE2 ;MY_OR is the relational file<br> ACCESS VIA EMPLOYER,DATE &<br> USING EMPLOYER OF FILE2,DATE OF FILE2 <br><br><br><br>PROCEDURE PREUPDATE<br> BEGIN<br> LET EMPLOYER OF MY_OR = EMPLOYER OF FILE2<br> LET DATE OF MY_OR = DATE OF FILE2<br><br>END<br><br><br>PROCEDURE UPDATE<br> BEGIN<br> Put FILE1<br> For FILE2<br> Begin<br> Put FILE2<br> Put FILE1<br> PUT MY_OR <br> End<br> End</span></p></div></div><p class="ecxMsoNormal"><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""><br>-- = = = = = = = = = = = = = = = = = = = = = = = = = = = = Mailing list: <a href="mailto:powerh-l@lists.sowder.com">powerh-l@lists.sowder.com</a> Subscribe: 'subscribe' in message body to <a href="mailto:powerh-l-request@lists.sowder.com">powerh-l-request@lists.sowder.com</a> Unsubscribe: 'unsubscribe <password>' in message body to <a href="mailto:powerh-l-request@lists.sowder.com">powerh-l-request@lists.sowder.com</a> <a href="http://lists.sowder.com/mailman/listinfo/powerh-l" target="_blank">http://lists.sowder.com/mailman/listinfo/powerh-l</a> This list is closed, thus to post to the list you must be a subscriber. Add 'site:lists.sowder.com powerh-l' to your search terms to search the list archive at Google.</span></p></div></div></div></div></div><br>--
= = = = = = = = = = = = = = = = = = = = = = = = = = = =
Mailing list: powerh-l@lists.sowder.com
Subscribe: 'subscribe' in message body to powerh-l-request@lists.sowder.com
Unsubscribe: 'unsubscribe <password>' in message body to powerh-l-request@lists.sowder.com
http://lists.sowder.com/mailman/listinfo/powerh-l
This list is closed, thus to post to the list you must be a subscriber.
Add 'site:lists.sowder.com powerh-l' to your search terms to search the list archive at Google.</div>                                            </div></body>
</html>