2016 Jul 25 10:58 AM
Hello Community,
we want to maintain an international address version of customers with the LSMW BAPI method. For this we war using ADRMAS03. In the field mapping of structure E1BPAD1VL1 we have set the field ADDR_VERS to 'C' (Chinese)
Within the IDOC Generation we will get the following information and error message:
Use another function to maintain the SPACE Version of the address
We only want the extend the Address for Chinese. Default Address is maintained.
Hope somebody can help.
Best regards
Matthias
2016 Jul 25 12:05 PM
the message is AM028
If you go to transaction SE91 and click the where used button for this message then you only get 3 hits, if you open the first of those programs then you can see that SAP only expects either a Handle or an address number , but not both.
Hello Community,
we want to maintain an international address version of customers with the LSMW BAPI method. For this we war using ADRMAS03. In the field mapping of structure E1BPAD1VL1 we have set the field ADDR_VERS to 'C' (Chinese)
Within the IDOC Generation we will get the following information and error message:
Use another function to maintain the SPACE Version of the address
We only want the extend the Address for Chinese. Default Address is maintained.
Hope somebody can help.
Best regards
Matthias
2016 Jul 25 12:05 PM
the message is AM028
If you go to transaction SE91 and click the where used button for this message then you only get 3 hits, if you open the first of those programs then you can see that SAP only expects either a Handle or an address number , but not both.
2016 Jul 25 1:57 PM
Hello Juergen,
and how can this solve my problem? I'm not sure what I have to change in my LSMW structure field settings.
Best regards
Matthias
2016 Jul 25 2:00 PM
Without showing your structure with content it is not easy to tell what you have to change
Make a screenshot of the detail of converted data
2016 Jul 25 2:23 PM
Hello Juergen,
sorry my mistake. I have made some screenshots from the Converted Data and the results:
Converted Data:
Results
Regards Matthias
2016 Jul 25 2:31 PM
Before I check in detail, can you add a screenshot of the record(s) in ADRC for this customer
2016 Jul 25 2:36 PM
no problem,
here the results of the address of this customer:
2016 Jul 25 4:22 PM
I just tested it and it looks like you can't create an address with this BAPI without submitting records for the NATION = ' '
I got the same error as you had when I just had the Chinese address alone, but when I had the normal address together with the chinese then it worked right away.
Make sure your Idoc structure looks finally like this, first the version with the blank, then the version with the C for chinese.
2016 Jul 26 8:44 AM
This sounds great. I'm not sure how I can reach your results above. I don't know how I can create two E1BPAD1VL Structures under the Header segment. If I enter two lines in the ADDR_VERS
E1BPAD1VL-ADDR_VERS = ' '
E1BPAD1VL-ADDR_VERS='C'
then the program will read my file but the same error.
Looking forward to hear from you.
BR Matthias
2016 Jul 26 8:57 AM
There are many ways to achieve this.
The easiest is eventually a second line with the international address in the source file .
Alternative you can also add a few line ABAP coding in the transfer_record section of E1ADRMAS, where you read the existing address from table ADRC table and fill the structure E1BPAD1VL and E1BPAD1VL1 and then use the commands transfer_this_record 'E1BPAD1VL' and transfer_this_record 'E1BPAD1VL1' to write the segments for the blank address version before the other segments for the Chinese address version are created by the LSMW
2016 Jul 26 9:09 AM
First proposal I have to check. That means I have for the same address two lines in my source file and in the column for the Addr_vers I have in the first line a blank and in the second line a C??
Second proposal sounds great but I cannot develop ABAP and our partner is not so fast that I get the coding as far as needed. 😞
2016 Jul 26 9:17 AM
regarding the first proposal:
if you use international addresses then you have the address in - lets call it - English
and again in Chinese.
So the blank version has to have the English address and the C version has to carry the Chinese address.
As you can only load Addresses with this BAPI via LSMW if the customer already exists then you should already have this English address in your database table ADRC.
So you may need to download it from there and add it into your source file.
Be aware that the IDoc updates your English address, make sure it is 100% equal to the address in your database.
2016 Jul 26 10:59 AM
Now I have the same structure like you but I hope we speak now only from a small problem.. I'm not able to set the "Blank" for the first address. In my source field, I have set a blank for the English Adress but within the IDOC generation the system ignores this field and the ADDR_VERS is not filled.
DATA RECORDS
E1ADRMAS
E1BPAD1VL -> Blank will be ignored
E1BPAD1VL
2016 Jul 26 12:02 PM
Not sure I understand, what is the difference between blank and not filled?
And what do you mean by "ignored"
this would be the coding for having a blank in the address version:
E1BPAD1VL-ADDR_VERS = ' '.
2016 Jul 26 12:21 PM
ok here the screenshots
converted data -> both Addresses (one with C and the first one with blank
The IDOC with the both segments
Segment 3 is the Address for C. Here you can see the field ADDR_VERS
Segment 2 is the SPACE Address. Field is missing because the program do not understand the blank and then the field is nit inside of the segment.
2016 Jul 26 12:26 PM
SAP shows only fields that are not empty in this "preview".
If you double click the icon in front to the segment then SAP takes you the segment detail and from there you can select from the first menu to Edit the record.
After doing that you can see the entire segment even with all empty fields.
2016 Jul 26 12:30 PM
2016 Jul 26 12:33 PM
You have to choose EDIT from the menu to see it complete
Or you take the idoc number and display it in WE19
2016 Jul 26 12:37 PM
2016 Jul 26 12:42 PM
maybe different error. I have found an answer from you in an other discussion
2016 Jul 26 12:49 PM
In many occasions SAP just stops with the first error, and once that one is solved you get the next one until you solved all.
The easiest way to know what data you need to maintain would be to send a fully maintained customer as IDOC, then check the ADRMAS idocs in BD87. Maybe you have already ALE in your system where customers or vendors are distributed, this would make it even easier to check. Otherwise follow the introduction in my blog
2016 Jul 26 1:20 PM
Problem is solved. I have to spend you a drink. Have a great day and thanks again for the great support.
BR Matthias
2016 Jul 26 1:30 PM
2016 Sep 01 7:01 PM
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |