Old one (BUS2081/cross fiscal years)

Keohan, Susan - 1140 - MITLL keohan at ll.mit.edu
Thu May 10 12:47:09 EDT 2018


Hi Jocelyn,

We are now on Basis 7.5, SAP_APPL 619.  We were on Basis 7.40 a year ago.

I doubt it’s the migration to HANA that caused the issue.  

 

I’ve looked at OSS Note 727704 and see that it wanted an additional public method in CL_SWF_RUN_WIM_LOCAL

Note that you must create an additional public method in the CL_SWF_RUN_WIM_LOCAL class.
Name: OBJKEY_CHANGE
Import parameter:
IM_LOGSYS TYPE LOGSYS OPTIONAL
IM_OBJTYPE TYPE SWO_OBJTYP
IM_OBJKEY_OLD TYPE SWO_TYPEID
IM_OBJKEY_NEW TYPE SWO_TYPEID
Exceptions:
CX_SWF_RUN_WIM

  

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. 

OSS Note 87700 is not valid for our release, nor is 87768.  

 

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. 

 



 

And the main difference between the two workflows *besides one that works, and one that doesn’t* 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)

 

 

AND… dev systems are down for patching so that’s all I can find out right now!

 

Cheers!
Sue

 

 

From: sap-wug-bounces at mit.edu <sap-wug-bounces at mit.edu> On Behalf Of Dart, Jocelyn
Sent: Wednesday, May 9, 2018 8:00 PM
To: SAP Workflow Users' Group <sap-wug at mit.edu>
Subject: Re: Old one (BUS2081/cross fiscal years)

 

Hi Sue, 

Moving to HEC shouldn’t change anything… unless there were transports involved and some macro definitions were lost?  

 

Did you also change NetWeaver releases at the same time? I recall some mention of HANA.. ? 

 

Rgds

Jocelyn 

 

From: <sap-wug-bounces at mit.edu <mailto:sap-wug-bounces at mit.edu> > on behalf of Susan Keohan <keohan at ll.mit.edu <mailto:keohan at ll.mit.edu> >
Reply-To: SAP Group <sap-wug at mit.edu <mailto:sap-wug at mit.edu> >
Date: Thursday, 10 May 2018 at 3:38 am
To: SAP Group <sap-wug at mit.edu <mailto:sap-wug at mit.edu> >
Subject: Old one (BUS2081/cross fiscal years)

 

Hi Wuggers,

 

I have two custom workflows that send invoices out for approvals.  When these workflows are started, they update a text field on the invoice using BAPI_INCOMINGINVOICE_GETDETAIL and BAPI_INCOMINGINVOICE_CHANGE.   The same calls are done to update the invoice again after approval (updating only the text field).

 

These two workflows, BTW, have been running for 14 years.  The method to update the invoice was updated in 2008 when the above BAPIs were released for customer use.

 

At some point, we recognized that we needed to handle invoices that are in process by workflow when the FY changed.  No problem!  The BAPI_INCOMINGINVOICE_CHANGE nicely returns invoicedocnumber_new and fiscalyear_new if the old invoice was deleted and a new one created in the background.  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???)

 

IF NOT new_invoice IS INITIAL.  "We have a new invoice doc

  CONCATENATE new_invoice new_year INTO new_key.

  swc_free_object self.

  swc_set_objectkey new_key.

* new object reference

  swc_create_object self 'BUS2081' new_key.

  swc_refresh_object self.

 

 

This methodology worked ~most~ of the time.  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.

Since it didn’t cause anyone except the lowly WF Admin any pain, nobody saw the need to change it!  (I can hear Jocelyn talking to me about this…)

 

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).  I’ve added a sort on accountingdata between them, and that problem goes away…

 

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).   When I debug the method in the BOR, the BAPI still returns the invoicedocnumber_new and fiscalyear_new, but my trusty macros are not updating the main object of the WF.

 

 

Sure would appreciate any insights you can share.  And bear in mind, this stuff is O-L-D…

Thanks,
Sue

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.mit.edu/pipermail/sap-wug/attachments/20180510/87d2f765/attachment-0001.html
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: image/png
Size: 207559 bytes
Desc: not available
Url : http://mailman.mit.edu/pipermail/sap-wug/attachments/20180510/87d2f765/attachment-0001.png
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5465 bytes
Desc: not available
Url : http://mailman.mit.edu/pipermail/sap-wug/attachments/20180510/87d2f765/attachment-0001.bin


More information about the SAP-WUG mailing list