Package com.bleujin.framework.db.procedure

Examples of com.bleujin.framework.db.procedure.IUserProcedureBatch


        System.out.println("Case 1 (end - start)="+ (end - start));
    }

    public void xtestCase2() throws Exception{
        IUserProcedureBatch upts = dc.createUserProcedureBatch("LobTest@insertBatch2(?,?)") ;

        long start = System.currentTimeMillis() ;

        Integer[] ints = new Integer[MaxTryCount];
        String[] strs = new String[MaxTryCount];

        for (int i = 0; i < ints.length; i++) {
            ints[i] = new Integer(i) ;
            strs[i] = "0123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890123456789" ;
        }

        upts.addParam(0, ints);
        upts.addParam(1, strs);

        upts.execUpdate() ;
        long end = System.currentTimeMillis() ;

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


        System.out.println("Case 1 (end - start)="+ (end - start));
    }

    public void xtestCase22() throws Exception{
        IUserProcedureBatch upts = dc.createUserProcedureBatch("LobTest@insertClob2(?,?)") ;

         long start = System.currentTimeMillis() ;

         Integer[] ints = new Integer[MaxTryCount];
         String[] strs = new String[MaxTryCount];

         for (int i = 0; i < ints.length; i++) {
             ints[i] = new Integer(i) ;
             strs[i] = "" ;
         }

         upts.addParam(0, ints);
         upts.addParam(1, strs);

         upts.execUpdate() ;
         long end = System.currentTimeMillis() ;

         System.out.println("Case 2 (end - start)="+ (end - start));

    }
View Full Code Here

        for (int i = 0, last = limit; i < last; i++) {
            a[i] = i ;
            b[i] = "abcdefg" ;
            c[i] = longString ;
        }
        IUserProcedureBatch case2 = dc.createUserProcedureBatch("bleujin@lobTest3(?,?,?)") ;
        case2.addParam(0, a); ;
        case2.addParam(1, b); ;
        case2.addClob(2, c); ;
        case2.execUpdate() ;

        long end = System.currentTimeMillis() ;
        return end - start ;

    }
View Full Code Here

        command.execUpdate() ;
    }

    public void xtestClobProcedureBatch() throws Exception {
        IUserProcedureBatch batch = dc.createUserProcedureBatch("bleujin@lobTest3(?,?,?)") ;
        batch.addParam(0, new int[]{1,2,3}); ;
        batch.addParam(1, "abcdefg", 3);
        batch.addClob(2, getLongString(), 3); ;

        int result = batch.execUpdate() ;
        System.out.println("result="+result);
    }
View Full Code Here

    DBController dc = DBController.getTestInstance() ;
    dc.initSelf() ;
   
    String query = "Types@test2(?,?,?,?,?, ?,?,?,?)" ;

    IUserProcedureBatch upt = dc.createUserProcedureBatch(query) ;
    int max = 10000 ;
    for (int i = 0; i < max; i++) {
      upt.addBatchParam(0, new UUID(RandomUtil.nextLong(), new Date().getTime()).toString()) ;
      upt.addBatchParam(1, RandomUtil.nextRandomString(10)) ;
      upt.addBatchParam(2, RandomUtil.nextRandomString(10)) ;
      upt.addBatchParam(3, RandomUtil.nextRandomString(20)) ;
      upt.addBatchParam(4, "NORMAL") ;
      upt.addBatchParam(5, RandomUtil.nextInt()) ;
      upt.addBatchParam(6, RandomUtil.nextRandomString(12)) ;
      upt.addBatchParam(7, RandomUtil.nextRandomString(10)) ;
      upt.addBatchParam(8, RandomUtil.nextInt()) ;
    }
    upt.execUpdate() ;
    dc.destroySelf() ;
  }
View Full Code Here

TOP

Related Classes of com.bleujin.framework.db.procedure.IUserProcedureBatch

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.