import java.sql.*;
import java.lang.*;
import java.io.*;
import java.util.*;
public class affiche {
public static void main(String[] args) {
try {
Class d = Class.forName("com.microsoft.sqlserver.jdbc.SQLServerDriver");
}
catch (Exception e)
{
e.printStackTrace();
System.out.println("Probleme de driver");
}
try
{
String url ="jdbc:sqlserver://localhost;";
Connection c = DriverManager.getConnection(url
System.out.println("Ca marche");
}
catch (Exception e)
{
e.printStackTrace();
System.out.println("la connexion a échouée");
}
}
}
Partager