I have a Java Application (with Swing) which has to do DB-queries. Currently the application connects directly to the DB which isn't the best solution because the Application shall also work through firewalls. My idea is to build a servlet which takes the queries and passes back the results in a CachedRowSet. Unfortunately I don't have a clue on how to build the servlet especially on how to access the servlets methods from the application. I'm using Tomcat 5, Java 1.5 and MySQL with Connector/J 3.1 as JDBC driver. Can anybody please give me a hint on how to start?