2013 Mar 09 6:57 PM
Hello everyone.
How can I add a field with type "LCHR" to Ztable.
How I can read out from that field and also how to update that field with a value.
there are not many example to find on LCHR.
i have tried the following link to study:
http://help.sap.com/saphelp_45b/helpdata/en/bc/897415dc4ad111950d0060b03c6b76/content.htm
but it only gives theoretical explanation for lchr.
can someone help me with example (in abap code).???
thank you
ojaswa
Hello everyone.
How can I add a field with type "LCHR" to Ztable.
How I can read out from that field and also how to update that field with a value.
there are not many example to find on LCHR.
i have tried the following link to study:
http://help.sap.com/saphelp_45b/helpdata/en/bc/897415dc4ad111950d0060b03c6b76/content.htm
but it only gives theoretical explanation for lchr.
can someone help me with example (in abap code).???
thank you
ojaswa
2014 Jan 30 10:04 PM
Hello Ojaswa,
You have a limitation of 255 characters on every alv that you use to show the results.
So you have to export the data from the database table.
Let's try to explain:
You have a database table with 2 fields (e.g.)
LENT TYPE INT2 (2 Byte Integer (Signed)), this field itis used for save the length of the LCHR field
ERROR_MESSAGE TYPE SMO_1500 LCHR (character 1500), this field it's used for save the string value with 1500 character.
You can't read this data with the TCODE SE16 or SE16N or SE11, because exist a limitation of 255 character on ALV tables.
Create a report like that to export the data to a file:
SELECT *
FROM zsrm_wlu_004
INTO TABLE lt_zsrm_wlu_004
WHERE wi IN s_wi AND
ano IN s_ano AND
wi_aagent IN s_agent .
CALL FUNCTION 'GUI_DOWNLOAD'
EXPORTING
filename = p_file_download
filetype = 'ASC'
TABLES
data_tab = lt_zsrm_wlu_004
.
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |