Hello.
Are you sure that you want to load PDF with LOAD DATA INFILE? Maybe LOAD_FILE is that you want: http://dev.mysql.com/doc/refman/5.0/en/string-functions.html Whil Hentzen wrote: > Hi folks, > > I want to load a set of PDFs into a MySQL 5 ISAM table. I'm using the > following command > > LOAD DATA INFILE '1037021.pdf' INTO TABLE complete FIELDS TERMINATED BY > '%%EOF' (d_c) > > in the Query Browser 1.1.17, MySQL 5.0.15, running on W2K. Field d_c is > defined as LONGTEXT. > > The following bad things happen: > > 1. The PDF gets loaded into 553 separate rows, instead of just one record. > 2. I get an error in the Query Browser (bottom pane, under the Result > Set pane) after completion: > > Row 42 was truncated; it contained more data than there were input > columns (error 1262). > > 3. If I change column d_c to be TEXT or BLOB, I get the same errant > results. > 4. If I remove the FIELDS TERMINATED BY clause, I get the following > error repeated 64 times between rows 48 and 176, where nn runs from 48 > to 176: > > Row nn was truncated; it contained more data than there were input > columns (error 1262). > > I've done a search on the list archive through the beginning of the year > and only found one set of three messages relating to LOAD DATA INFILE > failing for loading PDFs (and Word and XML), but the author later solved > it himself without telling us what he was doing wrong :(. > > Suggestions? Have I a big concept problem or just a little syntax one? > > Whil > > -- For technical support contracts, goto https://order.mysql.com/?ref=ensita This email is sponsored by Ensita.NET http://www.ensita.net/ __ ___ ___ ____ __ / |/ /_ __/ __/ __ \/ / Gleb Paharenko / /|_/ / // /\ \/ /_/ / /__ [EMAIL PROTECTED] /_/ /_/\_, /___/\___\_\___/ MySQL AB / Ensita.NET <___/ www.mysql.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]