At 17:41 +0000 2/1/02, Kevin Smith wrote: >Yes, it definitely is... I'm running Apache 1.3.22 on Linux RedHat 7.1 and >MySQL 3.23.47.
Does the script connect to the MySQL server using a MySQL account that has the FILE privilege? By the way, you didn't report the error message that you get. What is it? > >----- Original Message ----- >From: "Paul DuBois" <[EMAIL PROTECTED]> >To: "Gerald Clark" <[EMAIL PROTECTED]>; "Kevin Smith" ><[EMAIL PROTECTED]> >Cc: <[EMAIL PROTECTED]> >Sent: Friday, February 01, 2002 5:37 PM >Subject: Re: LOAD_FILE over SMB filesystems > > >> At 11:32 -0600 2/1/02, Gerald Clark wrote: >> >The single quotes around $image prevent perl from substituting the value. >> >You are trying to load a file named $imageFN. >> >$SQL = "UPDATE banners SET image=load_file(\"$imageFN\") where id=1"; >> >> But the single quotes are within a double-quoted string. So shouldn't >> the substitution still occur? >> >> Is the web server running on the same host as the MySQL server? >> >> > >> >Kevin Smith wrote: >> > >> >>After reading some other posts on inserting a image into a blob field, I >> >>tried using DBI to insert and the following does not work... >> >> >> >>I've double-checked the path and it is correct. >> >> >> >>$imageFN = '/var/www/htdocs/corporate/images/homenew.jpg'; >> >>$SQL = "UPDATE banners SET image=load_file('$imageFN') where id=1"; >> >> >> >>If I execute the same SQL statement at the MySQL > prompt it inserts >into >> >>the database fine... what am I doing wrong? >> >> >> >>Thanks, >> >> > > >>Kevin --------------------------------------------------------------------- Before posting, please check: http://www.mysql.com/manual.php (the manual) http://lists.mysql.com/ (the list archive) To request this thread, e-mail <[EMAIL PROTECTED]> To unsubscribe, e-mail <[EMAIL PROTECTED]> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php