package pack; import java.sql.Connection; import java.sql.DriverManager; public class Con { public static Connection getConnection() throws Exception { Class.forName("org.apache.phoenix.jdbc.PhoenixDriver"); String url = "jdbc:phoenix:192.168.88.101:2181"; String user = "hadoop"; String pwd = "123456"; Connection con = DriverManager.getConnection(url, user, pwd); return con; } }
标签:DriverManager,jdbc,String,getConnection,Connection,hbase,连接 From: https://www.cnblogs.com/cocotun/p/17707852.html