SHARE
TWEET

Untitled

a guest Jun 30th, 2018 100 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Class.forName("com.mysql.jdbc.Driver") ;
  2. Connection conn = DriverManager.getConnection("jdbc:mysql://localhost:3306/DBNAME", "usrname", "pswd") ;
  3. Statement stmt = conn.createStatement() ;
  4. String query = "select columnname from tablename ;" ;
  5. ResultSet rs = stmt.executeQuery(query) ;
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
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top