Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Need some advice on designing a scanned document archive system.

 
Masoud Kalali
Author
Ranch Hand
Posts: 531
Java Mac OS X Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
I should design a scanned document archive .
Is it good to store images in database ? (100,000,000 scanned image)
or its better to store string which point to image in file system .
how about converting all images to SCV and storing them in database?

what is best practice for this situation.


thank you very much.
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34672
367
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Masoud,
It depends on the requirements. I prefer to store the actual images in the db unless there is a compelling reason not to.
 
Adeel Ansari
Ranch Hand
Posts: 2874
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Masoud,

Images sometimes associated with some record. For example, we have some patients in our DB and there are some x-ray images of each patient associated with the patient. So, there should be some parent-child kind of relationship between the patients and the x-ray images. Now suppose if some user deletes a record of patient then the images belongs to that patient should be deleted with that record, or if not then the patient should not get deleted at all.

Hence if we store images in file system instead of DB, then it would result in lack of integrity. Say, user deletes a patient record, all the image name strings, refering to that patient, are also get deleted, but the actual images are still there. One more case results in real bad. Suppose somebody deletes the image from the file system, but the image name is there in the DB, then the system will look for the actual image and an exception will occur.

Bottomline is store the images in DB, as Jeanne said.
[ February 23, 2005: Message edited by: Adeel Ansari ]
 
Masoud Kalali
Author
Ranch Hand
Posts: 531
Java Mac OS X Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
Thank you very much for your help.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic