mirror of
https://github.com/alibaba/druid.git
synced 2023-03-04 19:17:16 +00:00
0.1.6
git-svn-id: http://code.alibabatech.com/svn/druid/trunk@540 b9813039-fb51-4c41-a8b9-e21c2acb5095
This commit is contained in:
@@ -16,18 +16,23 @@
|
||||
package com.alibaba.druid.stat;
|
||||
|
||||
import java.sql.Connection;
|
||||
import java.sql.DatabaseMetaData;
|
||||
import java.sql.DriverManager;
|
||||
import java.sql.PreparedStatement;
|
||||
import java.sql.ResultSet;
|
||||
|
||||
import junit.framework.TestCase;
|
||||
|
||||
import com.alibaba.druid.util.JdbcUtils;
|
||||
|
||||
public class TestOracle extends TestCase {
|
||||
|
||||
public void test_0() throws Exception {
|
||||
String url = "jdbc:oracle:thin:@10.20.144.80:1521:orcl";
|
||||
Class.forName("oracle.jdbc.driver.OracleDriver");
|
||||
Connection conn = DriverManager.getConnection(url, "druid", "druid123");
|
||||
Connection conn = DriverManager.getConnection(url, "DRUID", "DRUID");
|
||||
|
||||
conn.setAutoCommit(false);
|
||||
PreparedStatement stmt = conn.prepareStatement("select sysdate");
|
||||
stmt.executeBatch();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user