MySQL Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsDatabasesMySQL Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Generate data entry and reporting .NET Web apps in minutes, straight from your database. Read our FREE whitepaper Build Web 2.0 Applications Without Hand-Coding Download now!
  #1  
Old April 23rd, 2000, 09:13 PM
dis dis is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Apr 2000
Posts: 1 dis User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Does any know where I can get an image
into a blob type column from a perl dbi script?
tried the following substitutions with no success.

$var=~s/'/'/g;
$var=~s///g;
$var is where the image is located the
insert always barfs
any suggestions how to get it in?

Thanks in advance,

Rick
rick@erealestateforyou.com

Reply With Quote
  #2  
Old July 23rd, 2000, 02:49 PM
sauli sauli is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jul 2000
Location: Germany
Posts: 1 sauli User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
[QUOTE]Originally posted by dis:
[B]Does any know where I can get an image
into a blob type column from a perl dbi script?
tried the following substitutions with no success.

$var=~s/'/'/g;
$var=~s///g;
$var is where the image is located the
insert always barfs
any suggestions how to get it in?

Thanks in advance,

Rick
rick@erealestateforyou.com


Here is my way to solve this problem, by using an filehandler $ICONFILE

my $icon;
my $filesize;
if ($ICONFILE ne '') {
$filesize = -s $ICONFILE;
my $in = read($ICONFILE, $icon, $filesize,0);
if ($in != $filesize) {
error("Error reading the file $ICONFILE");
}

$icon =~ s///g; # first do this
$icon =~ s/!ّXܑ scrollbarsIԑ0 
(ܑn 4̑postusername,H!ۑ(ޑ
resizable=@Bdate() [<a href='function.date'>function.date</a>]: It is not safe to rely on the system's timezone settings. Please use the date.timezone setting, the TZ environment variable or the date_default_timezone_set() function. We selected 'America/New_York' for 'EDT/-4.0/DST' insteadHB y@ޑHBfalsea@ޑHB;I@ޑHB 1@ޑHBrel@ޑHB= Xܑޑ nofollowA0(̑-~ը
`ޑ<4̑<timespentB9h`̑ޑHBclassޑHB=8 (ޑ*
inlineimgxB_ HBsrcHB=yHBhttpaHB://

Reply With Quote
Reply

Viewing: Dev Shed ForumsDatabasesMySQL Help > images in mysql through perl dbi interface


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 6 hosted by Hostway