Description
Hello everyone
I am stuck with a new problem.I want to use SQL SERVER 2008 as the database in my Servlet project but don't know how to configure it.Any type for connection may be useful either by a datasource or by Sql Server Driver .
knodly help !!!!
Explanation & Answer
you can use JDBC connection
String driver = "com.microsoft.jdbc.sqlserver.SQLServerDriver";
Class.forName(driver);
String url = "jdbc:microsoft:sqlserver://host:1433/database";
Connection conn = DriverManager.getConnection(url, "username", "password");
Review
Review
24/7 Homework Help
Stuck on a homework question? Our verified tutors can answer all questions, from basic math to advanced rocket science!
Similar Content
Related Tags
Narrative of the Life of Frederick Douglass
by Frederick Douglass
Little Fires Everywhere
by Celeste Ng
Moby Dick
by Herman Melville
Siddhartha
by Hermann Hesse
The Sixth Extinction An Unnatural History
by Elizabeth Kolbert
Gone with the Wind
by Margaret Mitchell
The President is Missing
by James Patterson, Bill Clinton