Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How To Store Attachments

Status
Not open for further replies.

David92595

IS-IT--Management
Jul 13, 2012
12
US
Hello,

Basics: I'm running a SQL server 2008 R2 back end with an Access 2007 Front end.

I need to find a way to attach documents via my access front end. I've done some research and there seems to be quite the debate about how this should be done.

I don't have a full understanding about the subject, so any help as to the best means to accomplish my goal would be greatly appreciated.

Thank you,

David92595
 
I would set up a file share on your server, with permissions granted to it for everybody who uses the Access database.
You can then set up a table in SQL server linked through to access which stores the path to the file. Your "upload" routine then
- lets the user select the file and copies it to the share
- adds a row into the "file attachments" table with the path

To open the file you then just use something like Application.FollowHyperlink "\\server\documents\somefile.doc", substituting in the path.

The reason for storing them externally from the database is that it will grow exponentially if you store them as blobs, especially if there are a lot of them. Be sure to add the share path into your server backups though.

John
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top