Package com.bleujin.framework.db.manager

Examples of com.bleujin.framework.db.manager.DBManager


    }


    public void testCase3() throws Exception{

        DBManager dbm = dc.getDBManager();
    Connection conn = dbm.getConnection() ;

        long start = System.currentTimeMillis() ;
        PreparedStatement ps = conn.prepareStatement("insert into a# Select ? a,? from dual t1 Where Exists(Select 1 From copy_tblc WHere no2 = t1.dummy)");
        ps.clearBatch();
        for (int i = 0; i < MaxTryCount; i++) {
            ps.setInt(1, i);
            ps.setString(2, "0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789");
            ps.addBatch();
        }
        ps.executeBatch() ;
        ps.close() ;
        dbm.freeConnection(conn);
        long end = System.currentTimeMillis() ;

        System.out.println("Case 3 (end - start)="+ (end - start));
    }
View Full Code Here


  protected DBController dc ;
  public void setUp() throws Exception {
//    DBManager dbm = new MySQLPoolDBManager("jdbc:mysql://novision/test", "bleu", "redf") ;
//    DBManager dbm = new MSSQLPoolDBManager("jdbc:microsoft:sqlserver://localhost:1433;DatabaseName=test", "bleu", "redf") ;
    DBManager dbm = new OraclePoolDBManager("jdbc:oracle:thin:@novision:1521:bleujin", "setuptest", "setuptest") ;
//    DBManager dbm = new OracleCacheDBManager("jdbc:oracle:thin:@novision:1521:bleujin", "setuptest", "setuptest") ;
    dc = new DBController(dbm) ;
    dc.initSelf() ;
  }
View Full Code Here

public class TestJSON extends TestCase{

  private DBController dc ;
  public void setUp() throws Exception {
    DBManager dbm = new MSSQLDBManager("jdbc:sqlserver://localhost;databasename=test", "bleu", "redf") ;
    dc = new DBController(dbm) ;
    dc.initSelf() ;
  }
View Full Code Here

TOP

Related Classes of com.bleujin.framework.db.manager.DBManager

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.