• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Image Databases

 
V Bose
Ranch Hand
Posts: 113
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Does anyone know of a platform/DB environment which supports storage and retreival of a large number of images.
Eventually I want to be able to access and retrieve images based once I store each image with its custom header tag.
Any pointers/hints ? Thanks in advance...
 
Joe Ess
Bartender
Pie
Posts: 9266
10
Linux Mac OS X Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't know of any image-specific solutions but every database I've worked with (MSSQL, Oracle, MySQL) supported binary large objects (BLOB). I just used a field of that type to store the image.
 
Gregg Bolinger
GenRocket Founder
Ranch Hand
Posts: 15302
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Joe Ess:
I don't know of any image-specific solutions but every database I've worked with (MSSQL, Oracle, MySQL) supported binary large objects (BLOB). I just used a field of that type to store the image.

Joe is correct. With that being said, however, storing large amounts of binary data in a database will kill your performance. You would be better off storing the image on the hard drive somewhere and just storing the location of that image in the database.
 
SJ Adnams
Ranch Hand
Posts: 925
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

yea, storing things in databases is useless. I think you should put all your data in flat files & just use the database for filenames!

Mr Bose, don't listen to Gregg, he's just winding you up. Like Joe says every commercial database supports binary (i.e. picture) fields. And will give you better performance than using a (non caching) filesystem.
 
Gregg Bolinger
GenRocket Founder
Ranch Hand
Posts: 15302
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Simon Lee:

yea, storing things in databases is useless. I think you should put all your data in flat files & just use the database for filenames!

Mr Bose, don't listen to Gregg, he's just winding you up. Like Joe says every commercial database supports binary (i.e. picture) fields. And will give you better performance than using a (non caching) filesystem.

Why can't Mr. Bose listen to me? I stated my opinion, based on personal research BTW, that gives Mr. Bose another option to solve his problem.
Although the "Be Nice" rule is typically reserved for the Meaningless Drivel forum, it does apply throughout this Board. So please, be nice!
 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24208
35
Chrome Eclipse IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Article with hard data regarding BLOB vs. filesystem performance in Mysql (BLOB 30% slower.)
Another discussion, same conclusion.
Another point neither of these articles make but that's very important in big installations: if you use BLOBs, then your image data will be replicated on all slave servers; if you just store filenames, then a single server can serve all the images with far better caching.
Gregg knows what he's talking about, Mr. Lee. BLOBs aren't evil or anything, but their (small) convenience factor is very often outweighed by performance issues. Since you can't index on the actual image data, there's really no compelling reason to store images as BLOBs at all.
[ December 17, 2003: Message edited by: Ernest Friedman-Hill ]
 
SJ Adnams
Ranch Hand
Posts: 925
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hey I was being nice
wait till I get drunk
 
SJ Adnams
Ranch Hand
Posts: 925
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
(hic!)
not sure if this link will work Ask Tom - Storing Images in database as BLOB Vs storing images on file system on Application Server
To be honest I was a bit shocked by the stats that the filesystem is faster. However remember that the webserver can memory cache pages served up by the appserver just as well as pages (images) from the filesystem.
I also think that 1st URL is comparing apples with oranges. In the php script he already knows the filename (rather than making a trip to the database to get the filename).
I think the point Tom makes about large number of images. is very valid. Certainly I know that if you set up usenet server you need to format the hard disk to deal with the thousands of small files. With a database you don't need to worry about this ( spreading the tablespace over many disks etc..).
Anyway I kind of get the impression that the comments were more about my attitude than my suggestion, so I'll try & behave myself in future. :roll:
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64718
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Anyway I kind of get the impression that the comments were more about my attitude

Exactly. Rather than "Don't listen to Gregg...", perhaps something along the lines of "I'm not sure that I agree with Gregg about..."
bear
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic