dbTalk Databases Forums  

Dynamic Filename / DTS Import

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss Dynamic Filename / DTS Import in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
T-SQL Coder
 
Posts: n/a

Default Dynamic Filename / DTS Import - 09-04-2004 , 09:44 AM






Hey,

I have a DTS import package which works a treat when it is referencing
the filename (txt file) setup via EM, but can you dynamically pass in a
filename of your choice to a DTS to use as the txt source file?

This DTS can be triggered via the web I want a text filename to be
dynamic so more than one person can fire off the DTS...without
overwriting the other users DTS if they have triggered the DTS off to
begin with.

Is this possible?



Reply With Quote
  #2  
Old   
Allan Mitchell
 
Posts: n/a

Default Re: Dynamic Filename / DTS Import - 09-04-2004 , 09:49 AM






You certainly can do this

Easiest ways.


1. Pass the filename as a Global variable to the package when called
through DTSRUN using the /A switch
2. Use the Dynamic Properties task

--
--

Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
www.konesans.com - Consultancy from the people who know


"T-SQL Coder" <t-sql (AT) microsoft (DOT) com> wrote

Quote:
Hey,

I have a DTS import package which works a treat when it is referencing
the filename (txt file) setup via EM, but can you dynamically pass in a
filename of your choice to a DTS to use as the txt source file?

This DTS can be triggered via the web I want a text filename to be
dynamic so more than one person can fire off the DTS...without
overwriting the other users DTS if they have triggered the DTS off to
begin with.

Is this possible?





Reply With Quote
  #3  
Old   
T-SQL Coder
 
Posts: n/a

Default Re: Dynamic Filename / DTS Import - 09-04-2004 , 10:37 AM



Yeah, I just found info on this...great. thanks...SQL Server never
ceases to amaze me how powerful it is! roll on Yukon!!!



Allan Mitchell wrote:

Quote:
You certainly can do this

Easiest ways.


1. Pass the filename as a Global variable to the package when called
through DTSRUN using the /A switch
2. Use the Dynamic Properties task


Reply With Quote
  #4  
Old   
T-SQL Coder
 
Posts: n/a

Default Re: Dynamic Filename / DTS Import - 09-04-2004 , 10:38 AM



Oh, are 1 and 2 linked? i.e. pass the var in 1 and use it in 2 or are
they seperate?



Allan Mitchell wrote:

Quote:
You certainly can do this

Easiest ways.


1. Pass the filename as a Global variable to the package when called
through DTSRUN using the /A switch
2. Use the Dynamic Properties task


Reply With Quote
  #5  
Old   
Allan Mitchell
 
Posts: n/a

Default Re: Dynamic Filename / DTS Import - 09-04-2004 , 11:22 AM



They can be used in conjustion with one another but personally I wouldn't.

--
--

Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
www.konesans.com - Consultancy from the people who know


"T-SQL Coder" <t-sql (AT) microsoft (DOT) com> wrote

Quote:
Oh, are 1 and 2 linked? i.e. pass the var in 1 and use it in 2 or are
they seperate?



Allan Mitchell wrote:

You certainly can do this

Easiest ways.


1. Pass the filename as a Global variable to the package when called
through DTSRUN using the /A switch
2. Use the Dynamic Properties task




Reply With Quote
  #6  
Old   
T-SQL Coder
 
Posts: n/a

Default Re: Dynamic Filename / DTS Import - 09-06-2004 , 12:14 PM



Why?



Allan Mitchell wrote:
Quote:
They can be used in conjustion with one another but personally I wouldn't.


Reply With Quote
  #7  
Old   
Allan Mitchell
 
Posts: n/a

Default Re: Dynamic Filename / DTS Import - 09-06-2004 , 01:49 PM



What are you going to do wi tht eglobal variable in the Dynamic Properties
task? Assign a value. Why do I want to go through the extra step when I
can pass a value to a GV on the cmdline and cut out the middle man.

--
--

Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
www.konesans.com - Consultancy from the people who know


"T-SQL Coder" <t-sql (AT) microsoft (DOT) com> wrote

Quote:
Why?



Allan Mitchell wrote:
They can be used in conjustion with one another but personally I
wouldn't.




Reply With Quote
  #8  
Old   
T-SQL Coder
 
Posts: n/a

Default Re: Dynamic Filename / DTS Import - 09-06-2004 , 01:59 PM



True, what am I doing is as you say...setting up several GV's and
passing them in via /A of dtsrun to be used in SQL tasks and other
processes in a DTS.





Allan Mitchell wrote:
Quote:
What are you going to do wi tht eglobal variable in the Dynamic Properties
task? Assign a value. Why do I want to go through the extra step when I
can pass a value to a GV on the cmdline and cut out the middle man.


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.