Automate

 View Only
  • 1.  Customer master data - tax classification modification

    Posted 08-28-2019 07:51
    Dear all,

    I have to provide the possibility to update the tax classification in Customer master data (XD02 / Sales area data / Billing documents / Taxes), but I don't know how I can make sure the expected line will be updated (correct country and tax category).
    Did someone already made this type of script ?

    Thanks in advance for your support.

    ------------------------------
    Sandrine Leclair | Business Application Manager ESE Group
    ESE France | 0033 6 73 68 32 63
    ------------------------------


  • 2.  RE: Customer master data - tax classification modification

    Employee
    Posted 09-04-2019 17:47
    Hi Sandrine,

    You could try using a script recorded with GUI Scripting, but it could only be on one column, i.e. Country or Tax category.  Since neither might be unique enough, it usually doesn't work.

    Otherwise, a function module (BAPI)  is the best way to go.  Since SAP doesn't provide one, we do in our Winshuttle Function Module.  It's called /WINSHTLQ/TRN_FUNC_CUSTOMER

    I'm attaching a draft document that describes the functionality it has.  Note there is other functionality in this function module for customer, as well.  Please forgive typos, spelling and grammar. 
    • For this one I_MODE is TAX, and you pass in the customer number, sales org, dist channel and division all in ExportOthers
    • For the tax classes use table T_KNVI.  I used the change type (field KZ) of "U" for update.
    • There is another table called GT_TAX_MSG that has the message associated with it called Message.

    I am also attaching 2 examples.  One does one tax country/category at a time, and one does it in a loop.   Both only deal with tax classes and only do updates, so you can modify to meet your needs.  You'd have to use Studio Direct to do so.

    If you're not familiar with Direct, you're missing out :)  Use the training links on the Community site for Direct OR contact your sales rep to get you information on Training and/or mentoring options.

    Hope this helps.

    Best Regards,
    Sigrid


    ------------------------------
    Sigrid Kok
    pse | Winshuttle North America
    ------------------------------



  • 3.  RE: Customer master data - tax classification modification

    Posted 09-05-2019 08:18
    I use a BAPI to enter tax classifications in different countries.
    This is the script:
    script taxclass
    and this is the Excel sheet it refers to:
    excel tax class
    I  use this script very often, works like a charm.
    best regards, jan

    ------------------------------
    Jan Ketele | Sr engineer release management
    Xeikon Manufacturing NV | +3234431875
    ------------------------------



  • 4.  RE: Customer master data - tax classification modification

    Employee
    Posted 09-05-2019 09:54
    Hi Jan

    Thanks for posting.  You're right, that BAPI works great for materials - I use it often for taxes, alternate units of measure, multiple language descriptions, etc. 

    Unfortunately, there isn't a customer version with tax classes - thus the Function Module we offer for customer as part of the Winshuttle Function Module.

    Best Regards,
    Sigrid

    ------------------------------
    Sigrid Kok
    pse | Winshuttle North America
    ------------------------------