on ‎2020 Mar 29 4:26 PM
Hi All,
I have excel sheet of 5 records I got those records into internal table it_data_z
now I have 5 records in my internal table .
I am trying to upload 5 records from internal table ' it_data_z ' into z table ' zer_a3s_upload ' using
MODIFY zer_a3s_upload FROM TABLE it_data_z.
but when I am checking in debugging mode only last record is getting updated
I also tried for INSERT zer_a3s_upload FROM TABLE it_data_z.
Can anyone have on this .
thanks & regards,
Jyoshna.
Request clarification before answering.
Dear Jyoshna,
Having only one primary key as MANDT - will always going to be one record only. Because it stores the Client id only.
Adding bukrs also - unless you have multiple company codes.
Please add Line numbers like POSNR - which will be like sequence number of your line items.. adn keep that as additional key to MANDT
Only then it will work
Please update
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi All,
I have only taken mandt as a primary key and there are no primary keys in my table . because i am uploading excel sheet data into Z table .
my Ztable has 9 fields and i am taking It_data_z type standard table of my z table only .
okay i will take BUKRS as a primary key and check.
Thnaks to both for your replies .
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Dear Jyoshna
The Statement
MODIFY zer_a3s_upload FROM TABLE it_data_z.will work as insert as well as update.
If primary key value is new, it will insert else it will update
When you say it is updating the last record only means, The internal table is not having the full key - may be all 5 records belongs to same primary key - so it may be that 1st record is inserted and remaining 4 records are updated on it
So please recheck your Primary keys.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 8 | |
| 3 | |
| 3 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.