I want to upload a file(either txt or doc. file) into database using core java. I had made a simple swing programe. I just want to browse to particular file and upload it to database.
can anyone provide me a starter tips regarding this.
Getting the file contents is just basic usage of the java.io package, probably involving a FileDialog or JFileChooser. The upload can be handled by the Jakarta HttpClient library, while the server part is handled by the Jakarta FileUpload library. Links to both can be found in this FAQ page: http://faq.javaranch.com/java/FileUpload (That's assuming you want to use HTTP for the upload. The page also talks about other protocols.)