sexta-feira, 1 de maio de 2020

Easy maintanance of company code parameters

Company code is the basic organizational unit in SAP from which many of the settings depend. Besides all of the possible standard customizing there will be always a question coming if something can be made default per company – like MIRO document type. If there is no suitable standard customizing you look for alternatives and you find an userexit/ BADI / BTE or any other option available in ABAP enhancement framework.
Time to think about the design now – certainly you would like to avoid hardcoding entries so it should be flexible enough to add an entry pro company.
Here normally the thinking drifts towards a custom table – either existing one for customer-specific parameters or a new one. That is one feasible solution but how about settings which you can make without any new table/ maintenance of custom tables?

Company code additional parameters

In company code parameters (transaction OBY6 ) there is a button with ‘additional data’:
Clicking on it brings you to list of parameters that can be maintained with either meaningful values (like local Tax Number in Germany) or just activation of functions (like Detail Tax Entry with MIRO).
What if you could maintain the entries here – that would also make it possible to keep all the defaults or simple company-dependent customizing parameters in one place.

How to add own parameter

Fortunately there is a simple way to do archive that. Start table maintenance transaction SM30 and choose view V_T001I (it is also available in couple of IMG points):
Voila – you can now define new parameter and even make it country dependent.
Let’s say that we want to maintain the parameter for default document type for MIRO and also a second one with Polish Local Tax Number – that one should be only available for companies from Poland.
Save the settings now and that is it – you can now see the parameters in OBY6.
German company in OBY6:
Polish company:
So the entries work as desired and are limited to country where it is needed.

How to use in custom code

Now the specification to developer – how can you can access the parameter in ABAP. All the values maintained are stored in table T001Z:
To access the data (single or multilple entries) best option will be to use FM READ_ADD_COMPANY_CODE_INFO with parameters like below:
DATA: l_s_company_parameter_value TYPE t001z.
DATA: l_v_company_code TYPE bukrs.
DATA: l_v_parameter_id TYPE party.

CALL FUNCTION 'READ_ADD_COMPANY_CODE_INFO'
  EXPORTING
    ic_bukrs  = l_v_company_code "here your company code
    ic_party  = l_v_parameter_id "parameter id same which was customized in V_T001I
  IMPORTING
    es_t001z  = l_s_company_parameter_value "parameter value is returned in field PAVAL
  EXCEPTIONS
    not_found = 1
    OTHERS    = 2.
IF sy-subrc NE 0.

ENDIF.

That is it – simple, is it not?
You can use it for any additional data which is not available in standard (like local tax numbers which should be printed on sales invoice).

Marek Turczyński

How to prevent the sales(SD) document to post CO-PA document ?

Overview


Let´s create some situation in this blog post to have a better understanding about the content of this post.
In many businesses that run the SAP ECC system, the company sales and profitability results are analyzed by the CO-PA: Controlling – Profitability Analysis. CO-PA Documents are created during the sales processing until Billing.
I am pretty sure that many business which have this system scenario, don´t use the Sales and Distribution processing only for Profitable Sales. That means, that are some SD(outbound) scenarios which will not affect the company P&L, here we have some sales process that should not impact the company P&L:
  • Free Shipping
  • Test Consignment with or without Return
  • Donations
  • Scrapping
and… many others that are not related to the company profitable business.
Usually, the cost of these sales processing are usually absorved/consumed by the company.

Prevention of Update


In a scenario like this one how to prevent the sales document to post CO-PA document ?
A long time ago, the SAP delivers an enhancement for actual data update in CO-PA. You can check OSS note for some SAP Details 397298 – COPA0005: Prevention of update does not work
The COPA0005 – Enhancement for actual data update (CO-PA) will help us to achieve this need.
This enhancement has a component called EXIT_SAPLKEII_001 – User Exit for Processing AC-Document: Line Item Structure:

This EXIT has the following ABAP Code Function Structure:
FUNCTION EXIT_SAPLKEII_001.
*"----------------------------------------------------------------------
*"*"Lokale Schnittstelle:
*"       IMPORTING
*"             VALUE(I_ERKRS) LIKE  TKEB-ERKRS
*"             VALUE(I_ITEM)
*"       EXPORTING
*"             VALUE(E_ITEM)
*"             VALUE(E_INIT)
*"       TABLES
*"              T_ACCHD STRUCTURE  ACCHD
*"              T_ACCIT STRUCTURE  ACCIT
*"              T_ACCCR STRUCTURE  ACCCR
*"              T_ACCIT_PA STRUCTURE  ACCIT_PA
*"              T_ACCCR_PA STRUCTURE  ACCCR_PA
*"----------------------------------------------------------------------


INCLUDE ZXKKEU07 .


ENDFUNCTION.

They delivered the E_INIT Exporting parameter in this enhacement function and this indicator when set TRUE will avoid the creation of the CO-PA documents.
Usually the Sales Processes have different document types for each outbound sales or non-sales processing so we set a dynamic code in this enhancement to prevent the CO-PA document creation based on the Sales Document Type.
IF >>> your condition to prevent or not the COPA.
  e_init = abap_true. "By setting e_init true, the COPA document will not be created.
else.
  e_init = abap_false.
ENDIF.

I think this tip could be helpfull you guys that are working with sales processes that should not impact the profitability analysis of the company.
Best regards,
Gabriel Coleti

Transitioning from SAP GUI to SAP Fiori: A friendly user SAP Guide – Part Three

This is the final blog post under the series Transitioning from SAP GUI to SAP Fiori:  A friendly user SAP Guide and in this one I will be covering the below topics.
  • How do I know what role grants me access to the App?
  • How can I know the functionality behind an App?
The above questions are key to being able to understand the App functionality and for being able to execute them successfully.

How do I know what role grants access to the App

To be able to have access to the App you need to have the role in your user profile.
  1. Open Search on the SAP Fiori Apps library
  2. Type in the search box the name of the SAP GUI transaction code and click <ENTER>
  3. The tool will display all applications that match with the key word that you used in your search.
  4. Select the entry that you want to see to open the details.
In this example, I am choosing the Post G/L Document / Post General Journal Entries App because it is the newest and is has been improved in the latest release.
TIP!  Be aware that SAP Fiori apps does not have a 1 to 1 replacements of SAP GUI transaction. Read the App documentation carefully to be sure that is what you are looking. For more details please see https://blogs.sap.com/2018/04/20/fiori-for-s4hana-top-10-myths-misconceptions-to-avoid/.
5. Select the Implementation Information tab
6. Select the Configuration menu
7. Scroll down until you find the Business Role(s) and copy the role name
8. Add the role into your user profile in SAP GUI and click <SAVE>
TIP! This activity is usually done with transaction SU01 or PFCG. If you do not have authorization your will need to talk to your system administrator for help.
9. Log on to SAP Fiori and the App should be available.
Remember you may need to use the Fiori Search or the App Finder to find the app – not every app appears on the Home PageTIP! You may also need to clear your web browser cache if you were already logged on

 How can I know the functionality behind an App?

  1. Execute steps 1-3 from previous section.
  2. Select the Product Features Tab and scroll down until you find Read More App Documentation.TIP!  You can see a Product Feature summarized version of the App functionality in this tab.
  3. Click the App Documentation link.
The link will open the SAP Help Portal and in here you can find detailed information about the App, like Use, Key features, Navigation Targets, etc
  1. Some apps provide links to additional details or demo videos to help you understand the app – it’s worth checking for these as they are usually very useful.   Go back to the App Details>Product Features screen and scroll down until you find Further assets: P1: Post General Journal Entries (SAP S/4 Hana On Premise)
  1. Click the P1: Post General Journal Entries (SAP S/4 Hana On Premise)
The link will open a short presentation with slides that show a detailed example on how to use the App.TIP!  This option is not available for all the Apps.
This blog is a compilation of my own journey and experiences and is not intended to be the only or best way to do it.
In summary, you can use these guides to help you to transition to SAP Fiori and hopefully find answers to the most common user questions.  As the old saying goes “Practice makes perfect” so I invite you to practice and be patient with yourself because learning something new takes some time. But when you least expect it you will be a pro in SAP Fiori. Good luck, the exciting world of SAP Fiori awaits you!!
_ Brought to you by the S/4HANA RIG_

Payment Formats in SAP

In SAP we are simplifying your communication with banks using SAP S/4HANA and SAP S/4HANA Cloud by bringing you solutions regarding Payment Formats. It is my pleasure to introduce you to the new Payment Formats Blog. In this blog, We will be posting articles about the functionality of payment formats and tools associated with them. I’d like to be introducing newly delivered formats as well as enhancements and improvements of the tools used for their creations and modifications. This blog is not a replacement of the documentation, it is more like its extension. Articles will be about new functionality, which we think may be interesting and could help you with your communication with banks. I will post new articles on a regular basis, so you can always look forward to new content. The blog focuses on describing the work of teams developing new payment formats (outgoing and incoming) for S/4HANA and SAP S/4HANA Cloud for tools DMEE, DMEEX, and Fiori Map Payment Format Data. Check out all of the articles posted regarding Payment Formats and their tools.

General articles

Outgoing Formats

Payment Medium Formats

SAP S/4HANA Cloud
  1. Create, Copy, Delete & Release in Map Payment Format Data
  2. Create, Copy & Delete Payment Medium Format
  3. Linking Payment Medium Format to a Payment Method
  4. Create Selection Variants for Payment Medium Formats
SAP S/4HANA

Map Payment Format Data

SAP S/4HANA Cloud

DMEEX

SAP S/4HANA
Requires SAP S/4HANA 1709 release or newer

Incoming Formats

Don’t hesitate to share your thoughts, ideas or questions regarding Payment Formats in the comment section below. We will do our best to answer them all swiftly. Any suggestions regarding what should the next topic be about are very welcome.

Receipt & Reversal of Handling Units from Production with Restricted Batch Using Radio Frequency

Receipt of Handling Units from Production( Document Type INBM)

This blog will explain how from RF receipt of Hus and its reversal can be conducted for Advance Production Integration.
Assumption:
  • All mandatory configuration of Advance production integration
  • Master data is set up
  • Batch management is set up
  • RFUI is set up
The receipt of HUs from Production line using RF is a process by which goods receipt process at the end of production line is automated.
In the below example, points will be discussed
  •  Generation of restricted batch with Production date and BBD

  • Generation of Hus with RF

  • Generation of Inbound delivery in S4 Embedded EWM( No Expected Goods receipt)

  • Create & Confirm Warehouse Task from RF

  • Create a manufacturing order in ERP with goods receipt in EWM managed sloc. The product is batch managed with batch status management is active both in ERP and EWM. The initial status of batches is ”Restricted” is activated in OCHA and in EWM  warehouse task creation with ”Restricted Status” is configured at warehouse process type level.

  •  Logon to RFUI.
  • Scan the product
  • Create the HU( Receiving 1 HU from production )
  • Create Inbound delivery from RFUI.

  • Restricted Batch with Production date and SLED is generated. Restricted batch in EWM is marked as X.

  • Create Warehouse Task



Reversal of Handling units. 
If below condition is met, HU cannot be reversed.
  • The putaway of the HU to the final bin is already complete.
  • The HU is currently not in a bin and is not a planned HU.
  • The HU has multiple stock items in it, or the stock is not directly in the HU.
  • The stock in the HU refers to a quality inspection document that is released and cannot be canceled.
So, only those HUs can be reversed whose HU WT is not confirmed.
Try to reverse the above HU 8001000082.
— >Business context  RVS Reverse Receipt, in Customizing for Extended Warehouse Management under Start of the navigation path Cross-Process Settings Next navigation step Exception Handling Next navigation step Define Exception Codes End of the navigation path. The exception code must have an internal process code and a process code to reduce inbound delivery quantities upon reversal of the HU. DIFR



  • Process code has reduced the inbound delivery

  • Business Context RVS ,Exception code DIFF and the corresponding Process code I001 initiate the process of HU reversal by adjusting the Warehouse request.

  • Inbound delivery has reference of Process code


  • Try to conduct reversal of HU which is already Putawayed. System will not allow to do reversal of HUS.



  • Now, finally do the whole process again to conduct put-away.


  • New IBD is created.

  • Conduct WT creation and Confirmation

  • Check the delivery status now

  • Check Manufacturing Order in ERP

  • Check the Stock status with Batch Status in ERP and In EWM


  • EWM monitor Stock


Hence the blog end. Appreciate your suggestions and improvements to make this blog more useful


Best regards
Shailesh Mishra