Application Development and Automation 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: 
Read only

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

Former Member
0 Likes
1,277

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
Read only

Former Member
0 Likes
1,100

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

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

7 REPLIES 7
Read only

Former Member
0 Likes
1,100

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

Regards,

Prasanth

Read only

Former Member
0 Likes
1,100

Dear S M,

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

Best Regards,

Flavya

Read only

Former Member
0 Likes
1,100

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

Read only

0 Likes
1,100

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.

Read only

Former Member
0 Likes
1,101

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

Read only

Former Member
0 Likes
1,100

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

Read only

Former Member
0 Likes
1,100

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...