Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.sql.*;
- public class Test
- {
- public static void main(String[] args)
- {
- try
- {
- Class.forName( "com.microsoft.sqlserver.jdbc.SQLServerDriver" );
- System.out.println("no error till here");
- Connection c = DriverManager.getConnection("jdbc:sqlserver://localhost:1433;databaseName=;integratedSecurity=true;","", "");;
- System.out.println( "Connected with "+c);
- }
- catch( Exception ex )
- {
- ex.printStackTrace();
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement