Friday, February 28, 2014

Connect database using Servlet & JSP in java web project


  • First, need to copy JDBC drivers into WEB-INF\lib folder. It will come up under "Web App Libraries" automatically.






































  • Second, create a java class for connecting to SQL Server database. 


























  • Third, create Servlet.























  • Fourth, create JSP page.





















No comments:

Post a Comment