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
 Import/Export (DTS) and Replication (2000)
 How to create Excute DTs Through job

Author  Topic 

YogeshDesai
Posting Yak Master

136 Posts

Posted - 2007-04-24 : 01:43:48
Hi all,
I have created one Dts package and I want to excute it on some condition.

E.g. I am checking Enddate from table,It compare with current date.
If the condition is true i wanna excute the dts package.
For more information here is the query which I m using.

"select Enddate from criscampaign
where convert ( datetime, CONVERT(VARCHAR(23), enddate, 106))= convert ( datetime, CONVERT(VARCHAR(23), getdate(), 106))"

if this condition is true,
DTS package should be run, I m just little bit confused if the condition is false then how to handle.


Please help,

Yogesh V. Desai. | SQLDBA|

rmiao
Master Smack Fu Yak Hacker

7266 Posts

Posted - 2007-04-24 : 10:09:36
You can write a script. If above condition is true, call dtsrun to execute the package with xp_cmdshell in the script.
Go to Top of Page
   

- Advertisement -