‎2011 Jul 18 12:20 PM
I have created an object named ZMM_TXT from transaction se75, and also en ID named Z1 for this object.
I have executed funcion SAVE_TEXT from transaction se37 with these parameteres:
CLIENT = 111
HEADER:
TDOBJECT = ZMM_TXT
TDNAME = E000000000000001009731
TDID = Z1
TD = ES
LINES:
TDLINE = TEXT FOR PLANT E000 AND MATERIAL 1009731
NOTE: In TDNAME I have concatenated the plant (E000) and the material code ( 000000000001009731)
Everything is OK, I haven´t got any error message.
I thougth that using SAVE_TEXT, text was stored in STXH database table, but it´s not this way. After executing SAVE_TEXT from se16n
I look at STXH table with TDOBJECT = ZMM_TXT but no value is shown. In which database table are stored these values?
After executing SAVE_TEXT I have executed READ_TEXT with these parameters:
CLIENT = 111
ID = Z1
LANGUAGE = ES
NAME = E000000000000001009731
OBJECT = ZMM_TXT
This is what I get:
Excepcion NOT_FOUND
Id mensaje : TD
Numero mensaje = 600
Texto E000000000000001009731 ID Z1 idioma ES no existe.
How should I execute READ_TEXT to read the text I have saved previously?
Thanks in advance.
‎2011 Jul 18 12:36 PM
Hi,
check this
[http://wiki.sdn.sap.com/wiki/display/Snippets/HowtosaveandretreiveTextobjects]
Regards,
Madhu.
‎2011 Jul 18 12:58 PM
hii,
TDOBJECT shud be a table name of the text.Check the parameters u have passed correctly r not.see a sample code format.
data:l_name like thead-tdname,
SELECT single tdtxtlines
from stxh
into v_textline
where tdid = 'ZV23'
and tdname = p_vbeln
and tdobject = 'VBBK'.
call function 'READ_TEXT'
exporting
id = '0001'
language = sy-langu
name = wa_tname-name
object = 'VBBP'
tables
lines = it_tline
‎2011 Aug 01 9:58 AM
I have created database table ZMM_TXT_PD with fields
MANDT (MANDT)
CENTRO (EWERK)
MATERIAL (MATNR)
All of them are key fields.
I have created a record in this table:
111
E000
1009731
I have created from se75 an object called ZMM_TXT_PD with ID Z2.
I have executed SAVE_TEXT with these parameters:
CLIENT: 111
HEADER:
TDOBJECT = ZMM_TXT_PD
TDNAME = E000000000000001009731
TDID = Z2
TD = ES
LINES:
TDLINE = SOME TEXT
Text is saved.
After that I have executed READ_TEXT with these parameters:
CLIENT: 111
ID : Z2
LANGUAGE: ES
NAME : E000000000000001009731
OBJECT: ZMM_TXT_PD
I get this error:
EXCEPTION: NOT_FOUND
MESSAGE ID : TD
MEESAGE NUMBER : 600
"Texto E000000000000001009731 ID Z2 idioma ES no existe."
E000000000000001009731 ID Z2 LANGUAGE ES does not exist.
How should I execute READ_TEXT to be able to read the text previously saved?
‎2011 Aug 01 10:15 AM
It looks like the text is not saved..
use the commit work and wait statement or commit_text FM after save_text FM.
first try saving the standard text in SO10, giving the same parameters which you are using.
for read_text and save_text code you can search the forum
‎2011 Aug 01 10:40 AM
I execute save_text from se37, so commit is implicit; is it?
I can´t use so10 because it´s not a standard text.
Thanks.
‎2011 Aug 01 10:45 AM
try with an extra commit statement after save_text.
I dont think its implicit.
if not so10, use the same tcode se75 which you are using.
‎2011 Aug 01 12:15 PM
Would it be a good idea to save the text in table stxh directly?
Thanks.
‎2011 Aug 01 12:17 PM
i usually store my standrad text @ so10 or using save_text , which i can see in STKH tables. even few of the SAP's standrd texts are saved in the same table
‎2011 Aug 01 12:59 PM