How to import a single column of data into a mysql table

40 views Asked by At

Using MySQL 'Load Data Infile' in a windows environment, I found that the data that was uploaded is truncated. The first 2 characters were removed, but I am not sure why.

The data file looks like this:

ABL1
AKT1
AKT2
AKT3
ALK
ALOX12B
...

The uploaded data looks like:

|L1
|T1
|T2
|T3
|K
|OX12B
...

The sql command is:

load data infile "C:\\Users\\jw708\\Documents\\scripts\\perl\\OncoPanel_v1_exonic.csv" 
into table loadPanelGenes 
fields terminated by ',' 
lines terminated by '\n'; 

I was expecting the data to load correctly.

0

There are 0 answers