flxplzk flxplzk - 1 year ago 111
SQL Question

How can i load messages from Excel to SAP table T100?

I have to work out an solution for the following issue: My task is to import round about 2000 translations of existing messages to SAP. Does any one of you a simple solution how i can accomplish that, other than doing it manually with

SE91
?

I thought about solving this with an simple
UPDATE
or
INSERT
, but since I am a noop when it comes to code in ABAP, I would appreciate a hint to start somewhere.

SPRSL ARBGB MSGNR TEXT
------------------------------------
D /WMS 001 eine Nachricht


That is what i want the result in the table look like afterwards.

SPRSL ARBGB MSGNR TEXT
------------------------------------
D /WMS 001 eine Nachricht
E /WMS 001 some message


I have everything well prepared (Table with translation within the required structure, SQL - Insert Statement for each message class)

Answer Source

I figuered a way to solve this issue. I created a LSMW - job with an empty Batch-Job-Recording of tx SE16. In the menuepoint "fieldmapping" there is a slot to code in ABAP. There I wrote that simple ABAP code

DATA: t_T100 TYPE T100.
t_T100-SPRSL = TRANSLATIONS-SPRSL.
t_T100-ARBGB = TRANSLATIONS-ARBGB.
t_T100-MSGNR = TRANSLATIONS-MSGNR.
t_T100-TEXT = TRANSLATIONS-TEXT.

INSERT T100 FROM t_T100.

Then I imported my translations as CSV in the LSMW. I only had to press run and all the data were in the database in the right structure.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download