This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
Web applications aren't always deployed as expanded file system. They can be deployed from packed war files. When deployed this way, it isn't possible to upload files to a location within the application's directory structure.
Also, even when run from a file system, many people do not grant write permissions to the web app directories for security reasons.
Jigar, It is not difficult to write a servlet that streams binary file from the server to the client. I have an example app that does this. http://simple.souther.us Look for SimpleStream. In my app, I'm using context.getResourceAsStream to read the file. In your case, you'll want to use java.io.FileReader becuase the file is not under the web app's directory structure. I'm sure it wouldn't be difficult to stream the images straight from the database but I don't know what JDBC methods to use off the top of my head.