cancel
Showing results for 
Search instead for 
Did you mean: 

Export to CSV

Former Member
0 Kudos
89

When we export a report to CSV the output is essentially useless to us. Every row in the CSV contains the titles, and such of the groups and page. Is there a way to format this nicer. For instance if we have the following data in a report:

Name Address City

AF 123 Main My City

OF 234 Main My City

How can we get the csv:

Name,Address,city

AF,123 Main,My City

OF,123 Main,My City

instead of what we are receiving:

Name,Address,city,AF,123 Main,My City

Name,Address,city,OF,123 Main,My City

of course only MUCH worse since we have several columns, etc.

I've looked at the export options but really don't see much of help there for CSV.

Al

Accepted Solutions (0)

Answers (1)

Answers (1)

ted_ueda
Employee
Employee
0 Kudos

Are you able to use the alternative exporting format - Excel (data only) - new with Crystal Reports for Eclipse Version 2, that preserves the structure of the report better than CSV export?

Sincerely,

Ted Ueda

Former Member
0 Kudos

Ted,

Right now we are bound to the previous version (11.x) of the JRC. We may be upgrading to 2.0 in the future, but for now (1-3 months) we are using the older version. I would love to use the new excel export in 2.0, but the migration effort is more than we can handle at this time.

Al

ted_ueda
Employee
Employee
0 Kudos

There won't be a resolution for this at the current version of the JRC you're using (other than post-processing the csv, but that has its own issues, independent of the JRC).

I think there was a fix at version 11.8.3 (CR4E Version 1 Patch 3) for CSV export of report headers, but don't know if the fix applies to your issue specifically.

Sincerely,

Ted Ueda

Former Member
0 Kudos

Hmm then we should have that fix since we are on version 11.8.4.1197. Ohh well as you said we get around it by creating a report with only the data fields in it, then prepend our own csv column names to that for export.

is the problem totally resolved in CR4E 2? I know excel data only is in that, but we may have to stick with csv even if we upgrade. (It does not seem that CR4E 2 is a drop in replacement for us - we do some things in a struts action class, add the viewer to the session, get it out of the session in the jsp and view the report. Some of that due to requirements to have our own look and feel toolbar, customized PDF exports and such.)

Al

ted_ueda
Employee
Employee
0 Kudos

If it's not working for you with 11.8.4, I expect the same CSV with CR4E Version 2 RTM

The new DHTML Viewer is more interactive with JavaScript on the client-side, and the CrystalReportViewerServlet (where postbacks go to) retains its own copy of the ReportSource placed in session by the CrystalReportViewer - so I envision two possible fundamental changes with the new version in your integration.

Sincerely,

Ted Ueda

Former Member
0 Kudos

Ted,

yes we are definitely holding off on upgrading because of HTTP session issues. Currently we maintain the viewer in session (which can cause some problems but we have gotten around many issues by limiting the viewing to a single report at a time). Also since we do not use the built in toolbar, but created our own look and feel one we do next, previous, first, and last page stuff on our own.

Also we are always posting back to our own Struts ActionServlet/action instances so upgrading may be inherently difficult for us to begin with. Essentially we use the DHTML of the report itself but nothing else, so upgrading may cause some pain for us at this point.

Al