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)
 Losing first row on text file query

Author  Topic 

owen912
Starting Member

31 Posts

Posted - 2005-04-08 : 13:07:27
I created a linked server and then ran a select statement on a file on the designated directory:

SELECT * FROM txtImportFiles...gradereport#txt

The source text file does not have the first row as column names, so when I run the query in query analyzer used actual data as column headers. I created an .ini file with column headers set to false (ColNameHeader=False), but that has not affected things.

Is this just a Query Analyzer thing? Or when I write SQL to update tables in my database will I lose the first row of data.

owen912
Starting Member

31 Posts

Posted - 2005-04-08 : 13:57:08
Well I found a solution. The application that generates the text file has a configuration setting that lets me set the columns names as the first row.

Problem solved for this task, but I still interested hearing any input regarding the initial question.

Thanks,

Mike
Go to Top of Page
   

- Advertisement -