title: Insert into Select From Where (Selecting Last Same Row Data to Insert into the Same Table)
body: <p>I'm trying to insert rows using the same last values of rows in the column name bill period.</p>
  
  <p><a href="https://i.stack.imgur.com/tBfet.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/tBfet.png" alt="http://i.stack.imgur.com/tBfet.png"></a></p>
  
  <p>this is my desired result, and after the billperiod 3 it goes into 4 taking the data rows of billperiod 3.</p>
  
  <p>I tried other solution where I used the other table to use it as a where but this are the results.</p>
  
  <p><a href="https://i.stack.imgur.com/hJM19.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/hJM19.png" alt="http://i.stack.imgur.com/hJM19.png"></a></p>
  
  <p>but It didn't work, here is the image of my other table</p>
  
  <p><a href="https://i.stack.imgur.com/UwqTX.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/UwqTX.png" alt="enter image description here"></a></p>