title: How to persist very 100 record from List
body: <p>MY list size is consist 5000 records i need to get 100 records every time from list then persist to 100 records each time up to 5000 records persist to DB how can achieve this logic?</p>
  
  <pre><code>private  List&lt;DoTempCustomers&gt; doTempCustomers;
  for(DoTempCustomers tempCustomers:doTempCustomers){
  try {
      temp=new TempCustomers();               
      BeanUtils.copyProperties(temp, doTemp);
      getEntityManager().persist(temp);
  }
  </code></pre>
  
  <p>my above code i was persist all 5000 records single for each loop.</p>