How to speed up rbind? <p>I'm supposed to download a table from MS-SQL server.</p> <p>The number of row is larger than 6million. The server cannot return entire data at once.</p> <p>So, I wrote a code that downloads 10,000 rows at a time. and, it binds rows in the loop.</p> <p>Assume that <code>getData()</code> function returns a data frame contains 10000 rows at a time. (Pseudo Code)</p> <pre><code>for(i in 1:600) { tempValue &lt;- getData() wannagetValue &lt;- rbind(wannagetValue,tempValue) print(i) } </code></pre> <p>The problem is that it gets slower as time goes by.</p> <p>I think using rbind like that way is not a good idea.</p> <p>Any advice will be very helpful. Thank you in advance.</p>