DTS import csv - dynamic file name 
Author Message
 DTS import csv - dynamic file name
I have an asp application where a user can upload a .csv file.  The file
name will be different each time.

I need to know how to change the source file name the package parses
into a specified table.  Right now the package looks for a specific
file, but it will be different each time.

Thanks in advance.



Fri, 06 Jan 2006 14:39:26 GMT
 DTS import csv - dynamic file name

Assuming you have SQL Server 2000, you can use a Dynamic Properties task to set the file name.  The file name can be passed in through a global variable.

--
Tom

---------------------------------------------------------------
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Columnist, SQL Server Professional
Toronto, ON Canada
www.pinnaclepublishing.com/sql

I have an asp application where a user can upload a .csv file.  The file
name will be different each time.

I need to know how to change the source file name the package parses
into a specified table.  Right now the package looks for a specific
file, but it will be different each time.

Thanks in advance.



Fri, 06 Jan 2006 14:47:47 GMT
 DTS import csv - dynamic file name
Sorry - I should have mentioned I have sql 7.
Quote:

> Assuming you have SQL Server 2000, you can use a Dynamic Properties
> task to set the file name.  The file name can be passed in through a
> global variable.

> --
> Tom

> ---------------------------------------------------------------
> Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
> SQL Server MVP
> Columnist, SQL Server Professional
> Toronto, ON Canada
> www.pinnaclepublishing.com/sql



> I have an asp application where a user can upload a .csv file.  The
> file
> name will be different each time.

> I need to know how to change the source file name the package parses
> into a specified table.  Right now the package looks for a specific
> file, but it will be different each time.

> Thanks in advance.



Fri, 06 Jan 2006 14:54:09 GMT
 DTS import csv - dynamic file name
Hi

Check out

http://www.sqldts.com/default.aspx?6,101,200,0,1

John


Quote:
> I have an asp application where a user can upload a .csv file.  The file
> name will be different each time.

> I need to know how to change the source file name the package parses
> into a specified table.  Right now the package looks for a specific
> file, but it will be different each time.

> Thanks in advance.



Fri, 06 Jan 2006 14:56:25 GMT
 DTS import csv - dynamic file name

In that case, you can replace the Dynamic Properties Task with an equivalent ActiveX Script task to set the file name based on the global variable.

--
Tom

---------------------------------------------------------------
Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
SQL Server MVP
Columnist, SQL Server Professional
Toronto, ON Canada
www.pinnaclepublishing.com/sql

Sorry - I should have mentioned I have sql 7.

Quote:

> Assuming you have SQL Server 2000, you can use a Dynamic Properties
> task to set the file name.  The file name can be passed in through a
> global variable.

> --
> Tom

> ---------------------------------------------------------------
> Thomas A. Moreau, BSc, PhD, MCSE, MCDBA
> SQL Server MVP
> Columnist, SQL Server Professional
> Toronto, ON Canada
> www.pinnaclepublishing.com/sql



> I have an asp application where a user can upload a .csv file.  The
> file
> name will be different each time.

> I need to know how to change the source file name the package parses
> into a specified table.  Right now the package looks for a specific
> file, but it will be different each time.

> Thanks in advance.



Fri, 06 Jan 2006 15:09:30 GMT
 
 [ 5 post ] 

 Relevant Pages 

1. Dts Import Question:Importing Csv file in an existing SQL2000 table with row-level conditions

2. Importing a Text File via DTS and adding the File Name as a column via DTS

3. Importing unicode CSV file via DTS

4. SQL 7.0 DTS Import of CSV files

5. Importing unicode CSV file via DTS

6. DTS-CSV import file has dangling comma at the end of the record

7. SQL 7.0 DTS Import of CSV Files

8. DTS import error from CSV file - cannot insert value NULL

9. SQL 7.0 DTS Import of CSV files

10. Importing a 66 gigabyte csv file into SQL2000 using DTS

11. DTS - importing CSV file drops last record

12. DTS and importing CSV/ascii files?


 
Powered by phpBB® Forum Software