Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

How to get previous value of a field to upload from excel to table ?

0 Kudos

u.png
In the image there are 2 columns. Left column contain serial number and right column contain document number.
My requirement is to upload the excel file to table. I want to upload serial number and document number in such a way that even if a document number is common for two serial numbers upload the document numbers for both serial numbers. For example row 1 and row 2 have a common document number and row 12 is blank, so if I upload it then row 2 is taking as blank but I want to assign the document number as row 1 and row 2 have a common document number. Also I do not want to assign the document number value of row 11 to row 12. How can I achieve this. A sample code will be helpful

1 REPLY 1

Sandra_Rossi
Active Contributor

You may search the forum/SAP Web site with your favorite Web search engine. I see many answers for search below. Based on the results, if it still doesn't solve, you may anyway refine your query/provide more information.

upload from excel to table site:sap.com

NB: if your only issue is about the algorithm, better propose an example with input and expected result, don't attach as image, show them as text inside your question. Also if you know ABAP a little bit, you should share your code and explain where you're stuck:

Input:

SerialNumber   DocumentNumber
1              1000000001
2
3              1000000025

Expected result in database table:

SerialNumber   DocumentNumber
1              1000000001
2              1000000001
3              1000000025