2007 Feb 20 7:02 AM
Hi all,
I have an internal table with all the fields from s703 table.Now i display the internal table using alv field catalog merge.Actually in the table for some vaues decimals are present like 5.0000,32.5000 but in the alv output i did not get the decimal points means for 5.0000 it is displaying only 5 and for 32.5000 it is displaying 32.5.
Please tell me how to get the original values in the display.
Thanks in advance
2007 Feb 20 7:06 AM
Hi,
In the internal table define that field as type p with decimals n.
Hope this helps.
reward if helpful.
Regards,
Sipra
Hi all,
I have an internal table with all the fields from s703 table.Now i display the internal table using alv field catalog merge.Actually in the table for some vaues decimals are present like 5.0000,32.5000 but in the alv output i did not get the decimal points means for 5.0000 it is displaying only 5 and for 32.5000 it is displaying 32.5.
Please tell me how to get the original values in the display.
Thanks in advance
2007 Feb 20 7:03 AM
Hi
Use corresponding Conversion_Exits before displaying the data in ALV.
Regards,
kumar
2007 Feb 20 7:06 AM
Hi,
In the internal table define that field as type p with decimals n.
Hope this helps.
reward if helpful.
Regards,
Sipra
2007 Feb 20 7:08 AM
While building field catalog please refer to teh same filed from the table.
2007 Feb 20 7:14 AM
hi,
when u r displaying the fields make sure that the length u specify should be equal to the length of the field in the table.
Refer this example.plz do reward points if it is of some use.
FORM fieldcat .
PERFORM addf USING:
'MBLNR' 'material document' 'X' '10',
'ERDAT' 'date' space '10',
'MBLPO' 'item no' space '04',
'MATNR' 'material' space '18',
'MAKTX' 'description' space '40',
'MEINS' 'uom' space '04',
'MENGE' 'qty' space '13',
'WAERS' 'curr' space '05',
'DMBTR' 'amt' space '13'.
ENDFORM. " fieldcat
&----
*& Form addf
&----
text
----
FORM addf USING value(p_fd) TYPE c value(p_txt) TYPE c
value(p_key) TYPE c value(p_len) TYPE c.
DATA: p_fieldcat TYPE slis_fieldcat_alv.
p_fieldcat-col_pos = t_pos.
p_fieldcat-fieldname = p_fd.
p_fieldcat-seltext_m = p_txt.
p_fieldcat-key = p_key.
p_fieldcat-outputlen = p_len.
p_fieldcat-do_sum = p_tab.
IF p_fieldcat-col_pos = 9.
p_fieldcat-do_sum = 'X'.
ENDIF.
APPEND p_fieldcat TO t_fieldcat.
t_pos = t_pos + 1.
ENDFORM. " addf
2007 Feb 20 7:15 AM
Hi
Conversion exits or giving field names not solved this problem.
is there any solution to display but must and should field catalog merge will be there
2007 Feb 20 7:23 AM
Hi,
In fieldcatalog or in the final output table structure refer the field BRGEW from MARA u will get three decimals.
2007 Feb 20 7:21 AM
Hi
call the FMs:
CONVERT_FIELD_TO_INTERN_FORMAT
in your programming before display those fields in the ALV.
Regards,
kumar
2007 Feb 20 7:22 AM
u have to check Field catalog.
fcat-decimals_out(6) = '3'.
otherwise send complete data to fcat.
<b> fcat1-fieldname = 'LMNGA'.
fcat1-key = ''.
fcat1-outputlen = '15'.
fcat1-just = 'R'.
fcat1-seltext_m = 'Producation, 8 Oz'.
fcat1-ddictxt = 'M'.
fcat1-inttype = 'Q'.
fcat1-datatype = 'QUAN'.
fcat1-do_sum = 'X'.
fcat1-no_zero = 'X'.
append fcat1.
clear fcat1.</b>
in this case u wont miss any thing
Regards
Prabhu
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |