dbTalk Databases Forums  

Dynamic DTS (Urgent !!!)

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


Discuss Dynamic DTS (Urgent !!!) in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Malkesh
 
Posts: n/a

Default Dynamic DTS (Urgent !!!) - 07-08-2005 , 05:56 AM






Hi All,
I want to create DTS package in which
i will have source is MS Access file.
and import the data to my SQL Server
Database.
Now i want to pass full qualified path of
..mdb file thru SP parameter and then
execute the package thru SP itself.
How can i do this ? If any code sample
is there it would be great help for me.
Thanks & Regards
Malkesh

Reply With Quote
  #2  
Old   
David Portas
 
Posts: n/a

Default Re: Dynamic DTS (Urgent !!!) - 07-08-2005 , 06:03 AM






http://www.sqldts.com/default.aspx?210

However, if your MDB file is accessible to the server anyway then you
may want to consider creating a linked server to the database instead
and then importing the data using starndard SQL INSERT statements.

--
David Portas
SQL Server MVP
--


Reply With Quote
  #3  
Old   
David Portas
 
Posts: n/a

Default Re: Dynamic DTS (Urgent !!!) - 07-08-2005 , 06:03 AM



http://www.sqldts.com/default.aspx?210

However, if your MDB file is accessible to the server anyway then you
may want to consider creating a linked server to the database instead
and then importing the data using starndard SQL INSERT statements.

--
David Portas
SQL Server MVP
--


Reply With Quote
  #4  
Old   
Malkesh
 
Posts: n/a

Default Re: Dynamic DTS (Urgent !!!) - 07-11-2005 , 12:01 AM



Thanks David,
But my requirement is that, client
will specify source file name which is
Access Database thru Application and
using that file i need to export all the tables
in SQL Server which is fixed (not pass at runtime).
So i need to create a SP and pass that source file path
as parameter. Now how can i pass that parameter in DTS package ?
--
Thanks & Regards
Malkesh


"David Portas" wrote:

Quote:
http://www.sqldts.com/default.aspx?210

However, if your MDB file is accessible to the server anyway then you
may want to consider creating a linked server to the database instead
and then importing the data using starndard SQL INSERT statements.

--
David Portas
SQL Server MVP
--



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

Default Re: Dynamic DTS (Urgent !!!) - 07-11-2005 , 12:27 AM



You can also have the package dynamically allocate the mdb filename through
a Dynamic Properties task. You can also pass to DTSRUN the /A switch which
will populate a Global variable in the package. The package will then be
built to allocate the files name passed to the Access connection. If you
are using code anyway can you not use the object model to specify the
DataSource property og the Access connection before calling Execute()?

--



Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
www.SQLIS.com - You thought DTS was good. here we show you the new stuff.
www.konesans.com - Consultancy from the people who know


"Malkesh" <Malkesh (AT) discussions (DOT) microsoft.com> wrote

Quote:
Thanks David,
But my requirement is that, client
will specify source file name which is
Access Database thru Application and
using that file i need to export all the tables
in SQL Server which is fixed (not pass at runtime).
So i need to create a SP and pass that source file path
as parameter. Now how can i pass that parameter in DTS package ?
--
Thanks & Regards
Malkesh


"David Portas" wrote:

http://www.sqldts.com/default.aspx?210

However, if your MDB file is accessible to the server anyway then you
may want to consider creating a linked server to the database instead
and then importing the data using starndard SQL INSERT statements.

--
David Portas
SQL Server MVP
--





Reply With Quote
  #6  
Old   
David Portas
 
Posts: n/a

Default Re: Dynamic DTS (Urgent !!!) - 07-11-2005 , 03:01 AM



Quote:
Now how can i pass that parameter in DTS package ?
In the link I posted before, the Database Journal article demonstrates
how to do that. As Allan stated, you can also use the DTSRUN exe to
pass a global variable as a parameter.

Quote:
i need to export all the tables
Do you know the table names in advance? If so, you can build a package
and parameterize the name as discussed above. If not, then you'll have
to construct the DTS transformations dynamically, using VB for example.

--
David Portas
SQL Server MVP
--



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.