锘??xml version="1.0" encoding="utf-8" standalone="yes"?>亚洲国产天堂久久综合,中文字幕国产一区,亚洲福利在线观看http://www.aygfsteel.com/sutao/category/25330.html鐢ㄦ枃瀛楄褰曞涔犵殑浣撻獙錛?/description>zh-cnTue, 28 Aug 2007 00:50:00 GMTTue, 28 Aug 2007 00:50:00 GMT60鎴戠殑鎵歸噺鎿嶄綔http://www.aygfsteel.com/sutao/archive/2007/08/28/140262.html鑻忛唲鑻忛唲Tue, 28 Aug 2007 00:44:00 GMThttp://www.aygfsteel.com/sutao/archive/2007/08/28/140262.htmlhttp://www.aygfsteel.com/sutao/comments/140262.htmlhttp://www.aygfsteel.com/sutao/archive/2007/08/28/140262.html#Feedback0http://www.aygfsteel.com/sutao/comments/commentRss/140262.htmlhttp://www.aygfsteel.com/sutao/services/trackbacks/140262.html

import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.PreparedStatement;
import java.sql.SQLException;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.Date;
import java.util.HashSet;
import java.util.Iterator;
import java.util.Set;

public class test {
/*
    String sDBDriver = "com.microsoft.jdbc.sqlserver.SQLServerDriver";
    String url ="jdbc:microsoft:sqlserver://localhost:1433;DatabaseName=jihedb";       
    String user = "sa";
       String password = "517747";
       Connection conn = null;       
       PreparedStatement pstmt=null;
       ResultSet rs = null;   
    public test() {
          try {
            Class.forName(sDBDriver);
          } catch (java.lang.ClassNotFoundException e)
                      {
            System.err.println("DBconn(): " + e.getMessage());
                 }
                    }
    */
      
   
    String url="jdbc:jtds:sqlserver://localhost:1433/jihedb";
    String username="sa";
    String password="517747";
    static Connection conn=null;
    PreparedStatement pstmt=null;
   
    //鏋勯犲嚱鏁?br>    public test()
  {
try{
Class.forName("net.sourceforge.jtds.jdbc.Driver");
DriverManager.registerDriver(new net.sourceforge.jtds.jdbc.Driver());

conn=DriverManager.getConnection(url,username,password);

}catch(ClassNotFoundException e)
{    
e.printStackTrace();
}catch(SQLException e)
{
e.printStackTrace();
}

       
    //main()鍑芥暟
    public static void main(String args[]) throws SQLException{
       
        test m=new test();
        
        PreparedStatement ps =conn.prepareStatement( "INSERT into code values (?,?)");
        Date t=(Calendar.getInstance()).getTime();
       
        Set s=new HashSet();
                
            Date tt=(Calendar.getInstance()).getTime();
            System.out.print("鎻掑叆寮濮?+tt);
           int count=0;
           //LinkedList v=new LinkedList();
           ArrayList v=new ArrayList();
           for(int i=1;i<1000000;i++){
             v.add(i);
           }
           System.out.println("闀垮害"+v.size());
          
           Iterator vv=v.iterator();
           while(vv.hasNext()){
                                         
                ps.setObject(1,vv.next());
                ps.setString(2, "0");
                                       
                ps.addBatch();
                count+=1;
                           
                if(count%1000==0)
                {
                ps.executeBatch();
                }
           }
           ps.executeBatch();                    
           Date ttt=(Calendar.getInstance()).getTime();
           System.out.print("緇撴潫"+ttt);
    }

}
 



鑻忛唲 2007-08-28 08:44 鍙戣〃璇勮
]]>
主站蜘蛛池模板: 庆城县| 金寨县| 郸城县| 扶沟县| 隆尧县| 左贡县| 金山区| 北海市| 米林县| 工布江达县| 云阳县| 宣汉县| 海南省| 珠海市| 赫章县| 怀化市| 桓台县| 浙江省| 黑龙江省| 库车县| 疏勒县| 于都县| 武乡县| 宾阳县| 富裕县| 武胜县| 大庆市| 广安市| 芷江| 东乌珠穆沁旗| 伊金霍洛旗| 达州市| 五家渠市| 广昌县| 双牌县| 临清市| 美姑县| 陆良县| 噶尔县| 张掖市| 察雅县|