Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2008 Forums
 Transact-SQL (2008)
 Convert a matrix to a table

Author  Topic 

zhshqzyc
Posting Yak Master

240 Posts

Posted - 2010-12-08 : 17:05:56
Hi, I have a big matrix that is in a text file. The file is huge.
The size is from 100MB to 10GB. I want to insert it into a table.
Using insert statement is infeasible.

How to do it?

Thanks.

robvolk
Most Valuable Yak

15732 Posts

Posted - 2010-12-08 : 17:09:30
Is the file formatted? How many columns do you have? Does it have to fit an existing table? If so, please post the DDL statement for that table.

Depending on how the file is structured you could use bcp or BULK INSERT, or if it's more complicated then SSIS might be a better option. There's no way to know without more details.
Go to Top of Page
   

- Advertisement -