0

What is the fastest way to insert 3GB worth of data in to a table in SQL Server? I've tried inserting 80,000,000 records using a loop and it took about 2 hours to do. Is there any quicker way to do such a task?

If you're wondering, this is for benchmarking purposes.

NoobCoder
  • 73
  • 1
  • 9
  • What is the source of your imports? Another table? A CSV file or another data file? It would help us to understand the context to [edit] your question and include what you currently have. – TT. Sep 10 '17 at 07:00
  • check out this answer by Remus Rusanu and also try exploring Partition switch :https://dba.stackexchange.com/questions/84164/sql-server-table-insert-performance-optimization – TheGameiswar Sep 10 '17 at 07:23
  • 1
    @rndus2r That question you linked to was about doing it in C#. We do not know what the context is... is he doing this from SQL Server, Java, C# (.NET), another environment still? Until the OP gives us the context, closing for duplicate might give the OP the wrong answer. – TT. Sep 10 '17 at 07:42
  • Point given, nevertheless it's a simple google search task. – rndus2r Sep 10 '17 at 07:44

0 Answers0