Skip to Content

Hello SAPers!

Here is an article that provides an overview of transaction S_ALR_87012357 – Advance Return for Tax on Sales/Pur. On the first glance, this is a standard and well-known transaction, but in my opinion there are a lot of aspects about it, which are not straight forward and deserve a good explanation. Besides, I plan a couple more posts on taxation-related issues, which would cover more technical issues, so I decided that this most might be considered as a good starting point.

You can also find this blog post on Medium platform under the following link.

This article will cover the topics ranging from selection screen options to the procedural steps involved into generation of XML-based tax reports directly out of SAP. From this point of view, it would be a good starting point for somebody, who just started exploring taxation topics in SAP. But along the way, I’ll try to add some specific technical details and explanations that will give you a better understanding of the transaction even if you already have some experience with it.

1.1. Selection screen of the report

Selection screen of the report consists of several parts, purpose of some fields is more or less straight forward, whereas usage of some fields is not exactly clear. Let’s explore selection screen options section by section. First part of selection screen features general select options, which can be used to indicate your reporting entity (i.e. company code) and the reporting period (fiscal year / posting dates etc.). Note, in most cases company code is a required entry field, but if you use reporting that is based on tax groups you can leave this field empty.

Section “Further selections” contains a lot of options that enable flexible selection of documents for reporting purposes. Mostly used selection options are: tax reporting date, tax codes, transaction (e.g. MWS, VST, ESA, ESE etc.), special GL indicator (e.g. A for down-payments), GL accounts etc. Apart from these mostly transaction-related options, there is one additional field “Taxes on sales/purchases group”. Here you can indicate tax group – special organizational entity which can be used for tax reporting purposes.

Next section (i.e. “Tax payable posting“) is used to indicate parameters controlling the posting of tax payable. In short, program RFUMSV00 (i.e. program behind this transaction) can be used not only for reporting purposes, but also to post the amount of tax payable to special “netting account”. Posting amount for this purpose will be automatically calculated as a difference between total output tax (i.e. tax liability) and total input tax (i.e. tax credit). If you want to use this option, please do the following:

  • Select check-box “Batch input session required” – program run will generate a batch input with name indicated in field “Session name”, which can be processed either immediately (if respective check-box is activated) or in post-processing mode in transaction SM35;
  • Document type / posting date for tax payable as well as due date, indicating when the amount of tax should be paid. Indication of due date is especially useful, when you have maintained vendor account as account to which tax payable will be posted (this option is analyzed in a separate post “Tax payable posting to vendor account“).

Please note, to run the report in this mode, you should have authorization for t-code FB41 which is used to re-post tax amounts.

Output control” section of selection screen can be used to control how data is displayed in report mode. Probably the most useful feature in this section is related to display of address data of customers / vendors. By selecting check-box “Read address data” you make sure that report will also display address information of company’s business partners. You can also control which version of address data will be displayed. To do that, you should indicate reference to international address version in respective field (e.g. 8 – stands for Ukrainian address version, R – for Russian, I – international). If this field is empty, the system will display address data from standard address version.

Section “Output lists” also contains control parameters, which define which parts of the report will be displayed. In short – you can choose between line items option (display of all tax-relevant line items) and between totals option (aggregated data on output / input tax).

You can also configure the layout of each report by clicking “Configure” button. The system will navigate you to a separate screen with default report layout for each output list. You can configure the layout of report to suite your purposes and save it into a variant (e.g. ZTEST_OUT, ZTEST_IN). Report variants can then be indicated on selection screen of report.

Useful feature from this section is reporting on tax differences (check box “Tax difference: line items”). If you run the program with this option, it will generate a report on all line items, where the system expects postings to tax-related GL accounts (based upon tax codes’ settings), but these postings are missing in the document (see example below). This might be the case, when you use some external applications which post automatically to SAP.

The last section “Posting parameters” is probably the most important for generation of reporting. You have a couple of radio buttons, which control how the program will execute. First option (Do not update documents) is straight forward. If you run the report in update mode (Update documents: Update run), the program will update each document with date and time, when report was executed (technically speaking changes will be updated into fields BSET-STMDT and BSET-STMTI for date / time respectively). Usage of this option is supposed to prevent including of the same document twice into different reports, which are supposed to be submitted during one period. Update mode with update “Test run” will also update documents, but only those which were not updated previously. Usage of update option implies additional performance issues.

“Form printout” options from this section are also widely used for reporting purposes. Essentially, when you run the report, the program calculates in background different subtotals, which are transactions- and tax-codes-based (i.e. linked to transaction keys MWS, VST, ESA, ESE etc.). If you select check-box “Prepare printing of forms”, the program will save these subtotals into table UMSV with references to program run date and run ID (see example below, note in my test system I use custom transaction keys UAM, UAV instead of standard keys). This aggregated data can be used by other programs to print tax returns and / or generate XML-reports. These “other programs” are mostly localization specific programs. Intersections between standard and localization based tools is SAP is interesting of itself and also deserves to be explored in a separate post.

Finally, if you want to generate DME (i.e. data medium exchange) file based on report run, you should select appropriate check-box. You should also indicate format tree which was defined in transaction DMEE and file name. Depending on format tree settings, you can generate either flat text files or hierarchical XML-files for your tax reports.

Please note! When you indicate file name – you should only indicate file name + extension, without any path to a folder on your PC. There is a separate procedure on how to download the file to PC, which will be covered a bit later.

Upon click on “Add. Parameters” button, a new selection screen will be opened enabling you to enter some data, which then can be used as a source of data for DME engine.

Please note! Button “Add. Parameters” is an optional button. It will be displayed only in those case, when you have specified format-specific structure in the settings of DMEE tree. Consequently, the list of fields on selection screen of the program will depend on the structure. In this case, I’ve used standard structure for DMEE tree FIPL_S_FRMTS_DMEE which was delivered by SAP for EC Sales for Poland. But you can use custom structures as well.

1.2. Display of report results

Run, the report. You will get the following typical reports on tax-related lines for output / input tax respectively.

An important advantage of this report over line items reports (FBL3N / FAGLL03) is that this report is more comprehensive. Line items reports on tax-related GL accounts, will display only those documents, which have postings to these accounts i.e. when tax rate is not zero. From legislation perspective certain operations, might be taxable at 0%, but that doesn’t mean that they are not relevant to VAT and should not be considered in reporting. Technically speaking all lines that are stored in table BSEG, can be displayed in line items reports. On the other hand, RFUMSV00 report is based on values from table BSET, which stores all tax-relevant line items. Thus, if some operation involved tax base of 1000 UAH and was taxable at 0%, the table will store this info and you would be able to see it in report (see example in screenshot above based on input tax code P0).

But there is also an important disadvantage. If you try to save the report into spreadsheet (see screenshot below), you will notice this option is disabled. Nowadays it’s a kind of unheard of to be unable to save a report into spreadsheet for deeper analysis.

Fortunately, SAP came out with a solution quite recently (November 2016). Please check out OSS-note 2388449 (RFUMSV00 list: Download as Spreadsheet). This note contains technical explanation on why this option was restricted originally. After installation of this note, you would be able to save report into spreadsheet, but only if you selected one output list (i.e. in section “Output lists”). Note, this feature won’t be available only for output list “Balance of all company codes”.

1.3.  Downloading of report results

After you’ve executed report the system will generate DME file. Appropriated information will be displayed at the bottom of the report. Example of typical message can be found below.

There is a separate standard program RFASLDPC to download DME file to PC, but it has no standard transaction code assigned to it. You can consider creation of custom transaction code or decided to launch it via transactions SA38 / SE38.

Indicate the following details on the selection scree of the program:

  • Source file – name of the file as specified previously during execution of program RFUMSV00;
  • File type should be set as “**”, which indicates it as a generic DME format;
  • Select check-box “Copy source file” (recommended option);
  • In the section “Target file” you should specify the path name to a file on your PC;
  • You can also indicate a specific code page, which might be a prerequisite for correct display of local characters (e.g. ü, ä etc.).

After filling of selection screen is completed, run the report to download the file to PC.

Well… that’s it. If you’ve reached this part of the post, I hope it wasn’t too boring and you have learn something useful. I’m looking forward to your comments and remarks.

Best regards, 

Bohdan Petrushchak

P.S. Disclaimer.

All sensitive information (company names, tax numbers etc.) used in this example is invented by my own. If there is some coincidence with real-life companies, it is a purely accidental one.

 

 

To report this post you need to login first.

15 Comments

You must be Logged on to comment or reply to a post.

  1. Former Member

    Hello,

    Thank you for this very clear and appreciate document. One question : as SAP recommends that tax accounts are not managed on an open item basis, how do you make a link between the orignal tax items and the tax return posting ?

    Thank you.

    Julien D.

    (0) 
    1. Bohdan Petrushchak Post author

      Hi Julien,

       

      Thanks for your feedback and a good question! I agree that it is quite difficult to track the link without OI management, but in fact you can use OI management for tax accounts as well. Recommendation from SAP doesn’t mean that it’s forbidden.

      On the other hand, usually posting periods are managed quite carefully in companies and if you’re doing tax transfer posting at the end of the month and include all tax relevant documents into selection, than you can be quite sure that selection of all line items posted during any month will accurately display original tax items as well as transfer posting for the total amount.

       

      Regards,

      Bohdan

      (0) 
  2. Former Member

    Hi Bohdan,

    Your post was very informative and helpful. I am a bit new to the VAT scenario. There are several unanswered questions for me:

    1. how VAT id gets captured in field STCEG in various tables
    2. which line items get populated with VAT id
    3. in which scenarios – 0 tax or non-zero tax

    If you have some documentation or link which can clear my doubts, it will greatly help me.

    Thanks in advance.

    Best regards,

    Vishal.

     

    (0) 
    1. Bohdan Petrushchak Post author

      Hello Former Member,

      Sorry for a delay with an answer, was not specifically check the portal for some time. These are good questions! Indeed some time ago I also stumbled upon some issues with display of tax requisites in this report. Here is the logic:

      • first of all, the report displays STCEG based on transnational data i.e. based on BSEG-STCEG. I’m not completely sure, but it would suspect that it will filled for those lines, where BSEG-KOART = “D” (customer) or “K” (vendor). The logic is simple: during the posting SAP takes actual data from master records and saves it into documents, thus if the requisite changes you will be able to have correct report for a vendor with time-dependent tax requisites.
      • if BSEG-STCEG is empty, the report checks master data of customer / vendor;
      • scenarios – 0 vs. non-zero tax – this is purely dependent of specific taxation scheme applicable to operating entity under local laws, so here I can’t really help you:)
      • you can also check KBA 2159728 – Content of field STCEG in RFUMSV00, which provides some light on this topic.

      Regards,

      Bohdan

       

      (0) 
  3. Ritesh Singh

    Hello,

    Thanks for this info. I have one issue with this report.

    There are some amounts/line items seen in one currency(company code(Singapore) currency -USD) but not seen in other currency (foreign currency – SGD). This is the case only with certain tax codes and certain Vendors (which are not located in Singapore)

    Can you please help on this?

    Regards,

    Ritesh Singh

    (0) 
    1. Bohdan Petrushchak Post author

      Hi Ritesh,

       

      Do I understand correctly that you have items in foreign currency, but report displays them only in company code currency, whereas you would like to see the information in foreign currency? If that’s so, it can be solved via configuration of report layout for input tax line items (go to section “Output Lists” on selection screen and choose option “Input tax: line items”). As you can see from the screenshot below, there are separate columns displaying information in CC currency vs. foreign currency.

      P.S. That’s usually a typical scenario, when operations with foreign entities are tracked using a separate tax code.

       

      Hope this will help you!

      Regards,

      Bohdan

      (0) 
  4. Ritesh Singh

    Hello,

    Thanks for the reply but here the issue is that the same amounts/line items is visible for USD currency but not seen for SGD currency. In both the cases tax code is same(GE). Only when the currency is SGD, some amounts are missing. pls see below:

    Visible in USD:

    Not visible in SGD (5100029096 and 5100030898):

    (0) 
    1. Bohdan Petrushchak Post author

      I’m not really sure what you mean “same amounts / line items are not visible”. On the screenshot you’ve provided, I can see that “Tax base amount” column contains values for all documents. Screenshot doesn’t show any other columns, so I’m not able to comment as to the cause of your concern.

      Anyway, you’ve quite specific question that is not directly linked to the topic of this post and I would suggest to raise it in a dedicated part of the platform that deals with Q&A topics.

      Regards,

      Bohdan

      (0) 
  5. Ritesh Singh

    Hello,

    Exactly my point. Tax base amount column shows 5 documents in USD (1st screenshot) but only 3 documents in SGD(2nd screenshot) for GE tax code.

    Ideally whatever documents are seen in USD, same should be visible in SGD also right?

    (0) 
    1. Bohdan Petrushchak Post author

      Well… that’s a bit strange. I seems that you using filter by “Currency” in dynamic selections on selection screen and the only suggestion that I have is that the currency of both documents is not 5100029096 and 5100030898 SGD.

      (0) 
    1. Bohdan Petrushchak Post author

      Hi Archit,

       

      Thanks for feedback!:) The trouble with this and a lot of other “older” standard reports is that they do not support ALV-functionality. That means that you can’t have this option nor via user settings on selection screen nor via configuration. Moreover, as I mentioned in the post, you can’t even properly download report values to Excel. The only workaround for the latest issue would be to implement OSS note 2388449 (RFUMSV00 list: Download as Spreadsheet), which I also briefly mentioned in the post.

      Hope you won’t be very frustrated about this lack of functionality!:)

      Best regards,

      Bohdan

      (0) 
  6. Andre Spruit

    Hi Bohdan,

    Thank you for this informative document. I have one question on the output of this report. If there is a document posted which contains 5 different GL accounts all posting with the same vat code then the posting to the VAT GL account will post one line with the total vat amount stripped off the 5 GL accounts which is normal. The VAT report then shows this total amount in the first account posted in the document only and not against each respective account. We want to see the vat amounts per account. This can be achieved through report S_ALR_87012359 but we would like to see this in report S_ALR_87012357. Is this possible?

    Kind regards

    Andre

     

    (0) 

Leave a Reply