Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

how do i import text file with different delimited...HELP Expand / Collapse
Author
Message
Posted Thursday, June 19, 2008 11:50 AM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Tuesday, November 27, 2012 11:00 AM
Points: 14, Visits: 28
I am receiving various types of text file, some pipe delimited, some comma and some TAB. This is what I wrote but it only work for Comma Seperated. How do I specified the type of delimited???

SELECT *
FROM OPENROWSET ('MSDASQL',
'Driver={Microsoft Text Driver (*.txt; *.csv)};HDR=NO;IMEX=1;
DefaultDir=c:\;
Extensions=csv;',
'SELECT * FROM myFile.txt')


any help will be greatly appreciate it
Post #520085
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse