<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=utf-8"><meta name=Generator content="Microsoft Word 15 (filtered medium)"><!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:"Lucida Console";
        panose-1:2 11 6 9 4 5 4 2 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
p.msonormal0, li.msonormal0, div.msonormal0
        {mso-style-name:msonormal;
        mso-margin-top-alt:auto;
        margin-right:0in;
        mso-margin-bottom-alt:auto;
        margin-left:0in;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
span.EmailStyle18
        {mso-style-type:personal;
        font-family:"Times New Roman",serif;
        color:windowtext;}
span.EmailStyle19
        {mso-style-type:personal;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
span.EmailStyle20
        {mso-style-type:personal-reply;
        font-family:"Times New Roman",serif;
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link="#0563C1" vlink="#954F72"><div class=WordSection1><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'>Hi Jocelyn,<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'>We are now on Basis 7.5, SAP_APPL 619.  We were on Basis 7.40 a year ago.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'>I doubt it’s the migration to HANA that caused the issue.  <o:p></o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'>I’ve looked at OSS Note 727704 and see that it wanted an additional public method in CL_SWF_RUN_WIM_LOCAL<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:10.5pt;font-family:"Lucida Console";color:#333333;background:#FAFAFA'>Note that you must create an additional public method in the CL_SWF_RUN_WIM_LOCAL class.</span><span style='font-size:10.5pt;font-family:"Lucida Console";color:#333333'><br><span style='background:#FAFAFA'>Name: OBJKEY_CHANGE</span><br><span style='background:#FAFAFA'>Import parameter:</span><br><span style='background:#FAFAFA'>IM_LOGSYS TYPE LOGSYS OPTIONAL</span><br><span style='background:#FAFAFA'>IM_OBJTYPE TYPE SWO_OBJTYP</span><br><span style='background:#FAFAFA'>IM_OBJKEY_OLD TYPE SWO_TYPEID</span><br><span style='background:#FAFAFA'>IM_OBJKEY_NEW TYPE SWO_TYPEID</span><br><span style='background:#FAFAFA'>Exceptions:</span><br><span style='background:#FAFAFA'>CX_SWF_RUN_WIM<o:p></o:p></span></span></p><p class=MsoNormal><span style='font-size:10.5pt;font-family:"Lucida Console";color:#333333;background:#FAFAFA'>  <o:p></o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'>But that note is not supposed to be relevant to our release – and we’ve never had the method OBJKEY_CHANGE in CL_SWF_RUN_WIM_LOCAL. <o:p></o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'>OSS Note 87700 is not valid for our release, nor is 87768.  <o:p></o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'>What is interesting here is that the task that does the update does not get the new FY invoice in the container, but the wait steps (wait for Invoice Posted, wait for Invoice Deleted) DO get the new value in their container. <o:p></o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><img width=624 height=218 style='width:6.5in;height:2.275in' id="Picture_x0020_9" src="cid:image001.png@01D3E85D.01843340"><span style='font-size:12.0pt;font-family:"Times New Roman",serif'><o:p></o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'>And the main difference between the two workflows *<b>besides one that works, and one that doesn’t</b>* is that the one that doesn’t is updating the Invoice Header Text (RBKP-SGTXT) while the one that does work is updating line item text (RSEG-SGTXT)<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'>AND… dev systems are down for patching so that’s all I can find out right now!<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'>Cheers!<br>Sue<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'><o:p>&nbsp;</o:p></span></p><div><div style='border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in'><p class=MsoNormal><span style='font-size:12.0pt;font-family:"Times New Roman",serif'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><b>From:</b> sap-wug-bounces@mit.edu &lt;sap-wug-bounces@mit.edu&gt; <b>On Behalf Of </b>Dart, Jocelyn<br><b>Sent:</b> Wednesday, May 9, 2018 8:00 PM<br><b>To:</b> SAP Workflow Users' Group &lt;sap-wug@mit.edu&gt;<br><b>Subject:</b> Re: Old one (BUS2081/cross fiscal years)<o:p></o:p></p></div></div><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal><span lang=EN-GB>Hi Sue, <o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB>Moving to HEC shouldn’t change anything… unless there were transports involved and some macro definitions were lost? &nbsp;<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span lang=EN-GB>Did you also change NetWeaver releases at the same time? I recall some mention of HANA.. ? <o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span lang=EN-GB>Rgds<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB>Jocelyn <o:p></o:p></span></p><p class=MsoNormal><span lang=EN-GB><o:p>&nbsp;</o:p></span></p><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'><p class=MsoNormal><b><span lang=EN-AU style='font-size:12.0pt;color:black'>From: </span></b><span lang=EN-AU style='font-size:12.0pt;color:black'>&lt;<a href="mailto:sap-wug-bounces@mit.edu">sap-wug-bounces@mit.edu</a>&gt; on behalf of Susan Keohan &lt;<a href="mailto:keohan@ll.mit.edu">keohan@ll.mit.edu</a>&gt;<br><b>Reply-To: </b>SAP Group &lt;<a href="mailto:sap-wug@mit.edu">sap-wug@mit.edu</a>&gt;<br><b>Date: </b>Thursday, 10 May 2018 at 3:38 am<br><b>To: </b>SAP Group &lt;<a href="mailto:sap-wug@mit.edu">sap-wug@mit.edu</a>&gt;<br><b>Subject: </b>Old one (BUS2081/cross fiscal years)<o:p></o:p></span></p></div><div><p class=MsoNormal><span lang=EN-AU><o:p>&nbsp;</o:p></span></p></div><p class=MsoNormal><a name="_MailOriginalBody"><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif'>Hi Wuggers,</span></a><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif'>&nbsp;</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif'>I have two custom workflows that send invoices out for approvals.&nbsp; When these workflows are started, they update a text field on the invoice using BAPI_INCOMINGINVOICE_GETDETAIL and BAPI_INCOMINGINVOICE_CHANGE.&nbsp; &nbsp;The same calls are done to update the invoice again after approval (updating only the text field).</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif'>&nbsp;</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif'>These two workflows, BTW, have been running for 14 years.&nbsp; The method to update the invoice was updated in 2008 when the above BAPIs were released for customer use.</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif'>&nbsp;</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif'>At some point, we recognized that we needed to handle invoices that are in process by workflow when the FY changed.&nbsp; No problem!&nbsp; The BAPI_INCOMINGINVOICE_CHANGE nicely returns <b>invoicedocnumber_new</b> and <b>fiscalyear_new</b> if the old invoice was deleted and a new one created in the background.&nbsp; I capture those new values and pass them back into the object method, where I check for a new invoice/fiscal year and execute some macros (remember them???)</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif'>&nbsp;</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal style='text-autospace:none'><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:9.5pt;font-family:"Courier New";color:black'>IF NOT new_invoice IS INITIAL.&nbsp; &quot;We have a new invoice doc</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal style='text-autospace:none'><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:9.5pt;font-family:"Courier New";color:black'>&nbsp; CONCATENATE new_invoice new_year INTO new_key.</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal style='text-autospace:none'><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:9.5pt;font-family:"Courier New";color:black'>&nbsp; swc_free_object self.</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal style='text-autospace:none'><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:9.5pt;font-family:"Courier New";color:black'>&nbsp; swc_set_objectkey new_key.</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal style='text-autospace:none'><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:9.5pt;font-family:"Courier New";color:blue'>* new object reference</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal style='text-autospace:none'><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:9.5pt;font-family:"Courier New";color:black'>&nbsp; swc_create_object self 'BUS2081' new_key.</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:9.5pt;font-family:"Courier New";color:black'>&nbsp; swc_refresh_object self.</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:9.5pt;font-family:"Courier New";color:black'>&nbsp;</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:9.5pt;font-family:"Courier New";color:black'>&nbsp;</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif;color:black'>This methodology worked ~most~ of the time.&nbsp; Once in a while, one of the workflows would fail on subsequent steps because the new invoice doc number and fiscal year somehow were not returned in the container.</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif;color:black'>Since it didn’t cause anyone except the lowly WF Admin any pain, nobody saw the need to change it!&nbsp; (I can hear Jocelyn talking to me about this…)</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif;color:black'>&nbsp;</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif;color:black'>Now we’ve completed an upgrade to HEC, and noticed some quirks… BAPI_INCOMINGINVOICE_GETDETAIL doesn’t always return the accountingdata sorted by serial number, which makes the BAPI_INCOMINGINVOICE_CHANGE throw up (error M8 367).&nbsp; I’ve added a sort on accountingdata between them, and that problem goes away…</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif;color:black'>&nbsp;</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif;color:black'>But now the WFs are all erroring out on Fiscal Year changes – in QA, and only because I made people test ‘pre-HANA’ invoices (smiley face).&nbsp;&nbsp; When I debug the method in the BOR, the BAPI still returns the <b>invoicedocnumber_new</b> and <b>fiscalyear_new</b>, but my trusty macros are not updating the main object of the WF.</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif;color:black'>&nbsp;</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif;color:black'>&nbsp;</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif'>Sure would appreciate any insights you can share.&nbsp; And bear in mind, this stuff is O-L-D…</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif'>Thanks,<br>Sue</span></span><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU><o:p></o:p></span></span></p><p class=MsoNormal><span style='mso-bookmark:_MailOriginalBody'><span lang=EN-AU style='font-size:12.0pt;font-family:"Times New Roman",serif'>&nbsp;</span></span><span style='mso-bookmark:_MailOriginalBody'></span><span lang=EN-AU><o:p></o:p></span></p></div></body></html>