zoukankan      html  css  js  c++  java
  • spring.boot mybaits集成

    https://www.cnblogs.com/pejsidney/p/9272562.html (insertBatch批量插入)
            第一篇博客循环部分有错误,参照下面的例子去更改
            List<String> list=new ArrayList<String>();
            list.add("1");
            list.add("2");
            list.add("3");
            list.add("4");
            list.add("5");
            list.add("6");
            list.add("7");
            int batchCount=3;
            int batchLastIndex=batchCount;
            for(int index=0;index<list.size();){
                List<String> subs;
                if(batchLastIndex>list.size()){
                   batchLastIndex=list.size();
                   subs= list.subList(index, batchLastIndex);
                }else{
                    subs = list.subList(index, batchLastIndex);
                    index = batchLastIndex;
                    batchLastIndex = batchLastIndex + batchCount;  //这一行改造原来是batchLastIndex = batchLastIndex + batchCount-1
                }
    
            }
    https://blog.csdn.net/qq_33337504/article/details/78460383 (select * from )
    https://blog.csdn.net/qq_36367789/article/details/79732868 特别完整版
  • 相关阅读:
    实验四
    实验三
    实验二
    实验一
    6
    5
    4
    3
    shiyan2
    实验1
  • 原文地址:https://www.cnblogs.com/kexb/p/10066763.html
Copyright © 2011-2022 走看看