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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Saving Files to a SQL Server 7 table via ASP webpage

Status
Not open for further replies.

waggers

Programmer
Sep 7, 2000
13
0
0
AU
I am currently required to upload a file via an ASP webpage to a server and then save that file to a SQl Server 7 table.

Currently, the file upload is working fine and we are saving the uploaded file to a directory and recording the file name in the database. This part works really well, BUT... my boss wants that actual file stored in the databases for security purposes and I can't get this happening.

The file types will be .gif, .jpg and various other formats such as .doc., .ppt and .xls and will vary in size from approx 1 - 2k up to perhaps several Mb.

I can get the file to a known directory on the server - no problem, but the next bit just isn't happening and Microsoft's documentation is none too clear on this aspect.

Has anyone successfully done this and how did you do it?

TIA

waggers
 
I believe the image data type is the recommended data type by Microsoft for situations like this...

Are you using a Visual Basic application for this?

Tom
 
I have defined an 'image' column for this.

I am using active server pages via an IIS4 web server, not a VB application...I think a VB application would have been easier, but using a web-based approach (no choice) I am relying on using FileSystemObjects for my file handling, which is ok as it is working.

Any thoughts?

waggers
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top