List:General Discussion« Previous MessageNext Message »
From:Paul DuBois Date:September 15 1999 4:49pm
Subject:Re: load_file questions..
View as plain text  
At 11:19 AM -0400 9/15/99, James Manning wrote:
>[ Wednesday, September 15, 1999 ] Sean L. Gilley wrote:
>>    update attachments set 
>>attachment=load_file("/home/slg/mr_req.PDF") where num='811'
>>
>>    ERROR 1064: You have an error in your SQL syntax near 
>>'("/home/slg/mr_req.PDF") where num='811';' at line 1
>>
>>    mysql> describe attachments;
>>    +------------+-------------+------+-----+---------+-------+
>>    | Field      | Type        | Null | Key | Default | Extra |
>>    +------------+-------------+------+-----+---------+-------+
>>    | num        | int(11)     | YES  |     | NULL    |       |
>>    | title      | varchar(50) | YES  |     | NULL    |       |
>>    | attachment | blob        | YES  |     | NULL    |       |
>>    +------------+-------------+------+-----+---------+-------+
>>    3 rows in set (0.00 sec)
>
>Guesses:
>    a) underscore in filename is wildcard and confusing (hope not :)
>    b) num is int, so should be num=811 instead, not a string
>    c) pdf file larger than 64k and type MEDIUMBLOB (16M) or LONGBLOB
>       (4GB) needs to be used instead.
>
>I'm fascinated to find out what's up, though... certainly looks legal :)


It's legal but LOAD_FILE() was added in 3.23.0 and he's using 3.22.23b.

-- 
Paul DuBois, paul@stripped
Thread
load_file questions..Sean L. Gilley15 Sep
  • Re: load_file questions..James Manning15 Sep
    • Re: load_file questions..Paul DuBois15 Sep