Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How can I create a table from a text file with SQL Server

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
Hello I`d like to Know how I can create a table from a text file,I think that I have to import a text file but I don't Know how I can do it.
Thanks in advance
 
maybe try creating an instance of the filesystemobject inside of SQL
 
If you are using Oracle, you need to create the table structure first and then you can use SQL*Loader. I'm going to save the rest of the details until I find out which RDBMS you are using...


Terry M. Hoey
th3856@txmail.sbc.com

Ever notice that by the time that you realize that you ran a truncate script on the wrong instance, it is too late to stop it?
 
If you're using SQLServer 7.0 you can use Data Transformation Services. Either use the Wizared on mmc tool bar or 'All tasks'|'Import' (right click) from the database target. It will guide you in setting up import. You can then save the VB code - if you're doing this in a program and use/modify that code.
See BOL for more info.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top