Toad World® Forums

Export from Toad into Excel is not preserving the "new line" characters inside a field

I’m trying to Export some data into an Excel.

Some of the fields have aggregated values which are separated by “new lines” - chr(13). (I’ve also tried chr(10) and chr(13)||chr(10) )

Everything looks good in Toad (grid view).

But the export to Excel does not preserve the “new lines” They are essential for the formatting in my particular case.

Is this a bug? I can’t find any option that would control this behavior.

Thoughts?
Thanks!

A “new line” for windows is CHR(13) and CHR(10).

So if you replace CHR(13) with CHR(13) || CHR(10) in your select statement, you’ll see a line feed in excel.

I know. I should have mentioned that I tried all these 3 options:

  • chr(13)
  • chr(10)
  • chr(13)||chr(10)
    Neither one worked.

I tested chr(13) || chr(10) before my first reply and it worked with the “Excel Instance” export option.

With the “Excel File” option - at first it looks like it doesn’t work, but then when I double-click a cell in Excel, the line feed suddenly appears.

I wonder if there is some setting in Excel that affects this.

Thanks! Yes, you are right! I just noticed that in my file as well.

There is a “Wrap text” option in Excel (under formatting cell) that controls this.

I think that needs to be done separately, in Excel, after the export is completed from Toad (I don’t see an option to control this from Toad). But that’s still good for my purpose.

Thanks!

Ovidiu

From: John Dorlon [mailto:bounce-jdorlon@toadworld.com]

Sent: Thursday, August 17, 2017 11:48 AM

To: toadoracle@toadworld.com

Subject: RE: [Toad for Oracle - Discussion Forum] Export from Toad into Excel is not preserving the “new line” characters inside a field

RE: Export from Toad into Excel is not preserving the “new line” characters inside a field

Reply by John Dorlon

I tested chr(13) || chr(10) before my first reply and it worked with the “Excel Instance” export option.

With the “Excel File” option - at first it looks like it doesn’t work, but then when I double-click a cell in Excel, the line feed suddenly appears.

I wonder if there is some setting in Excel that affects this.

To reply, please reply-all to this email.

Stop receiving emails on this subject.

Or
Unsubscribe from Toad for Oracle Forum
notifications altogether.

Toad for Oracle - Discussion Forum

Flag
this post as spam/abuse.