473,656 Members | 2,777 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Still Trying to Find the Best Way to Serve Documents

Greetings!

I am still trying to determine the best way to implement a Web site that
contains many documents that visitors can read. Most of the suggestions I've
been given indicate that I should store the documents in a database but then
cache them to pages.

Unfortunately, while an experienced programmer, I've very new to ASP.NET and
the very brief descriptions I've been given how to do this, I just don't
understand.

I would think this is a common task yet I've done a lot of searching the Web
and came up empty. Is there anyone who can provide me with some more
specific information on the best way to implement this?

Thanks!

--
Jonathan Wood
SoftCircuits
http://www.softcircuits.com
Apr 8 '06 #1
7 1447
> I would think this is a common task yet I've done a lot of searching the
Web and came up empty. Is there anyone who can provide me with some more
specific information on the best way to implement this?


There is no 'best' way. Just different camps of thought.

Many claim that storing the files in the database is the way to go. It's
easier to maintain, easier to backup, easier to control access.

Others claim that the filesystem was designed specifically for
this...storing and organizing files. So that the way to go is store the
files in the system, and then just reference them in the DB.

I prefer the latter, mainly because it is less abstract. I can SEE the files
right there in the folder. But that's not necessarily a reason that it's a
better method. ;o)

-Darrel
Apr 8 '06 #2
Hi Darrel,
There is no 'best' way. Just different camps of thought.


I understand, but I'm really new to ASP.NET. I'd just like to see an
approach by someone who understands the technology.

--
Jonathan Wood
SoftCircuits
http://www.softcircuits.com
Available for consulting: http://www.softcircuits.com/jwood/resume.htm
Apr 8 '06 #3
As Darrel said, people who understand the technology either store the
document in the DB or in the file system.

The *best* way is what works for you.

I'm in the filesystem camp, myself.

Bob Lehmann

"Jonathan Wood" <jw***@softcirc uits.com> wrote in message
news:%2******** ********@TK2MSF TNGP02.phx.gbl. ..
Hi Darrel,
There is no 'best' way. Just different camps of thought.


I understand, but I'm really new to ASP.NET. I'd just like to see an
approach by someone who understands the technology.

--
Jonathan Wood
SoftCircuits
http://www.softcircuits.com
Available for consulting: http://www.softcircuits.com/jwood/resume.htm

Apr 9 '06 #4
Jonathan,
As was mentioned, both approaches work -
if you are an experienced programmer and .NET is new to you, the best thing
to do is simply make a decision, and go with it. You can always change it
later, but at this point your objective should be to "get to first base". If
you have issues with the actual code for the implementation, you can always
post here again and get some help.
Peter

--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com


"Jonathan Wood" wrote:
Greetings!

I am still trying to determine the best way to implement a Web site that
contains many documents that visitors can read. Most of the suggestions I've
been given indicate that I should store the documents in a database but then
cache them to pages.

Unfortunately, while an experienced programmer, I've very new to ASP.NET and
the very brief descriptions I've been given how to do this, I just don't
understand.

I would think this is a common task yet I've done a lot of searching the Web
and came up empty. Is there anyone who can provide me with some more
specific information on the best way to implement this?

Thanks!

--
Jonathan Wood
SoftCircuits
http://www.softcircuits.com

Apr 9 '06 #5
> I understand, but I'm really new to ASP.NET. I'd just like to see an
approach by someone who understands the technology.


The approach I take is to accept the document, save it to a particular
folder, then put the filename in a DB table.

I often device a categorization system of some sort so all files aren't in
one directory. I then store this categorization in the DB table along with
the file.

So my file table record might look like:

UID: 1111
FileName: my_document.doc
Category: Resumes

Then, to grab the file, I just write out the URL from the data:

/documents/Resumes/my_document.doc

The drawback? Well, deleting or moving a file requires not only updating the
DB, but also the filesystem. Of course, that's not much more then just
adding a couple of functions to handle it, so not a big deal.

-Darrel
Apr 9 '06 #6
Thanks, I've printed out your comments.

--
Jonathan Wood
SoftCircuits
http://www.softcircuits.com
Available for consulting: http://www.softcircuits.com/jwood/resume.htm

"Darrel" <no*****@nospam .com> wrote in message
news:uv******** ******@TK2MSFTN GP02.phx.gbl...
I understand, but I'm really new to ASP.NET. I'd just like to see an
approach by someone who understands the technology.


The approach I take is to accept the document, save it to a particular
folder, then put the filename in a DB table.

I often device a categorization system of some sort so all files aren't in
one directory. I then store this categorization in the DB table along with
the file.

So my file table record might look like:

UID: 1111
FileName: my_document.doc
Category: Resumes

Then, to grab the file, I just write out the URL from the data:

/documents/Resumes/my_document.doc

The drawback? Well, deleting or moving a file requires not only updating
the DB, but also the filesystem. Of course, that's not much more then just
adding a couple of functions to handle it, so not a big deal.

-Darrel

Apr 9 '06 #7
Yes, that's probably what I'll end up doing. I do have some very brief
comments from one of the people who suggested that it be stored in both
places (BTW, I was able to confirm this is how it's done at
codeproject.com ). I'm just trying to get as much info as I can before diving
in.

Thanks.

--
Jonathan Wood
SoftCircuits
http://www.softcircuits.com
Available for consulting: http://www.softcircuits.com/jwood/resume.htm

"Peter Bromberg [C# MVP]" <pb*******@yaho o.nospammin.com > wrote in message
news:AC******** *************** ***********@mic rosoft.com...
Jonathan,
As was mentioned, both approaches work -
if you are an experienced programmer and .NET is new to you, the best
thing
to do is simply make a decision, and go with it. You can always change it
later, but at this point your objective should be to "get to first base".
If
you have issues with the actual code for the implementation, you can
always
post here again and get some help.
Peter

--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com


"Jonathan Wood" wrote:
Greetings!

I am still trying to determine the best way to implement a Web site that
contains many documents that visitors can read. Most of the suggestions
I've
been given indicate that I should store the documents in a database but
then
cache them to pages.

Unfortunately, while an experienced programmer, I've very new to ASP.NET
and
the very brief descriptions I've been given how to do this, I just don't
understand.

I would think this is a common task yet I've done a lot of searching the
Web
and came up empty. Is there anyone who can provide me with some more
specific information on the best way to implement this?

Thanks!

--
Jonathan Wood
SoftCircuits
http://www.softcircuits.com

Apr 9 '06 #8

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
1529
by: trek | last post by:
Good evening, I am trying to locate a standard (commonly accepted) XML schema for managing documents. What want to know is if someone has already created an XML schema for describing the pertinent data about a journal article (title, author(s), journal name, publication date, etc). If anyone can help me out here, I'd really appreciate it. You can email me at trekcelt @ yahoo.com.
16
2218
by: Jonas Smithson | last post by:
I'm going to say something now that may seem to completely contradict a previous post of mine, in which I basically said that taking a "who cares" attitude about certain browsers (because of their non-standard CSS rendering) makes no sense. Well, you have to draw the line *somewhere*... and contradictory or not, I've decided that I've suffered with Netscape 4 for long enough. Coding workarounds for its brain-dead CSS rendering has...
136
9301
by: Matt Kruse | last post by:
http://www.JavascriptToolbox.com/bestpractices/ I started writing this up as a guide for some people who were looking for general tips on how to do things the 'right way' with Javascript. Their code was littered with document.all and eval, for example, and I wanted to create a practical list of best practices that they could easily put to use. The above URL is version 1.0 (draft) that resulted. IMO, it is not a replacement for the FAQ,...
3
5381
by: Richard Fritzler | last post by:
I was given the task of designing a complete web based document prep system. In simplest terms (using a msword explanation) create a database of merge fields, and a library of templates. Allow the webuser to select the template, merge his DB record, and produce a formatted document that can be printed or downloaded. We need to do this without specialized software on the client, since it will be universally available to webusers. We...
687
23323
by: cody | last post by:
no this is no trollposting and please don't get it wrong but iam very curious why people still use C instead of other languages especially C++. i heard people say C++ is slower than C but i can't believe that. in pieces of the application where speed really matters you can still use "normal" functions or even static methods which is basically the same. in C there arent the simplest things present like constants, each struct and enum...
9
1368
by: Thomas Scheiderich | last post by:
I am getting ready to look at putting our users manual and employee handbook on our intranet and was curious how others do it? We have it already set up as Word documents and am looking at whether to put into our Sql Server and maintain it there or put it as text or doc files (not sure how I would display Word .doc files on a web page with all the Word formating). Not sure how to keep it maintained either.
0
910
by: Benjamin Cabé | last post by:
Hi, I have to serve TIFF images (scanned documents) stored on an unique server, clients are likely to edit these images and send them back to the server.. Ideally, the client would ask something like "MemoryStream getImage(int folderNumber, int pageNumber) and he will retrieve the stream corresponding to he pageNumberth page in the folderNumberth folder! Implementing this method in a Webservice (IIS 5.1 + flatcomp (to reduce bandwidth,...
0
874
by: jonefer | last post by:
I followed the walkthrough in the help and developed my application in this physical location: C:\Inetpub\wwwroot\Membership When I try to build the Setup file I get the following error (Did I develop in the wrong place?) Could not find the file c:\Documents and Settings\jonefer\VSWebCache\MD8600\Membership\obj\Release\Membership.dll
8
3197
by: CptDondo | last post by:
I have a small, embedded app that uses a webserver to serve up pages showing status, etc. Right now all the pages are hard-coded in English. We need to provide multi-lingual support. All of the pages are PHP generated. Ideally, I'd like for the PHP backend to serve up the language based a) the user's locale, and if that is not set, its own locale.
0
8297
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8717
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8498
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8600
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7311
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6162
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4150
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4300
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
1930
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.