List:General Discussion« Previous MessageNext Message »
From:Visolve DB Team Date:November 18 2006 7:21am
Subject:Re: Importing Text File Into mySQL
View as plain text  
Hi,

LOAD DATA restricts only on BLOB,TEXT,ENUM and FIXED DATA.  Others are 
equally supported [INSERT stmt].  Likewise for mysqlimport also.

If the data file has no delimiter other than space[even the name, 
addresss,etc contain spaces], then the target table will not the one what is 
expected, though it is possible to import the data. It also depends on the 
width of the fields. The data and the fieldname does not corresponds.

Thanks
ViSolve DB Team.
----- Original Message ----- 
From: "John Kopanas" <kopanas@stripped>
To: <mysql@stripped>
Sent: Saturday, November 18, 2006 4:35 AM
Subject: Importing Text File Into mySQL


>I have a text file with over 500K rows of data in it.  The problem is
> that the data is no seperated by commas but instead  occupy a certain
> amount of characters.  So for instance:
>
> ID 1 -11
> NAME 12-50
> COMPANY_NAME 51-100
> ...
>
> How would you parse import this data into mysql?
>
> Thanks for your help :-).
>
> -- 
> John Kopanas
> john@stripped
>
> http://www.kopanas.com
> http://www.cusec.net
> http://www.soen.info
>
> -- 
> MySQL General Mailing List
> For list archives: http://lists.mysql.com/mysql
> To unsubscribe: 
> http://lists.mysql.com/mysql?unsub=1
> 

Thread
Importing Text File Into mySQLJohn Kopanas18 Nov
  • Re: Importing Text File Into mySQLBruce Ferrell18 Nov
  • Re: Importing Text File Into mySQLDan Nelson18 Nov
    • Re: Re: Importing Text File Into mySQLJohn Kopanas18 Nov
      • Re: Importing Text File Into mySQLDan Nelson18 Nov
  • Re: Importing Text File Into mySQLVisolve DB Team18 Nov