How to import CSV data to MySQL in JetBrains DataGrip
Asked Answered
L

3

25

I'm studying MySQL. I need to import data from a CSV file to a MySQL table using JetBrains DataGrip.

I've done such this job before in dbForge MySQL, but last week I moved from Windows to Linux.

There are some questions how to import CSV to MySQL on StackOverflow, but I'm still not so familiar with SQL.

How do I import a CSV data file in JetBrains DataGrip?

Thank you!

Lee answered 20/1, 2016 at 14:53 Comment(0)
I
37
  1. Context menu of datasource you want to import to
  2. Choose Import from File....
  3. Customize the table that will be created, check the preview and press OK.

Context menu Import Dialog

Irvin answered 29/2, 2016 at 9:13 Comment(4)
I tried this and it was taking 280ms per row of a 3 column file. It took 380 seconds for 1321 rows compared to navicat which took 7 seconds to import the same data. Is there a way to speed this up? I want to be able to insert some csv files which contain several million rows of dataBurney
It's quite fast now with 2016.1Rubio
Still very slowwwwAmalbergas
Theja, please file the issue here: youtrack.jetbrains.com/issues/DBEIrvin
E
8

Precision : The pinned answer explains how to create and populate a new table.

To populate an already existing table it's quite similar: use the context menu of this particular table to choose Import From File. Then the steps are similar to the ones in the pinned answer.

Right click the table to update then import data from file

Epigram answered 3/9, 2018 at 10:39 Comment(0)
F
0

Since this original post. JetBrains has published this page outlining several of DataGrip's Import and Export features. https://www.jetbrains.com/datagrip/features/importexport.html

Footfall answered 17/11, 2021 at 21:56 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.