import java.sql.*;
  public class JDBC {
  public static void main(String args[]) throws Exception {


  Connection con;
  DatabaseMetaData baglanti;
  String url;
  Class.forName("com.mysql.jdbc.Driver");
  url = "jdbc:mysql:jsptr";


  con = DriverManager.getConnection(url,"root","");
  baglanti = con.getMetaData();
  

  System.out.print("Database adi : ");
  System.out.println(baglanti.getDatabaseProductName());


  System.out.print("Database Version : ");
  System.out.println(baglanti.getDatabaseProductVersion());


  System.out.print("Driver Adi : ");
  System.out.println(baglanti.getDriverName());


  System.out.print("Driver Version : ");
  System.out.println(baglanti.getDriverVersion());


  System.out.print("JDBC URL : ");

  System.out.println(baglanti.getURL());


  con.close(); 

  } 

}
