The code uploads; however, saves the file to my server. I do not want the file saved to my server, just inserted into my database. I would like to store the WHOLE file in a field not just the contents. Files I would like to save are .txt, .sgn, html, etc...
Thanks for your response. When I said I would like to store the whole file instead of its contents, I meant that the file would be stored in a field. Before I tried to insert a file in a field and I had to do it as a string, which messed the file up. I want to be able to do a query and have the file returned as a field, so the user can click on it to download it from the database, not the file server. Hope this makes sense. Basically I want to upload a file into the database as a field. Thanks again!
Originally posted by Rick Banster: Thanks Jeanne. I'm new to using files with Java. Can you point me to some Java code that will recreate the file for me. It will be very helpful.
Rick, To retrieve a BLOB (file), see this example.
Originally posted by Rick Banster: Also is there a way to not upload the file to my server before inserting it to the database? The code I have uploads and saves the file to my server before inserting it to my database.
What technology are you using to upload the file? Servlets? Standalone app?