2

I am new to database,I am using SSMS 2008 R2 to import 2GB of data from a .csv file.

It is taking around 115mins to import.

Can anybody let me know any better way to perform this import.

2
  • You should show the definition of the table(s) involved, how the data is clustered, how many indexes it has, ... and some indication of the hardware on which the database it's running, to help assess whether 115 mins is considered normal or not.
    – joanolo
    Commented May 19, 2017 at 6:35
  • 1
    Not only that.... what code are you using to import it? As far as we can tell you're just typing it in manually.
    – Nick.Mc
    Commented May 19, 2017 at 8:32

1 Answer 1

7

You need to use bcp.exe or SSIS. Read Import and Export Bulk Data by Using the bcp Utility (SQL Server) and The Data Loading Performance Guide. Also, read How to Analyze SQL Server Performance to be able to tell why something is slow.

After you've read those, come back with a more actionable question, including structure of table, csv structure, repeatability of the job, access issues etc.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.