SHARE
TWEET

Untitled

a guest May 22nd, 2017 45 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. package br.edu.ifce.bd.crud;
  2.  
  3.  
  4. import java.sql.Connection;
  5. import java.sql.DriverManager;
  6. import java.sql.SQLException;
  7. import java.sql.Statement;
  8. import java.util.logging.Level;
  9. import java.util.logging.Logger;
  10.  
  11.  
  12.  
  13. /**
  14.  *
  15.  * @author IgorJava()
  16.  */
  17. public class AltosTestes {
  18.    
  19.     public static void main(String[] args){
  20.         try {
  21.             Class.forName("com.mysql.jdbc.Driver");
  22.         } catch (ClassNotFoundException ex) {
  23.             System.out.println("Erro");
  24.         }
  25.         try {
  26.             Connection conn = DriverManager.getConnection("jdbc:mysql://localhost:3306/filmes", "root", "igor");
  27.         } catch (SQLException ex) {
  28.             System.out.println("Erro na conex√£o");
  29.            
  30.         }
  31.        
  32.         Statement st=conn.createStatement();
  33.         st.executeUpdate("");
  34.     }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top