2013 Dec 13 7:26 AM
Hi Folks,
I am uploding data thru excel into my custom table, while uploading have to check whether the entry is new or old based on that update the flag field with 'N' or 'O'.
entry may exist with old required fields data same and non-required fields data has changed so need to update the entry with "O"
Please suggest me how can approach the above
Thanks,
smriti
2013 Dec 13 7:31 AM
Hi Smriti,
Can you explain your requirement little bit more ???
Deependra
2013 Dec 13 7:36 AM
Hi Deependra
I am Uplodaing excel data into Ztable, while uploding i have to check whether the
entry is already existing(req fields checking, non- required fields data will change)
or new entry.If it new entry i have to update the flag as "N", if any entry existing
then i have to modify the record instead of creating new entry in this case
flag has to update as "O".
Appreciate your help
Thanks,
Smriti
2013 Dec 13 7:44 AM
I assume that you use gui_upload. After that query the table with pkey. modify the same in the uploaded internal table and update the table.
2013 Dec 13 7:46 AM
Smriti,
As i understood update flag is also field of your table . That would be better if you select the data from Ztable and validate with new data (Uploaded by Excel in internal table) via table keys, and then update new and old both flags in internal table with new data.
After validation and populate entries in internal table you can use Modify statement . If data with exist with Old Flag it will get modify in table else new record would be created.
Deependra
2013 Dec 13 7:38 AM
HI Smriti Reddy,
You want to update the Table using se38 or LSMW.
By SE38, you have to select record based on the update record If the record exist then set the flag as per your requirement.
By LSMW you have to make a module in the PAI and select the record from the database table and if exist set the flag.
Regards.
Nishant Bansal