Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Crystal report export to CSV

Crystal report export to CSV

Crystal report export to CSV

Good day,

Hoping someone can help. I exported my report from crystal report to CSV format with the headers and all columns coming out right as expected. I have a client platform that says a file must be imported as CSV and the CSV format exported from crystal report seem to fail during import to the client's platform.

When I copy and paste the header columns from the template provided by the client over to the Crystal report's CSV export, and then import the file on the client platform, this seems to go through Ok. Is there something i am doing wrong. I am trying to avoid any manual inputs and just have a report that exports to CSV and then can be imported to a platform.

During my export from crystal report to csv, i selected the option Isolate Report/Page sections.

Any help or advise will be appreciated. Thanks

RE: Crystal report export to CSV

Without knowing why the import fails, it will be hard to diagnose. It could be data types, NULLs, etc.

RE: Crystal report export to CSV

I understand what you mean. Problem is how do i diagnose this?

Just reading through the document provided along side the template from the client about upload to the platform. It says must be CSV and column headers have Carriage return line feed (Crlf) as end of line delimiter. I am going to try adding Crlf to the header column names using a formula "textname"&chr(13). I'll advise if this works.

RE: Crystal report export to CSV

Note that the ASCII code for line feed is chr(10). I wonder if they are asking for both a carriage return chr(13) and a line feed.


RE: Crystal report export to CSV

Just tried "textname"&chr(13) and that didn't work. trying "textname"&chr(13)&chr(10) and if this doesn't work, i'll change this over as "textname"&chr(10)&chr(13) to see if it works. Thanks for all your response. I will advise shortly or let me know if the formula should be written in a different way.

RE: Crystal report export to CSV

If this is due to BOM issue, there are several ways to get around that.
Are you addressing an interactive use case (user running report inside Crystal Designer or a Crystal Viewer) or an automated scenario (scheduled, command line, desktop shortcut)?

view, export, burst, email, and schedule Crystal Reports.

RE: Crystal report export to CSV

Neither "textname"&chr(13)&chr(10) nor "textname"&chr(10)&chr(13) has worked.
IdoMillet - I don't think issue is with BOM. What I have tested so far is that, I run my report and export to CSV. So far so good. When I try to import into the client's platform it fails. When I take the CSV template the client provided and copy the header column titles over my exported csv titles (override), import is successful.

Note. I have checked the column titles up to the smallest space, alignments, spellings etc. There is no difference to the csv I generated. I have decided to send my CSV to the client and ask they check and advise why the file is not importing, maybe they could provide a starting point.

RE: Crystal report export to CSV

Still sounds like a BOM issue to me.

If it is, at least one of the 3rd-party UFLs listed here provides control over the emitting of BOM in writing the report data to a a text (.csv) file.

view, export, burst, email, and schedule Crystal Reports.

RE: Crystal report export to CSV

Also, at least one of the 3rd-party Crystal report automation tools listed here allows you to use the "good" header file and simply append the csv export to the existing header (while removing the header from the export).

view, export, burst, email, and schedule Crystal Reports.

RE: Crystal report export to CSV

Not sure if this is relevant, but to my surprise, I couldn't get the chr()'s to create the return/line feed without adding a space to the end of the formula:

&" "

Not sure how this would play out in a cvs export.


RE: Crystal report export to CSV

Thanks for all your inputs. I went back to the company we are importing the file on their platform with the files rejected and they confirmed there was an issue with the template they provided and sent through a revised template with different column names. Import is now successful without use of Carriage return or Line feed function mentioned above.

Only thing I noticed is that exporting the report to CSV from crystal report, there is the option to tick "Isolate Report / Page Sections" but when uploaded to an online platform infoview, this option is not available. Anyway round this?

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close