RE: IMAGES/PICTURES-MYSQL
Hi! I have seen in this page http://www.blobstreaming.org/ but i think that it´s quite difficult. I want to put only the url of the image, and as you said the pictures o images might be in the server folder, but what is the folder? Thanks. -- View this message in context: http://www.nabble.com/IMAGES-PICTURES-MYSQL-tf4845682.html#a13923823 Sent from the MySQL - General mailing list archive at Nabble.com. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: IMAGES/PICTURES-MYSQL
Hello! I have tried the instructions that you explain to me. I have read also some issues but doens´t work. So i have done: ui:tableColumn binding=#{STOCKSOC.tableColumn6} headerText=image id=tableColumn6 sort=producto.image ui:imageHyperlink action=#{STOCKSOC.imageHyperlink1_action} binding=#{STOCKSOC.imageHyperlink1} id=imageHyperlink1 imageURL=C:\Documents and Settings\Ibai Leizea\Escritorio\gsg\SociedadGastronomica\web\IMAGES\im?imageid=#{currentRow.value['producto.id_prod']} text= url=C:\Documents and Settings\Ibai Leizea\Escritorio\gsg\SociedadGastronomica\web\IMAGES\im?imageid=#{currentRow.value['producto.id_prod']}/ /ui:tableColumn http://www.nabble.com/file/p13894350/1.jpg http://www.nabble.com/file/p13894350/2.jpg http://www.nabble.com/file/p13894350/3.jpg I don´t know if my proyect is in the correct path (C:\Documents and Settings\Ibai Leizea\Escritorio\gsg\SociedadGastronomica\) or the images (C:\Documents and Settings\Ibai Leizea\Escritorio\gsg\SociedadGastronomica\web\IMAGES). I have also proved copying the IMAGE folder in other path, but it doesn´t work. I don´t know specifically which is the server path. Thanks to everybody! Ibai -- View this message in context: http://www.nabble.com/IMAGES-PICTURES-MYSQL-tf4845682.html#a13894350 Sent from the MySQL - General mailing list archive at Nabble.com. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
IMAGES/PICTURES-MYSQL
Hello to everybody! I have read some messages about this topic but i haven´t resolved my problem yet. I am using mySQL Query Browser to make de schema. And i have a table (product) where there are some attributes (producto, precio, nUds,tipo)(spanish). All are relationated with one product (ex: heineken beer). So, i want to put another atribute image where i can put the image of all the products. But i have read that is imposible, that i have to put the path of the jpeg or gif, but i don´t know how. If anyone could help me i will be grateful. Attached is the image of my DB: http://www.nabble.com/file/p13863505/7.jpg Thank you very much! *Sorry for my english -- View this message in context: http://www.nabble.com/IMAGES-PICTURES-MYSQL-tf4845682.html#a13863505 Sent from the MySQL - General mailing list archive at Nabble.com. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: IMAGES/PICTURES-MYSQL
Hi, I have read some messages about this topic but i haven´t resolved my problem yet. I am using mySQL Query Browser to make de schema. And i have a table (product) where there are some attributes (producto, precio, nUds,tipo)(spanish). All are relationated with one product (ex: heineken beer). So, i want to put another atribute image where i can put the image of all the products. But i have read that is imposible, that i have to put the path of the jpeg or gif, but i don´t know how. If anyone could help me i will be grateful. Attached is the image of my DB: What makes you think it's impossible to store the actual image inside a blob field? Martijn Tonies Database Workbench - development tool for MySQL, and more! Upscene Productions http://www.upscene.com My thoughts: http://blog.upscene.com/martijn/ Database development questions? Check the forum! http://www.databasedevelopmentforum.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: IMAGES/PICTURES-MYSQL
Hello! I have read that. But i have not idea what i have to do. Because i´m amateur in this topic. Thank you -- View this message in context: http://www.nabble.com/IMAGES-PICTURES-MYSQL-tf4845682.html#a13865352 Sent from the MySQL - General mailing list archive at Nabble.com. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: IMAGES/PICTURES-MYSQL
It all comes down to what you are most comfortable with. What I have done is to name each image file with a serial number (1.jpg, 2.gif, 3.png, ...) and store the path along with the real name of the image in a table row. Doing it this way means that you don't need to program logic to convert a blob in order to serve it up with a script, you just need to programmatically create a link to the image file and let the web server do it. I find that easier to work with, and certainly easier to debug. Regards, Jerry Schwartz The Infoshop by Global Information Incorporated 195 Farmington Ave. Farmington, CT 06032 860.674.8796 / FAX: 860.674.8341 www.the-infoshop.com www.giiexpress.com www.etudes-marche.com -Original Message- From: puntapari [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 20, 2007 3:38 PM To: mysql@lists.mysql.com Subject: Re: IMAGES/PICTURES-MYSQL Hello! I have read that. But i have not idea what i have to do. Because i´m amateur in this topic. Thank you -- View this message in context: http://www.nabble.com/IMAGES-PICTURES- MYSQL-tf4845682.html#a13865352 Sent from the MySQL - General mailing list archive at Nabble.com. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] infoshop.com -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Images to MySql Database in PHP or JAVA
Hi, Have you try google ? http://www.google.fr/search?hl=frq=storing+image+in+mysqlbtnG=Recherche+Googlemeta= I see pretty much a lot of stuff there ;) btw, storing image in a table in considering a bad practice, let the filesystem handle it it does it more efficiently. I would suggesdt to write the image on the disk, and then store the path in you db with useful thing like image format, width, height, etc... HIMH. Christopher Molnar wrote: Hello list- I am programing both in Java and PHP. Can anyone point me to sample code for either on saving an image to a table? Thanks, -Chris -- Philippe Poelvoorde COS Trading Ltd. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Images to MySql Database in PHP or JAVA
Hello list- I am programing both in Java and PHP. Can anyone point me to sample code for either on saving an image to a table? Thanks, -Chris -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: Images to MySql Database in PHP or JAVA
Dear member,you can visit: http://dev.mysql.com/doc/connector/j/en/index.html http://dev.mysql.com/doc/mysql/en/php.html Hello list- I am programing both in Java and PHP. Can anyone point me to sample code for either on saving an image to a table? Thanks, -Chris -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Storing Images In MySQL
I figured I'd post a follow-up to the discussion earlier this week on issues relating to storing images in MySQL. In my opinion. Whether you store images in MySQL ultimately depends on whether you can setup a caching accelerator (like Squid) between you and your visitors. Storing images in the database adds a minimum of around 28 ms of latency. Cacheing makes this a mute point since images are once again stored as files. The main benefit is that you can more easily manage a large number of images by storing them in the database. Most people, those on shared hosting services, aren't going to likely have access to a caching accelerator, so originally storing images as files is probably going to be the best approach. The most common approach that I've seen is to create some sort of directory hiearchy and divide images in groups of 1000. Two other points came up while I was playing around with this. People on dial-up accessing test pages didn't notice any difference in performance - their average ping times to the server were around 120ms. I'm guessing their connection latency helped to buffer the difference between the two approaches. Pulling images from the database usually involves a script with a parameter that indicates which image to display. For example, like this: img src='http://www.myhost.com/display_image.php?id=5' Locally installed firewalls (Zone Alarm, McAfee Internet Security, and Norton Internet Security) all blocked the display of images that were served with a script like this. Getting the images to display required renaming the script, using Apache forcetype commands, and manually parsing the URL to get the image id to display. In other words, the url ended up like this: img src='http://www.myhost.com/display_image/5' Anyone who sends me a request can get copies of the scripts and help on trying to set something up to duplicate what I did. Thanks to everyone who helped me with this - especially Dreamwerx. -Ed -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
images from MySQL backend used with MS-Access 2000 frontend
Hi everyone, I am new to MySQL. I am starting a database project for a medium-sized medical office. I chose MS-Access (on 10-terminal pre-existing Win2K intranet) for rapid front-end dev and familiarity to the existing users. I plan to use MySQL on Linux server for backend for its speed, great support and ease of use. The database will consist of doctor's reports, schematic drawings and photos (500K JPGs and 50K PICTs). I am planning to implement that with BLOB or, alternatively, with file system while storing links to files. Later we may add webaccess through MySQL webserving or by using Access webserving options. Has anybody done anything similar? What is the best way to implement image storage (and, in future, movies, maybe)? Thanks a lot. yuri. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: images from MySQL backend used with MS-Access 2000 frontend
I would recommend storing the images on the filesystem and put the information about those images (along with the path to the image) in MySQL. If you plan to have lots of images, implement a nice logical directory structure to keep them in as in my experience linux ext2/3 is fast reading/writing files in that scenario and can be slow in retrieving files in a single directory containing large amounts of files. Cheers, Andrew -Original Message- From: Yuri Oleynikov [mailto:[EMAIL PROTECTED] Sent: Sunday 01 February 2004 16:33 To: [EMAIL PROTECTED] Subject: images from MySQL backend used with MS-Access 2000 frontend Hi everyone, I am new to MySQL. I am starting a database project for a medium-sized medical office. I chose MS-Access (on 10-terminal pre-existing Win2K intranet) for rapid front-end dev and familiarity to the existing users. I plan to use MySQL on Linux server for backend for its speed, great support and ease of use. The database will consist of doctor's reports, schematic drawings and photos (500K JPGs and 50K PICTs). I am planning to implement that with BLOB or, alternatively, with file system while storing links to files. Later we may add webaccess through MySQL webserving or by using Access webserving options. Has anybody done anything similar? What is the best way to implement image storage (and, in future, movies, maybe)? Thanks a lot. yuri. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: images from MySQL backend used with MS-Access 2000 frontend
Read this article for it's design on database storage.. I have several big implementations on this design which are fast, reliable and scalable (one of them in the medical field aswell) http://php.dreamwerx.net/forums/viewtopic.php?t=6 On Sun, 1 Feb 2004, Yuri Oleynikov wrote: Hi everyone, I am new to MySQL. I am starting a database project for a medium-sized medical office. I chose MS-Access (on 10-terminal pre-existing Win2K intranet) for rapid front-end dev and familiarity to the existing users. I plan to use MySQL on Linux server for backend for its speed, great support and ease of use. The database will consist of doctor's reports, schematic drawings and photos (500K JPGs and 50K PICTs). I am planning to implement that with BLOB or, alternatively, with file system while storing links to files. Later we may add webaccess through MySQL webserving or by using Access webserving options. Has anybody done anything similar? What is the best way to implement image storage (and, in future, movies, maybe)? Thanks a lot. yuri. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: inserting images to mysql - is it possible?
Armand- Why is it not recommended to store images in a database? I've not heard this... bob. At 09:51 PM 6/29/03 +0200, you wrote: Hi, You have to insert a new blob field where you can store binary data. But it is not recommanded to store images in a database. I recommande you to store images on a server filesystem and only the reference to the images in a database. Armand Digital Directory USA wrote: I am new to php and mysql, I have searched looked over and cannot find a way to do this... can it be done? I have set up the following in mysql. How do I upload the product images to the pPhoto column. Any suggestions? ds_produc Field Type Attributes Null Default Extra pID int(11)Noauto_increment catID int(11)No 0 pName varchar(70)Yes NULL pNum varchar(40)Yes NULL pTeaser textNo pDesc textYes NULL pPrice float(10,2)Yes NULL pSalesPrice float(10,2)No 0.00 pSale char(1)No pPhoto varchar(70)Yes NULL pPhotoWidth int(11)No 0 pPhotoHeight int(11)No 0 pSize varchar(35)Yes NULL pAvail char(1)No Y George Guebely Digital Directory USA, Inc -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] == The RediNews Network http://www.redinews.com/ Custom Financial Web Site Content phone: (516) 997-4343 == -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: inserting images to mysql - is it possible?
Bob: This question comes up over and over on the list ... do a search for 'images' of the list archive and you can read the accumulated pros and cons. Gerald Jensen - Original Message - From: Bob Ostermann [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, June 30, 2003 7:35 AM Subject: Re: inserting images to mysql - is it possible? Armand- Why is it not recommended to store images in a database? I've not heard this... bob. At 09:51 PM 6/29/03 +0200, you wrote: Hi, You have to insert a new blob field where you can store binary data. But it is not recommanded to store images in a database. I recommande you to store images on a server filesystem and only the reference to the images in a database. Armand Digital Directory USA wrote: I am new to php and mysql, I have searched looked over and cannot find a way to do this... can it be done? I have set up the following in mysql. How do I upload the product images to the pPhoto column. Any suggestions? ds_produc Field Type Attributes Null Default Extra pID int(11)Noauto_increment catID int(11)No 0 pName varchar(70)Yes NULL pNum varchar(40)Yes NULL pTeaser textNo pDesc textYes NULL pPrice float(10,2)Yes NULL pSalesPrice float(10,2)No 0.00 pSale char(1)No pPhoto varchar(70)Yes NULL pPhotoWidth int(11)No 0 pPhotoHeight int(11)No 0 pSize varchar(35)Yes NULL pAvail char(1)No Y George Guebely Digital Directory USA, Inc -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] == The RediNews Network http://www.redinews.com/ Custom Financial Web Site Content phone: (516) 997-4343 == -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: inserting images to mysql - is it possible?
Hi Gerald- I understand the pros and cons of db vs filesystem, and for images (static, rarely changing) it makes sense. I was pursuing any info about large chunk transfers or fragmented storage issues for large field tables. I'm working with a table containing historical information for 67,000 stocks and indexes. Each record has a data field (mediumtext) which contains the csv data for the stock (approx 30K). Each record needs to be updated each night (append that day's row of data to the mediumtext field) and need to be available ASAP to all web-servers (currently 4). The file is now about 1.5GB, and keeping/updating shadow copies of 70,000 files on 4+ nodes seemed like a problem which would not scale well. The read-side application will access less than 10% of the records in the database each day (but may access many records repeatedly). bob. At 07:50 AM 6/30/03 -0500, you wrote: Bob: This question comes up over and over on the list ... do a search for 'images' of the list archive and you can read the accumulated pros and cons. Gerald Jensen - Original Message - From: Bob Ostermann [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, June 30, 2003 7:35 AM Subject: Re: inserting images to mysql - is it possible? Armand- Why is it not recommended to store images in a database? I've not heard this... bob. At 09:51 PM 6/29/03 +0200, you wrote: Hi, You have to insert a new blob field where you can store binary data. But it is not recommanded to store images in a database. I recommande you to store images on a server filesystem and only the reference to the images in a database. Armand Digital Directory USA wrote: I am new to php and mysql, I have searched looked over and cannot find a way to do this... can it be done? I have set up the following in mysql. How do I upload the product images to the pPhoto column. Any suggestions? ds_produc Field Type Attributes Null Default Extra pID int(11)Noauto_increment catID int(11)No 0 pName varchar(70)Yes NULL pNum varchar(40)Yes NULL pTeaser textNo pDesc textYes NULL pPrice float(10,2)Yes NULL pSalesPrice float(10,2)No 0.00 pSale char(1)No pPhoto varchar(70)Yes NULL pPhotoWidth int(11)No 0 pPhotoHeight int(11)No 0 pSize varchar(35)Yes NULL pAvail char(1)No Y George Guebely Digital Directory USA, Inc -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] == The RediNews Network http://www.redinews.com/ Custom Financial Web Site Content phone: (516) 997-4343 == -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED] == The RediNews Network http://www.redinews.com/ Custom Financial Web Site Content phone: (516) 997-4343 == -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: inserting images to mysql - is it possible?
check out http://www.phpbuilder.com thay have a lot of things and that is one off them. -- eschew obfuscation. -Original Message- From: Digital Directory USA [mailto:[EMAIL PROTECTED] Sent: 29 June 2003 19:28 To: [EMAIL PROTECTED] Subject: inserting images to mysql - is it possible? I am new to php and mysql, I have searched looked over and cannot find a way to do this... can it be done? I have set up the following in mysql. How do I upload the product images to the pPhoto column. Any suggestions? ds_produc Field Type Attributes Null Default Extra pID int(11)Noauto_increment catID int(11)No 0 pName varchar(70)Yes NULL pNum varchar(40)Yes NULL pTeaser textNo pDesc textYes NULL pPrice float(10,2)Yes NULL pSalesPrice float(10,2)No 0.00 pSale char(1)No pPhoto varchar(70)Yes NULL pPhotoWidth int(11)No 0 pPhotoHeight int(11)No 0 pSize varchar(35)Yes NULL pAvail char(1)No Y George Guebely Digital Directory USA, Inc -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
inserting images to mysql - is it possible?
I am new to php and mysql, I have searched looked over and cannot find a way to do this... can it be done? I have set up the following in mysql. How do I upload the product images to the pPhoto column. Any suggestions? ds_produc Field Type Attributes Null Default Extra pID int(11)Noauto_increment catID int(11)No 0 pName varchar(70)Yes NULL pNum varchar(40)Yes NULL pTeaser textNo pDesc textYes NULL pPrice float(10,2)Yes NULL pSalesPrice float(10,2)No 0.00 pSale char(1)No pPhoto varchar(70)Yes NULL pPhotoWidth int(11)No 0 pPhotoHeight int(11)No 0 pSize varchar(35)Yes NULL pAvail char(1)No Y George Guebely Digital Directory USA, Inc
Re: inserting images to mysql - is it possible?
Hi, You have to insert a new blob field where you can store binary data. But it is not recommanded to store images in a database. I recommande you to store images on a server filesystem and only the reference to the images in a database. Armand Digital Directory USA wrote: I am new to php and mysql, I have searched looked over and cannot find a way to do this... can it be done? I have set up the following in mysql. How do I upload the product images to the pPhoto column. Any suggestions? ds_produc Field Type Attributes Null Default Extra pID int(11)Noauto_increment catID int(11)No 0 pName varchar(70)Yes NULL pNum varchar(40)Yes NULL pTeaser textNo pDesc textYes NULL pPrice float(10,2)Yes NULL pSalesPrice float(10,2)No 0.00 pSale char(1)No pPhoto varchar(70)Yes NULL pPhotoWidth int(11)No 0 pPhotoHeight int(11)No 0 pSize varchar(35)Yes NULL pAvail char(1)No Y George Guebely Digital Directory USA, Inc -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: inserting images to mysql - is it possible?
If you want to store images in the database, use a blob columntype.. And take a look at this example alot of people have based mysql binary storage off: http://www.php4.com/forums/viewtopic.php?t=6 good luck On Sun, 29 Jun 2003, Digital Directory USA wrote: I am new to php and mysql, I have searched looked over and cannot find a way to do this... can it be done? I have set up the following in mysql. How do I upload the product images to the pPhoto column. Any suggestions? ds_produc Field Type Attributes Null Default Extra pID int(11)Noauto_increment catID int(11)No 0 pName varchar(70)Yes NULL pNum varchar(40)Yes NULL pTeaser textNo pDesc textYes NULL pPrice float(10,2)Yes NULL pSalesPrice float(10,2)No 0.00 pSale char(1)No pPhoto varchar(70)Yes NULL pPhotoWidth int(11)No 0 pPhotoHeight int(11)No 0 pSize varchar(35)Yes NULL pAvail char(1)No Y George Guebely Digital Directory USA, Inc -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Storing Images in MySQL
Hey all, I'm using phpNewsAds and am wanting to store images in MySQL. I have this working on my Red Hat 7.2 Box and am moving to a new server running Red Hat 7.3 and of course, after moving the database the images are not being dispalyed. The database, however, is working. I'm assuming that maybe something in MySWL needs to me turned on and I have no idea what that is. Anyone have any ideas? Thanks. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: Storing Images in MySQL
I assumed to store the data in mysql you did something like uuencode and inserted that data into the db? Could the decode method be different on redhat 7.3? -Original Message- From: vernon [mailto:[EMAIL PROTECTED] Sent: Friday, March 28, 2003 2:19 PM To: [EMAIL PROTECTED] Subject: Storing Images in MySQL Hey all, I'm using phpNewsAds and am wanting to store images in MySQL. I have this working on my Red Hat 7.2 Box and am moving to a new server running Red Hat 7.3 and of course, after moving the database the images are not being dispalyed. The database, however, is working. I'm assuming that maybe something in MySWL needs to me turned on and I have no idea what that is. Anyone have any ideas? Thanks. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED] -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
RE: Storing Images in MySQL
I assumed to store the data in mysql you did something like uuencode and inserted that data into the db? Could the decode method be different on redhat 7.3? -Original Message- From: vernon [mailto:[EMAIL PROTECTED] Sent: Friday, March 28, 2003 2:19 PM To: [EMAIL PROTECTED] Subject: Storing Images in MySQL Hey all, I'm using phpNewsAds and am wanting to store images in MySQL. I have this working on my Red Hat 7.2 Box and am moving to a new server running Red Hat 7.3 and of course, after moving the database the images are not being dispalyed. The database, however, is working. I'm assuming that maybe something in MySWL needs to me turned on and I have no idea what that is. Anyone have any ideas? Thanks. Why not just store it in a binary field? That said, if you are going to use any programming language, why not store the pointer in the database and the image on the disk? Only case where this would be a problem would be if the numbers of images were so large that the file look up mechanism of the file system began to be a factor. In cases like that I use a tree of subdirectories tied to something like ISBM number. William R. Mussatto, Senior Systems Engineer Ph. 909-920-9154 ext. 27 FAX. 909-608-7061 -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe:http://lists.mysql.com/[EMAIL PROTECTED]
Re: images with mysql
sure you can. And i don't mind you disagreeing with me either =) Although, if the solution/site is meant to be used by other than people who know something about the webserver i don't think it's a good solution. I can imagine writing something that reads the htaccess-file and edits it... but i don't like the possible securtyissues with that. Besides... if you render a page with a selectbox from mysqltables and another with images and let the user match them together, it's idiotproof =) If you have a php(or whatever)-file wich sole purpouse is to check users rights and render images it can also always check if you have the right cookies. If you've been to the right previous page to see that picture, if not redirect to '/'; Do you get my point? I still believe that the blob i my saviour... (despite the obvious loss of performance) On Thu, 20 Mar 2003, B. van Ouwerkerk wrote: You can use other ways to protect your images from linking by others. Like with Apache and htaccess.. I don't agree with you on your opinion that it's easier to code. If you insert a link into your database all you have to do is retrieve it and push the link to the browser. B. At 20:18 20-03-2003 +0100, lasse wrote: hey all.. new to the list. Just my 5 cents... I think it's better to store images in the database, sure you loose a bit in performance, but it's easier to code. The way i've done it before is always a separate render.php (or what ever) that compares the users rights to view that image, get's the blob from the database, sets right content-type for the page and then renders the binary data. That way... you can control frames/design (direct links to images can be avoided) und so weiter... //lars On Thu, 20 Mar 2003, B. van Ouwerkerk wrote: I assume it is, have not tested it.. If you need to fetch the files from the database your app needs to wait until it has recieved the data. If you only store name/path info it will take less time to fetch the data, ship it off to the browser which can start fetching the images without connecting to the database again. Sounds pretty logical.. and it gets worse if your site is hosted by an ISP who is using a database server running on a seperate box.. B. At 21:35 20-03-2003 +, Lai Liu-yuan wrote: Well, this may be off topic. In my case, I store tens of thousands of images, gradually growing. All of them are quite small, most around 30*30 gray scale. Would it still be faster to store them on disk? On Thu, 20 Mar 2003 13:57:06 +0100 B. van Ouwerkerk [EMAIL PROTECTED] wrote: IMHO it's better to store a link. I have seen databases (not MySQL) getting corrupted because the file inserted was to big. For the visitor it doesn't really matter whether you put it into the database or not. A link is less difficult and you don't have to retrieve pictures from the database so it might be quicker.. B. At 18:34 20-03-2003 +, Lai Liu-yuan wrote: I am now having a database storing images of chinese characters for research purpose. I wrote a program to store and retrieve them. My images are of type ppm. This is how I designed my table: mysql describe poor; +++--+-+-+---+ | Field | Type | Null | Key | Default | Extra | +++--+-+-+---+ | cc | char(2) binary | | | | | | width | int(1) | YES | | NULL| | | height | int(1) | YES | | NULL| | | data | blob | YES | | NULL| | +++--+-+-+---+ Just have to be really careful in storing binary data. Hope this help. On Thu, 20 Mar 2003 10:34:19 +0100 [EMAIL PROTECTED] wrote: Hi! I have a problem with my MySQL I need to have some a images related with an item for example -- ! author ! date of birth an death ! image! -- How can I define the field for the images? I have read that LONGBLOB could be useful for large objct like images, but I can't understand how to set it in my database... Thank you in advance stefano -- S t e f a n o C a r d o Debian GNU-Linux user - 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]
RE: images with mysql
Don't forget that the images can be stored *outside* the root dir. Access them using ../../ until you reach your img dir. There's no way to get to the images directly then. Paul -Original Message- From: lasse [mailto:[EMAIL PROTECTED] Sent: Friday, March 21, 2003 12:14 AM To: unlisted-recipients:; no To-header on input Cc: [EMAIL PROTECTED] Subject: Re: images with mysql sure you can. And i don't mind you disagreeing with me either =) Although, if the solution/site is meant to be used by other than people who know something about the webserver i don't think it's a good solution. I can imagine writing something that reads the htaccess-file and edits it... but i don't like the possible securtyissues with that. Besides... if you render a page with a selectbox from mysqltables and another with images and let the user match them together, it's idiotproof =) If you have a php(or whatever)-file wich sole purpouse is to check users rights and render images it can also always check if you have the right cookies. If you've been to the right previous page to see that picture, if not redirect to '/'; Do you get my point? I still believe that the blob i my saviour... (despite the obvious loss of performance) On Thu, 20 Mar 2003, B. van Ouwerkerk wrote: You can use other ways to protect your images from linking by others. Like with Apache and htaccess.. I don't agree with you on your opinion that it's easier to code. If you insert a link into your database all you have to do is retrieve it and push the link to the browser. B. At 20:18 20-03-2003 +0100, lasse wrote: hey all.. new to the list. Just my 5 cents... I think it's better to store images in the database, sure you loose a bit in performance, but it's easier to code. The way i've done it before is always a separate render.php (or what ever) that compares the users rights to view that image, get's the blob from the database, sets right content-type for the page and then renders the binary data. That way... you can control frames/design (direct links to images can be avoided) und so weiter... //lars On Thu, 20 Mar 2003, B. van Ouwerkerk wrote: I assume it is, have not tested it.. If you need to fetch the files from the database your app needs to wait until it has recieved the data. If you only store name/path info it will take less time to fetch the data, ship it off to the browser which can start fetching the images without connecting to the database again. Sounds pretty logical.. and it gets worse if your site is hosted by an ISP who is using a database server running on a seperate box.. B. At 21:35 20-03-2003 +, Lai Liu-yuan wrote: Well, this may be off topic. In my case, I store tens of thousands of images, gradually growing. All of them are quite small, most around 30*30 gray scale. Would it still be faster to store them on disk? On Thu, 20 Mar 2003 13:57:06 +0100 B. van Ouwerkerk [EMAIL PROTECTED] wrote: IMHO it's better to store a link. I have seen databases (not MySQL) getting corrupted because the file inserted was to big. For the visitor it doesn't really matter whether you put it into the database or not. A link is less difficult and you don't have to retrieve pictures from the database so it might be quicker.. B. At 18:34 20-03-2003 +, Lai Liu-yuan wrote: I am now having a database storing images of chinese characters for research purpose. I wrote a program to store and retrieve them. My images are of type ppm. This is how I designed my table: mysql describe poor; +++--+-+-+---+ | Field | Type | Null | Key | Default | Extra | +++--+-+-+---+ | cc | char(2) binary | | | | | | width | int(1) | YES | | NULL| | | height | int(1) | YES | | NULL| | | data | blob | YES | | NULL| | +++--+-+-+---+ Just have to be really careful in storing binary data. Hope this help. On Thu, 20 Mar 2003 10:34:19 +0100 [EMAIL PROTECTED] wrote: Hi! I have a problem with my MySQL I need to have some a images related with an item for example -- ! author ! date of birth an death ! image! -- How can I define the field for the images? I have read that LONGBLOB could be useful for large objct like images, but I can't understand how to set it in my database... Thank you in advance stefano -- S t e f a n o C a r d o
Re: images with mysql
Not an issue since you don't need to edit the htaccess file for every file. You set it for the whole directory. The only reason for preventing ppl to access files would be theft of bandwith. If you worry about ppl being able to get the images then you shouldn't publish them at all. You can't protect them from being dumped with printscreen. Another solution would be to change the the path at random and copy all images to the new location while you copy a special image on the old location. You have no idea how fast ppl will stop using your pics if they have the text stolen from ... where you put your domainname on the dots. This would require you to have the path to the file in your code. HTTP REFERER is not always set correctly so I wouldn't trust that to much. B. At 09:13 21-03-2003 +0100, lasse wrote: sure you can. And i don't mind you disagreeing with me either =) Although, if the solution/site is meant to be used by other than people who know something about the webserver i don't think it's a good solution. I can imagine writing something that reads the htaccess-file and edits it... but i don't like the possible securtyissues with that. Besides... if you render a page with a selectbox from mysqltables and another with images and let the user match them together, it's idiotproof =) If you have a php(or whatever)-file wich sole purpouse is to check users rights and render images it can also always check if you have the right cookies. If you've been to the right previous page to see that picture, if not redirect to '/'; Do you get my point? I still believe that the blob i my saviour... (despite the obvious loss of performance) On Thu, 20 Mar 2003, B. van Ouwerkerk wrote: You can use other ways to protect your images from linking by others. Like with Apache and htaccess.. I don't agree with you on your opinion that it's easier to code. If you insert a link into your database all you have to do is retrieve it and push the link to the browser. B. - 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
Re: images with mysql
Hi! I have a problem with my MySQL I need to have some a images related with an item for example -- ! author ! date of birth an death ! image! -- How can I define the field for the images? I have read that LONGBLOB could be useful for large objct like images, but I can't understand how to set it in my database... Thank you in advance stefano -- S t e f a n o C a r d o Debian GNU-Linux user - 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
RE: images with mysql
I had a go with putting a image into MySQL and it did not work. But what I did do is put the directory and image location /image/smile.jpg. This is very good way to use the index of the db and the speed of the file structure. Sorry if this was not what you were looking for but I hope it helps a bit. Simon -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: 20 March 2003 09:34 To: [EMAIL PROTECTED] Subject: Re: images with mysql Hi! I have a problem with my MySQL I need to have some a images related with an item for example -- ! author ! date of birth an death ! image! -- How can I define the field for the images? I have read that LONGBLOB could be useful for large objct like images, but I can't understand how to set it in my database... Thank you in advance stefano -- S t e f a n o C a r d o Debian GNU-Linux user - 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 - 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
Re: images with mysql
I am now having a database storing images of chinese characters for research purpose. I wrote a program to store and retrieve them. My images are of type ppm. This is how I designed my table: mysql describe poor; +++--+-+-+---+ | Field | Type | Null | Key | Default | Extra | +++--+-+-+---+ | cc | char(2) binary | | | | | | width | int(1) | YES | | NULL| | | height | int(1) | YES | | NULL| | | data | blob | YES | | NULL| | +++--+-+-+---+ Just have to be really careful in storing binary data. Hope this help. On Thu, 20 Mar 2003 10:34:19 +0100 [EMAIL PROTECTED] wrote: Hi! I have a problem with my MySQL I need to have some a images related with an item for example -- ! author ! date of birth an death ! image! -- How can I define the field for the images? I have read that LONGBLOB could be useful for large objct like images, but I can't understand how to set it in my database... Thank you in advance stefano -- S t e f a n o C a r d o Debian GNU-Linux user - 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 - 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
Re: images with mysql
IMHO it's better to store a link. I have seen databases (not MySQL) getting corrupted because the file inserted was to big. For the visitor it doesn't really matter whether you put it into the database or not. A link is less difficult and you don't have to retrieve pictures from the database so it might be quicker.. B. At 18:34 20-03-2003 +, Lai Liu-yuan wrote: I am now having a database storing images of chinese characters for research purpose. I wrote a program to store and retrieve them. My images are of type ppm. This is how I designed my table: mysql describe poor; +++--+-+-+---+ | Field | Type | Null | Key | Default | Extra | +++--+-+-+---+ | cc | char(2) binary | | | | | | width | int(1) | YES | | NULL| | | height | int(1) | YES | | NULL| | | data | blob | YES | | NULL| | +++--+-+-+---+ Just have to be really careful in storing binary data. Hope this help. On Thu, 20 Mar 2003 10:34:19 +0100 [EMAIL PROTECTED] wrote: Hi! I have a problem with my MySQL I need to have some a images related with an item for example -- ! author ! date of birth an death ! image! -- How can I define the field for the images? I have read that LONGBLOB could be useful for large objct like images, but I can't understand how to set it in my database... Thank you in advance stefano -- S t e f a n o C a r d o Debian GNU-Linux user - 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
Re: images with mysql
Well, this may be off topic. In my case, I store tens of thousands of images, gradually growing. All of them are quite small, most around 30*30 gray scale. Would it still be faster to store them on disk? On Thu, 20 Mar 2003 13:57:06 +0100 B. van Ouwerkerk [EMAIL PROTECTED] wrote: IMHO it's better to store a link. I have seen databases (not MySQL) getting corrupted because the file inserted was to big. For the visitor it doesn't really matter whether you put it into the database or not. A link is less difficult and you don't have to retrieve pictures from the database so it might be quicker.. B. At 18:34 20-03-2003 +, Lai Liu-yuan wrote: I am now having a database storing images of chinese characters for research purpose. I wrote a program to store and retrieve them. My images are of type ppm. This is how I designed my table: mysql describe poor; +++--+-+-+---+ | Field | Type | Null | Key | Default | Extra | +++--+-+-+---+ | cc | char(2) binary | | | | | | width | int(1) | YES | | NULL| | | height | int(1) | YES | | NULL| | | data | blob | YES | | NULL| | +++--+-+-+---+ Just have to be really careful in storing binary data. Hope this help. On Thu, 20 Mar 2003 10:34:19 +0100 [EMAIL PROTECTED] wrote: Hi! I have a problem with my MySQL I need to have some a images related with an item for example -- ! author ! date of birth an death ! image! -- How can I define the field for the images? I have read that LONGBLOB could be useful for large objct like images, but I can't understand how to set it in my database... Thank you in advance stefano -- S t e f a n o C a r d o Debian GNU-Linux user - 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 - 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
Re: images with mysql
Lai Liu-yuan wrote: Well, this may be off topic. In my case, I store tens of thousands of images, gradually growing. All of them are quite small, most around 30*30 gray scale. Would it still be faster to store them on disk? In most cases yes. We have over 3.5 million images stored and mananaging them from the database side would be almost impossible. There are many benifits to using the file system instead of the database. 1. You can archive the images on cd/dvd/tape as new ones are received/added. 2. Try converting or moving databases with 200GB of blob files. 3. The larger the database, the longer it takes to retreive information. 4. Data from a database is retreived one row at a time so you have to wait for each image. Storing the path in the database allows you to fetch a row, spawn a child process to fetch the image, and continue to fetch rows from the database while the child processes handle getting the images. 5. Mysql will not cache the images. The OS however will cache disk reads. 6. The database has a finite set of resources. You can add many file servers, each specific to what type of image you're pulling. We store stuff by date so we know to pull 1998 images from fileserver a and 1999 images from fileserver b, etc... The OS on each fileserver can then cache what is requested most often. Good luck! walt - 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
Re: images with mysql
I assume it is, have not tested it.. If you need to fetch the files from the database your app needs to wait until it has recieved the data. If you only store name/path info it will take less time to fetch the data, ship it off to the browser which can start fetching the images without connecting to the database again. Sounds pretty logical.. and it gets worse if your site is hosted by an ISP who is using a database server running on a seperate box.. B. At 21:35 20-03-2003 +, Lai Liu-yuan wrote: Well, this may be off topic. In my case, I store tens of thousands of images, gradually growing. All of them are quite small, most around 30*30 gray scale. Would it still be faster to store them on disk? On Thu, 20 Mar 2003 13:57:06 +0100 B. van Ouwerkerk [EMAIL PROTECTED] wrote: IMHO it's better to store a link. I have seen databases (not MySQL) getting corrupted because the file inserted was to big. For the visitor it doesn't really matter whether you put it into the database or not. A link is less difficult and you don't have to retrieve pictures from the database so it might be quicker.. B. At 18:34 20-03-2003 +, Lai Liu-yuan wrote: I am now having a database storing images of chinese characters for research purpose. I wrote a program to store and retrieve them. My images are of type ppm. This is how I designed my table: mysql describe poor; +++--+-+-+---+ | Field | Type | Null | Key | Default | Extra | +++--+-+-+---+ | cc | char(2) binary | | | | | | width | int(1) | YES | | NULL| | | height | int(1) | YES | | NULL| | | data | blob | YES | | NULL| | +++--+-+-+---+ Just have to be really careful in storing binary data. Hope this help. On Thu, 20 Mar 2003 10:34:19 +0100 [EMAIL PROTECTED] wrote: Hi! I have a problem with my MySQL I need to have some a images related with an item for example -- ! author ! date of birth an death ! image! -- How can I define the field for the images? I have read that LONGBLOB could be useful for large objct like images, but I can't understand how to set it in my database... Thank you in advance stefano -- S t e f a n o C a r d o Debian GNU-Linux user - 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 - 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 - 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
Re: images with mysql
hey all.. new to the list. Just my 5 cents... I think it's better to store images in the database, sure you loose a bit in performance, but it's easier to code. The way i've done it before is always a separate render.php (or what ever) that compares the users rights to view that image, get's the blob from the database, sets right content-type for the page and then renders the binary data. That way... you can control frames/design (direct links to images can be avoided) und so weiter... //lars On Thu, 20 Mar 2003, B. van Ouwerkerk wrote: I assume it is, have not tested it.. If you need to fetch the files from the database your app needs to wait until it has recieved the data. If you only store name/path info it will take less time to fetch the data, ship it off to the browser which can start fetching the images without connecting to the database again. Sounds pretty logical.. and it gets worse if your site is hosted by an ISP who is using a database server running on a seperate box.. B. At 21:35 20-03-2003 +, Lai Liu-yuan wrote: Well, this may be off topic. In my case, I store tens of thousands of images, gradually growing. All of them are quite small, most around 30*30 gray scale. Would it still be faster to store them on disk? On Thu, 20 Mar 2003 13:57:06 +0100 B. van Ouwerkerk [EMAIL PROTECTED] wrote: IMHO it's better to store a link. I have seen databases (not MySQL) getting corrupted because the file inserted was to big. For the visitor it doesn't really matter whether you put it into the database or not. A link is less difficult and you don't have to retrieve pictures from the database so it might be quicker.. B. At 18:34 20-03-2003 +, Lai Liu-yuan wrote: I am now having a database storing images of chinese characters for research purpose. I wrote a program to store and retrieve them. My images are of type ppm. This is how I designed my table: mysql describe poor; +++--+-+-+---+ | Field | Type | Null | Key | Default | Extra | +++--+-+-+---+ | cc | char(2) binary | | | | | | width | int(1) | YES | | NULL| | | height | int(1) | YES | | NULL| | | data | blob | YES | | NULL| | +++--+-+-+---+ Just have to be really careful in storing binary data. Hope this help. On Thu, 20 Mar 2003 10:34:19 +0100 [EMAIL PROTECTED] wrote: Hi! I have a problem with my MySQL I need to have some a images related with an item for example -- ! author ! date of birth an death ! image! -- How can I define the field for the images? I have read that LONGBLOB could be useful for large objct like images, but I can't understand how to set it in my database... Thank you in advance stefano -- S t e f a n o C a r d o Debian GNU-Linux user - 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 - 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 - 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 -- -BEGIN GEEK CODE BLOCK- Version: 3.1 (2002 update) GCM/GCS/GMU/ d+ s++:++ a-- C++() UBLAIS+() P+ L+(-) E--- W+++ N+ o-- K w O- M- V- PS(+++) PE++ Y PGP- t 5+ X++ R- tv+ b+ DI+++ D- G e h++ r% y++ --END GEEK CODE BLOCK-- - 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:
Re: images with mysql
You can use other ways to protect your images from linking by others. Like with Apache and htaccess.. I don't agree with you on your opinion that it's easier to code. If you insert a link into your database all you have to do is retrieve it and push the link to the browser. B. At 20:18 20-03-2003 +0100, lasse wrote: hey all.. new to the list. Just my 5 cents... I think it's better to store images in the database, sure you loose a bit in performance, but it's easier to code. The way i've done it before is always a separate render.php (or what ever) that compares the users rights to view that image, get's the blob from the database, sets right content-type for the page and then renders the binary data. That way... you can control frames/design (direct links to images can be avoided) und so weiter... //lars On Thu, 20 Mar 2003, B. van Ouwerkerk wrote: I assume it is, have not tested it.. If you need to fetch the files from the database your app needs to wait until it has recieved the data. If you only store name/path info it will take less time to fetch the data, ship it off to the browser which can start fetching the images without connecting to the database again. Sounds pretty logical.. and it gets worse if your site is hosted by an ISP who is using a database server running on a seperate box.. B. At 21:35 20-03-2003 +, Lai Liu-yuan wrote: Well, this may be off topic. In my case, I store tens of thousands of images, gradually growing. All of them are quite small, most around 30*30 gray scale. Would it still be faster to store them on disk? On Thu, 20 Mar 2003 13:57:06 +0100 B. van Ouwerkerk [EMAIL PROTECTED] wrote: IMHO it's better to store a link. I have seen databases (not MySQL) getting corrupted because the file inserted was to big. For the visitor it doesn't really matter whether you put it into the database or not. A link is less difficult and you don't have to retrieve pictures from the database so it might be quicker.. B. At 18:34 20-03-2003 +, Lai Liu-yuan wrote: I am now having a database storing images of chinese characters for research purpose. I wrote a program to store and retrieve them. My images are of type ppm. This is how I designed my table: mysql describe poor; +++--+-+-+---+ | Field | Type | Null | Key | Default | Extra | +++--+-+-+---+ | cc | char(2) binary | | | | | | width | int(1) | YES | | NULL| | | height | int(1) | YES | | NULL| | | data | blob | YES | | NULL| | +++--+-+-+---+ Just have to be really careful in storing binary data. Hope this help. On Thu, 20 Mar 2003 10:34:19 +0100 [EMAIL PROTECTED] wrote: Hi! I have a problem with my MySQL I need to have some a images related with an item for example -- ! author ! date of birth an death ! image! -- How can I define the field for the images? I have read that LONGBLOB could be useful for large objct like images, but I can't understand how to set it in my database... Thank you in advance stefano -- S t e f a n o C a r d o Debian GNU-Linux user - 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 - 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 - 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 -- -BEGIN GEEK CODE BLOCK- Version: 3.1 (2002 update) GCM/GCS/GMU/ d+ s++:++ a-- C++() UBLAIS+() P+ L+(-) E--- W+++ N+ o-- K w O- M- V- PS(+++) PE++ Y PGP- t 5+ X++ R- tv+ b+ DI+++ D- G e h++ r% y++ --END GEEK CODE BLOCK--
Storing images in MySQL bad idea, performance-wise?
I'm working on a simple content management system that uses PHP and MySQL for updating a web site's text (stored in a MySQL database). (The PHP scripts that do the updating (my stuf) live on one web server, the actual DB data to be updated (my client's stuff) live on another.) So far, I've only had to he able to update the text content of a site--therefore, I've only had to bother to store textual data in the client's DB. But now the client wants to be able to upload/change/delete certain pictures on their web site--using my CMS tool--so I am faced with the following problem: Do I store all such images in the DB? (Which I understand reduces performance.) Or do I--somehow--store the images as files on the client's web server? And if so, how? (Because my PHP scripts are being executed on a different server.) ...Rene --- René Fournier, [EMAIL PROTECTED] Toll-free +1.888.886.2754 Tel +1.403.291.3601 Fax +1.403.250.5228 www.smartslitters.com SmartSlitters International #33, 1339 - 40th Ave NE Calgary AB T2E 8N6 Canada - 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
Re: Storing images in MySQL bad idea, performance-wise?
Rene: I think a good deal depends on the size of the image files themselves. There are a number of apps that store small files (i.e.: icons, small gif's, etc.), which seems to make sense. Larger files may be problematic. There was quite a discussion on this issue here just last week ... do a search of the list archive for 'blob versus file' and read some informed opinions. Gerald Jensen - Original Message - From: René Fournier [EMAIL PROTECTED] To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Monday, July 08, 2002 5:34 PM Subject: Storing images in MySQL bad idea, performance-wise? I'm working on a simple content management system that uses PHP and MySQL for updating a web site's text (stored in a MySQL database). (The PHP scripts that do the updating (my stuf) live on one web server, the actual DB data to be updated (my client's stuff) live on another.) So far, I've only had to he able to update the text content of a site--therefore, I've only had to bother to store textual data in the client's DB. But now the client wants to be able to upload/change/delete certain pictures on their web site--using my CMS tool--so I am faced with the following problem: Do I store all such images in the DB? (Which I understand reduces performance.) Or do I--somehow--store the images as files on the client's web server? And if so, how? (Because my PHP scripts are being executed on a different server.) ...Rene --- René Fournier, [EMAIL PROTECTED] Toll-free +1.888.886.2754 Tel +1.403.291.3601 Fax +1.403.250.5228 www.smartslitters.com SmartSlitters International #33, 1339 - 40th Ave NE Calgary AB T2E 8N6 Canada - 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 - 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
Images in MySql
Eric, Monday, January 28, 2002, 2:30:47 PM, you wrote: ETK Eric here from South Africa. ETK I'm fairly new at using mysql and need to access images via a php website. ETK What is the best way to store images or reference to images like jpg and ETK gifs in a mysql db? Also what would the sql ETK querie look like to call the and view the image. Is there any documentation ETK specificaly geared towards to images in mysql. You can store images in database using blob data type, see http://www.mysql.com/doc/B/L/BLOB.html In other way, you can store references to images. -- For technical support contracts, goto https://order.mysql.com/ This email is sponsored by Ensita.net http://www.ensita.net/ __ ___ ___ __ / |/ /_ __/ __/ __ \/ /Victoria Reznichenko / /|_/ / // /\ \/ /_/ / /__ [EMAIL PROTECTED] /_/ /_/\_, /___/\___\_\___/ MySQL AB / Ensita.net ___/ www.mysql.com - 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
Images in MySql
Hi all. Eric here from South Africa. I'm fairly new at using mysql and need to access images via a php website. What is the best way to store images or reference to images like jpg and gifs in a mysql db? Also what would the sql querie look like to call the and view the image. Is there any documentation specificaly geared towards to images in mysql. Any help on the matter would be greatly appreciated. Thank you Eric Torr Klopper Thrasher Technologies +27 82 219 3994 - 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
RE: Images in MySql
Eric, Generally you would store references to the images in the database as a full or partial pathname. You can store binary data in the db itself using the BLOB type but this is not necessarily the most efficient approach to take John Lodge -Original Message- From: Eric Torr Klopper [mailto:[EMAIL PROTECTED]] Sent: Monday, January 28, 2002 12:31 PM To: [EMAIL PROTECTED] Subject: Images in MySql Hi all. Eric here from South Africa. I'm fairly new at using mysql and need to access images via a php website. What is the best way to store images or reference to images like jpg and gifs in a mysql db? Also what would the sql querie look like to call the and view the image. Is there any documentation specificaly geared towards to images in mysql. Any help on the matter would be greatly appreciated. Thank you Eric Torr Klopper Thrasher Technologies +27 82 219 3994 - 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 - 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
storing images in MYSQl database
hi , how to store the images in mysql database and how to retrieve the images onto teh VB form.how to do it. please mail me the suggestions. thanx phani = S.V.PHANI KRISHNA STESALIT LIMITED 10,BELVEDERE ROAD, ALIPORE KOLKATTA - 700027 PHONE NUMBERS 4498346,4498345,4498342 MAIL: [EMAIL PROTECTED],[EMAIL PROTECTED] Do You Yahoo!? Send a newsletter, share photos files, conduct polls, organize chat events. Visit http://in.groups.yahoo.com - 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
Re: storing images in MYSQl database
phani krishna writes: how to store the images in mysql database and how to retrieve the images onto teh VB form.how to do it. What about it? Lemme guess, you're wondering how to do it, right? Two points: 1) Images are just like any other data. Just store them in a BLOB. As with all other data you need to escape certain characters, but hopefully you knew that already. 2) Don't store that sort of data in the database. There are a larg number of reasons why this is a bad thing to do. Store them in the file system and just let your database contain information about the images, such as where to find them in the file system. //C -- Carl Troein - Círdan / Istari-PixelMagic - UIN 16353280 [EMAIL PROTECTED] | http://pixelmagic.dyndns.org/~cirdan/ Amiga user since '89, and damned proud of it too. - 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
inserting images in mysql tables
I am new to mysql. I am attempting to place images in one of my columns. As for my table structure, I have gotten as far as: image blob NOT NULL, How should I proceed? Thanks a bunch Get free email and a permanent address at http://www.netaddress.com/?N=1 - 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
Re: inserting images in mysql tables
you should probably just store the images on your server, and provide the location to the image in the table...much quicker. Tyler - Original Message - From: Felicia [EMAIL PROTECTED] To: mysql post [EMAIL PROTECTED] Sent: Tuesday, June 19, 2001 11:03 AM Subject: inserting images in mysql tables I am new to mysql. I am attempting to place images in one of my columns. As for my table structure, I have gotten as far as: image blob NOT NULL, How should I proceed? Thanks a bunch Get free email and a permanent address at http://www.netaddress.com/?N=1 - 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 - 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
Re: inserting images in mysql tables
IMHO, (take it for what it is worth) You shouldn't. Store a reference to the image in the database.(either a file system reference, or if you are doing HTML, store the URL) I've yet to see a good reason for stuffing an image in a database. In most cases the OS/file system will handle the image faster than the database will. Sorry, probably not the answer you wanted. Cal * * Cal Evans * Senior Internet Dreamer * http://www.calevans.com * - Original Message - From: Felicia [EMAIL PROTECTED] To: mysql post [EMAIL PROTECTED] Sent: Tuesday, June 19, 2001 11:03 AM Subject: inserting images in mysql tables I am new to mysql. I am attempting to place images in one of my columns. As for my table structure, I have gotten as far as: image blob NOT NULL, How should I proceed? Thanks a bunch Get free email and a permanent address at http://www.netaddress.com/?N=1 - 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 - 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
images and mysql
Dear Sir/Madam, I use a mysql database on the web and use php to get information from it. Now I want to use pictures/images in the database. I've included a php script The information I get from the mysql database in a while statement. My question is, how do I get the picture available on the web, must I put this in the mysql-database and how do I do this? If anyone can help me, than I hope to get an e-mail from you at: [EMAIL PROTECTED] Thanks, Johan. Student ? require ('connect2.php'); echo html; echo 'body bgcolor=#FF text=#00 background=Afbeelding1.jpg bgproperties=fixed'; Echo h2Het Sportprogramma 2001/h2; echo br; $result = mysql_query ('SELECT * from Programma') or die (Invalid query); echo 'table border=2 width=100%'; while ($row=mysql_fetch_row($result)){ echo 'trtd width=16%'; echo $row[5]; echo /td; echo 'td width=16%'; echo $row[6]; echo /td; echo 'td width=16%'; echo $row[4]; echo /td; echo 'td width=16%'; echo $row[1]; echo /td; echo 'td width=16%'; echo $row[2]; echo /td; echo 'td width=16%'; echo $row[3]; echo /td/tr;} echo /table; mysql_close ($link); echo /body; echo /html; ?
Re: images and mysql
This topic has been discussed many times on the PHP General (archived at http://marc.theaimsgroup.com/?l=php-general) and PHP DB (archived at http://marc.theaimsgroup.com/?l=php-db) mailing lists. Search the archives for the terms 'MySQL images blob' and you will find a wealth of posts. Good Luck! --zak J.Heegsma wrote: I use a mysql database on the web and use php to get information from it. Now I want to use pictures/images in the database. I've included a php script The information I get from the mysql database in a while statement. My question is, how do I get the picture available on the web, must I put this in the mysql-database and how do I do this? [snip] - 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
Re: is it possible to store images in mysql db?
It's actually pretty simple. Here's an excellent tutorial on how to do it with PHP. http://www.oreillynet.com/pub/a/php/2000/09/15/php_mysql.html Enjoy -- it's pretty cool what you can do with it. -- jon From: Nikhilesh Haval [EMAIL PROTECTED] Organization: University of Sheffield Reply-To: [EMAIL PROTECTED] Date: Sat, 17 Feb 2001 11:43:20 + To: mysql list [EMAIL PROTECTED] Subject: is it possible to store images in mysql db? I want to store different file formats in a database like images (*.jpg) or audio files (*.mp3). Is it possible to do so in mysql? -Nikhilesh - 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 - 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
is it possible to store images in mysql db?
I want to store different file formats in a database like images (*.jpg) or audio files (*.mp3). Is it possible to do so in mysql? -Nikhilesh - 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
Re: is it possible to store images in mysql db?
On Sat, 17 Feb 2001, Nikhilesh Haval wrote: I want to store different file formats in a database like images (*.jpg) or audio files (*.mp3). Is it possible to do so in mysql? Yeah, that's what BLOB is for--but why would you want to do that? Why not just store the path in the table, and the binary somewhere else? -- /"\ \ /ASCII RIBBON CAMPAIGN X AGAINST HTML EMAIL / \AND POSTINGS - 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
Re: is it possible to store images in mysql db?
Actually ... there are often some good reasons one might want to store pictures in BLOBs. For example, our integrated application gives the administrators at our various customer sites the ability to associate a series of icons on a toolbar with a wide range of programmable functions. In addition to the functions themselves, we want the customer's Administrator to be able to associate standard .ICO or .BMP icon graphics with the various toolbar positions and the functions they have decided to associate with them. We also want the customer's Administrator to be able to use standard icon graphic editors to create their own pictures, and use our utility program to slam them into the BLOB. If we store them as seperate binaries, then we have to keep track of the path to them. On an NT network, any goofball (usually with Admin privs!) can use Explorer to find/move/delete these files. If we store them as BLOBs in the database, we know exactly where they are. G. Jensen - Original Message - From: "clay bond" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Saturday, February 17, 2001 8:16 AM Subject: Re: is it possible to store images in mysql db? On Sat, 17 Feb 2001, Nikhilesh Haval wrote: I want to store different file formats in a database like images (*.jpg) or audio files (*.mp3). Is it possible to do so in mysql? Yeah, that's what BLOB is for--but why would you want to do that? Why not just store the path in the table, and the binary somewhere else? -- /"\ \ / ASCII RIBBON CAMPAIGN X AGAINST HTML EMAIL / \ AND POSTINGS - 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 - 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
Re: is it possible to store images in mysql db?
Actually, blobs are stored in files in data directory. You can store your binary files in data directory, if you wish. - Original Message - From: Gerald R. Jensen [EMAIL PROTECTED] To: clay bond [EMAIL PROTECTED]; [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Sent: Saturday, February 17, 2001 5:52 PM Subject: Re: is it possible to store images in mysql db? Actually ... there are often some good reasons one might want to store pictures in BLOBs. For example, our integrated application gives the administrators at our various customer sites the ability to associate a series of icons on a toolbar with a wide range of programmable functions. In addition to the functions themselves, we want the customer's Administrator to be able to associate standard .ICO or .BMP icon graphics with the various toolbar positions and the functions they have decided to associate with them. We also want the customer's Administrator to be able to use standard icon graphic editors to create their own pictures, and use our utility program to slam them into the BLOB. If we store them as seperate binaries, then we have to keep track of the path to them. On an NT network, any goofball (usually with Admin privs!) can use Explorer to find/move/delete these files. If we store them as BLOBs in the database, we know exactly where they are. G. Jensen - Original Message - From: "clay bond" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Saturday, February 17, 2001 8:16 AM Subject: Re: is it possible to store images in mysql db? On Sat, 17 Feb 2001, Nikhilesh Haval wrote: I want to store different file formats in a database like images (*.jpg) or audio files (*.mp3). Is it possible to do so in mysql? Yeah, that's what BLOB is for--but why would you want to do that? Why not just store the path in the table, and the binary somewhere else? -- /"\ \ / ASCII RIBBON CAMPAIGN X AGAINST HTML EMAIL / \ AND POSTINGS - 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 - 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 - 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
saving images from mysql to file
How do I save an images to a unix file that is saved in mysql? I know how to view the image with PHP and I know how to write a file to unix. I just can't get the data from mysql into a format that will allow me to read it then write it. - 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
Re: saving images from mysql to file
Firstly, I'm not exactly sure of what you are trying to do but in any case check out the blob column type in the mysql manual. Also, you are probably better off storing the image on disk and only store the URL in the database. Whichever the case, good examples can usually be found at www.devshed.com - Original Message - From: "Phillip M.(Mike) Bishop" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, February 07, 2001 4:01 Subject: saving images from mysql to file How do I save an images to a unix file that is saved in mysql? I know how to view the image with PHP and I know how to write a file to unix. I just can't get the data from mysql into a format that will allow me to read it then write it. - 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 - 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
Re: saving images from mysql to file
Ok I have 2000 images in a database that I want to move out of the database and save the image as a file and place the url to the image in the database. But I can\'t figure out how to get them out and written to a file to do this. You Wrote: Firstly, I\'m not exactly sure of what you are trying to do but in any case check out the blob column type in the mysql manual. Also, you are probably better off storing the image on disk and only store the URL in the database. Whichever the case, good examples can usually be found at www.devshed.com - Original Message - From: \"Phillip M.(Mike) Bishop\" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, February 07, 2001 4:01 Subject: saving images from mysql to file How do I save an images to a unix file that is saved in mysql? I know how to view the image with PHP and I know how to write a file to unix. I just can\'t get the data from mysql into a format that will allow me to read it then write it. - 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
Re: saving images from mysql to file
Look at section 7.19 SELECT Syntax of the manual. The line [INTO {OUTFILE | DUMPFILE} 'file_name' export_options] is what you will probably be looking for. - Original Message - From: "Phillip M.(Mike) Bishop" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, February 07, 2001 10:49 Subject: Re: saving images from mysql to file Ok I have 2000 images in a database that I want to move out of the database and save the image as a file and place the url to the image in the database. But I can\'t figure out how to get them out and written to a file to do this. You Wrote: Firstly, I\'m not exactly sure of what you are trying to do but in any case check out the blob column type in the mysql manual. Also, you are probably better off storing the image on disk and only store the URL in the database. Whichever the case, good examples can usually be found at www.devshed.com - Original Message - From: \"Phillip M.(Mike) Bishop\" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, February 07, 2001 4:01 Subject: saving images from mysql to file How do I save an images to a unix file that is saved in mysql? I know how to view the image with PHP and I know how to write a file to unix. I just can\'t get the data from mysql into a format that will allow me to read it then write it. - 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 - 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