‎2007 May 08 3:08 PM
how to find the length of a field dynamically.
i'm displaying the output in flat file, with delimiter.
based on the length of field dynamically '|' should come.
05562031|26/07/2006|31/12/9999|P|12 Sanderling Rise |
0753||31/12/9999|| Jackdaw Drive 07562926|26/07/2006|31/12/9999|P|
I mean based on the field length pipe delimiter should come. if you observe first and second records especially first field length you can cleary identify what i'm exactly looking for.
Experts please help me.
Regards
vamsi.
‎2007 May 08 3:12 PM
Hi,
You will have the data in a Internal table, then you will put that in the final one and download it to the faltfile, so before movin git to the internal table move with PIPE symbol
Regards
Sudheer
‎2007 May 08 3:12 PM
Hi,
You will have the data in a Internal table, then you will put that in the final one and download it to the faltfile, so before movin git to the internal table move with PIPE symbol
Regards
Sudheer
‎2007 May 08 3:15 PM
Hi Vamsi,
Make ur internal table as shown below :
data : begin of i_record occurs 0,
records type string,
end of i_record.
data : v_pipe type c value '|'.
LOOP AT I_TAB.
CONCATENATE I_TAB-matnr
I_TAB-mtart
I_TAB-meins
INTO I_record-RECORD SEPARATED BY V_PIPE.
APPEND i_record.
Download this data usinf FM 'gui_download' and the internal table i_record in to it.
Reward points if helpful.
Regards,
Hemant
‎2007 May 08 3:18 PM
Hi Vamsi,
write ENDLOOP after appending i_record.
I forgot to write in previous thread.
Regards,
Hemant
‎2007 May 08 3:26 PM
Hi Vamsi,
If you are trying to find out the length of a field and not the content you can use the
following abap statement for it.
DESCRIBE FIELD d_ntype-tdata LENGTH d_len IN CHARACTER MODE.
Regards,
Aravind