How to export with Header Rows

Answered

Using the Dump Data button with either tsv or csv selected and I can't seem to get DataGrip to export the header rows.

I tried setting 'First row is header' in the CSV formats options, but it seems to have no effect.

I assume the solution is straightforward but I'm struggling to find it.

 

Thanks,

Simon

9 comments
Comment actions Permalink

I would also like to know this both for CSV exports and for clipboard exports and tried 'First row is header' to no avail

3
Comment actions Permalink

This is exactly what I want. 

 

It turns out if you select all the rows and click data dump you can select "First Row as Headers" and it adds the column names as headers.

0
Comment actions Permalink

Dear Jet Brains. Please make this default in the next release.

2
Comment actions Permalink

Dear Jet Brain, why is this feature still not there?  It is VITAL when doing exports with many columns. 

5
Comment actions Permalink

Jet Brains, any update on this?

0
Comment actions Permalink

In general one need to configure CSV formats:

 

and then to check First row is header for a specified format:

Don't forget to apply your changes.

 

 

 

0
Comment actions Permalink

It is there but not trivial especially when you chose to have another format such as CSV or custom format.

You have to specifically select the target format under "Formats" before selecting "First row is header" as otherwise your changes are applied only to the default format which is TSV :) This took me a while to figure this out. Hope this helps someone.

 

Navigation(Intellij 2018.2)

Right click on query results -> Data Extractor -> Configure CSV Formats.

Here is the trick Select your target format under "Formats" first before enabling "First row is header" option.

You must be good to go now.

 

 

2
Comment actions Permalink

Hari Krishna, that was my problem exactly!  Ty

0

Please sign in to leave a comment.