ASP Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 
Go Back   Dev Articles Community ForumsProgrammingASP Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old May 24th, 2003, 07:38 AM
mark0 mark0 is offline
Junior Member
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Feb 2003
Posts: 9 mark0 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Uploading images and assigning to content

Just a quick question, I was wondering what the best approach would be simply for performance; ease and general good programming practice reasons.

Using ASP and SQL Server.

If I was to build an image upload routine and then when I create an new piece of content such as an article and assign an image to it should the image be stored on disk in the file system and the name of the image referenced in the database along with the content being saved or should the image be stored along with the content item in the database?

I always used packaged content management solutions in the past, which always store the image on disk and does all of the hard work for you, however, now I wish to do this myself in ASP and wondered what the best approach was.

Thanks in advance.

Reply With Quote
  #2  
Old May 24th, 2003, 04:14 PM
iahmed iahmed is offline
Contributing User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: May 2003
Location: USA
Posts: 171 iahmed User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 42 m 58 sec
Reputation Power: 6
Its completely a trade-off issue.
If you insert images in the database field, retrieving image is always a faster. But image size may be an issue for the operating system ( I mean operation system may delimit the size).

On the otherhand, keeping image under a folder is always easy to maintain or update ( or probably you will use a single image for multiple ref.), but little slower to retrieve if there are huge number of images under same folder.

In my project, I had to maintain about 100,000 images, I devided them logically under 4 diff. folder.

However, When Intel are about to introduce a Hyperthread Processor sLike P4. In future how you organize your images wont be performance factor for any of the above approach.

Reply With Quote
  #3  
Old May 25th, 2003, 07:14 AM
stumpy's Avatar
stumpy stumpy is offline
May contain nuts.
Dev Articles Regular (2000 - 2499 posts)
 
Join Date: Aug 2002
Location: Sydney, AU
Posts: 2,058 stumpy User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 5 h 8 m 57 sec
Reputation Power: 9
Send a message via ICQ to stumpy Send a message via MSN to stumpy
CPU doesn't really have much to do with it as most decent DB's store their content memory.

I've always found that the filesystem method is the best. It's very easy to maintain, clean, and there's no hassles pulling the filename string outta the DB. The DB method is messy, bloated and clunky, streaming the data to the broswer, setting content-types, etc... blah...

Go the FS route.
__________________
DevArticles Moderator
BlueSix - Web Development and Consulting

Reply With Quote
  #4  
Old May 25th, 2003, 01:58 PM
mark0 mark0 is offline
Junior Member
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Feb 2003
Posts: 9 mark0 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Thanks guys.

Just as I thought, I didn't really want to go down the dB route but thought I would double check that my reasons were correct.

Thanks.

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingASP Development > Uploading images and assigning to content


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 3 hosted by Hostway
Stay green...Green IT