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 2000 Forums
 Transact-SQL (2000)
 How to read csv file and then insert it into my da

Author  Topic 

kamii47
Constraint Violating Yak Guru

353 Posts

Posted - 2006-12-26 : 06:03:09
How can I read csv file and then insert it into my database table ?

harsh_athalye
Master Smack Fu Yak Hacker

5581 Posts

Posted - 2006-12-26 : 06:06:19
Make use of BCP/DTS tool.

Harsh Athalye
India.
"The IMPOSSIBLE is often UNTRIED"
Go to Top of Page

kamii47
Constraint Violating Yak Guru

353 Posts

Posted - 2006-12-26 : 06:37:14
I don't want's to use BCP/DTS tool.
I have used some query previously which i forget.
Can any body help ?
Go to Top of Page

harsh_athalye
Master Smack Fu Yak Hacker

5581 Posts

Posted - 2006-12-26 : 06:41:11
You can make use of OPENROWSET().

Check this topic:
[url]http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=49926[/url]

Harsh Athalye
India.
"The IMPOSSIBLE is often UNTRIED"
Go to Top of Page

BrianArmstrong
Starting Member

6 Posts

Posted - 2006-12-27 : 15:33:32
If you want to pull the data into a single table, without doing any formatting first, you can also use the BULK INSERT command.

[url]http://msdn2.microsoft.com/en-us/library/ms188365.aspx[/url]
Go to Top of Page
   

- Advertisement -