Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Truncated file in application server.........

Former Member
0 Kudos

Hi,

I am downloading XML file to the application server...

But only one line is coming....I think i am able to see only one line but all the records are going into the application server file...

Can any body advice me what to do.

Regards.

Edited by: s m on Nov 27, 2008 6:39 AM

Edited by: s m on Nov 27, 2008 7:14 AM

1 ACCEPTED SOLUTION

former_member184619
Active Contributor
0 Kudos

Hi,

Sometimes in case of XML files.. it will show all the data in single line...

Just select all and paste in notepad/wordpad... and cross check you are getting all the tags..in XML if so then your XMl file is correct.

Regards,

Sachin

7 REPLIES 7

Former Member
0 Kudos

Could you please elaborate how your are doing, if possible just paste couple of code.

Regards,

Prasanth

Former Member
0 Kudos

Dear S M,

what is the problem? Could you please explain in details so that it will help us for sloving?

Best Regards,

Flavya

Former Member
0 Kudos

Hi delcare like this ...

CONSTANTS: c_cr TYPE x VALUE '0D', "Carriage Return Character in Hex

c_lf TYPE x VALUE '0A', "Line Feed Character in Hex

after that pass like this...

OPEN DATASET g_file FOR OUTPUT IN BINARY MODE .

LOOP AT v_xml_table INTO li_xml_table.

TRANSFER li_xml_table TO g_file .

TRANSFER c_cr TO g_file.

TRANSFER c_lf TO g_file. ENDLOOP.

CLOSE DATASET g_file.

in u r program u r passing only data Not cr and lf

add these two u r problem will resolve.

Thanks,

Rahul M

0 Kudos

Hi Rahul,

Thanks for the reply....

Still one problem ..some part of lines are getting truncated....

I cant see the full lines...

What can be done in this regard.

Regard.

former_member184619
Active Contributor
0 Kudos

Hi,

Sometimes in case of XML files.. it will show all the data in single line...

Just select all and paste in notepad/wordpad... and cross check you are getting all the tags..in XML if so then your XMl file is correct.

Regards,

Sachin

Former Member
0 Kudos

use CG3Y tcode and download the your file and chek the all fileds are transferd or not.

Former Member
0 Kudos

Hi,

Use this way:-


  OPEN DATASET w_log
                   FOR OUTPUT IN TEXT MODE
                   ENCODING DEFAULT.
    IF sy-subrc <> 0.

      WRITE:/ 'Error in opening file'.
    ELSE.


      LOOP AT it_log.


        CLEAR wa_it_log.

        wa_it_log-w_vbeln   = it_log-w_vbeln.
        wa_it_log-w_posnr   = it_log-w_posnr.
        wa_it_log-w_matnr   = it_log-w_matnr.               
        wa_it_log-w_cname   = it_log-w_cname.
        wa_it_log-w_ovalue  = it_log-w_ovalue.
        wa_it_log-w_nvalue  = it_log-w_nvalue.


        TRANSFER wa_it_log TO w_log.
        CLEAR w_excel_string.

      ENDLOOP.

Thanks & Regards,

Krishna...