Therefore, in the old days of SQL Server 2000 I often created DTS packages to suck in my data. DTS was OK, especially the funky grey arrows, but it was a little time consuming. Then - disaster - DTS was phased out in favour of SSIS. At No Frills Corp our DBAs have not been able to give me a server that SSIS actually works on, so I was a bit stuck.
It was then that I came across the beatifully simple SQL command, BULK INSERT.
Just point a BULK INSERT command at your text file, tell it where to put the data, and you are all set. It can't be that easy can it? Yes, it really can:
BULK INSERT Chimps FROM 'D:\primates\chimps.csv' WITH ( FIELDTERMINATOR =',', ROWTERMINATOR ='\n' )Cashback!
No comments:
Post a Comment