dbTalk Databases Forums  

Can I tell if I'm Scheduled or Run from Enterprise

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


Discuss Can I tell if I'm Scheduled or Run from Enterprise in the microsoft.public.sqlserver.dts forum.



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

Default Can I tell if I'm Scheduled or Run from Enterprise - 04-19-2006 , 06:05 PM






Is there an env var or property that tells me if I have been run from
Enterprise Manager of from DTSRun (e.g. scheduled).
If I have been run from the GUI I can request input, or show errors in an
activex, but if not, I would want to quit immediately.
--
Thanks and Good Luck.
Fergus


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

Default Re: Can I tell if I'm Scheduled or Run from Enterprise - 04-19-2006 , 07:12 PM






Hello Fergus,

Once the package is loaded up there is no way from within DTS to tell how
you was executed AFAIK. DTS is one of those apps where I never think it
good to request user input. A lot of the uses for DTS are scheduled and
unattended so asking the user to enter something in a box will probably not
work very well.

Try having the user enter the values for the scheduled running into an external
medium that can be read by the Dynamic Properties Task.

To see what errors have occured you should enable logging.


Allan Mitchell
www.SQLDTS.com
www.SQLIS.com
www.Konesans.com

Quote:
Is there an env var or property that tells me if I have been run from
Enterprise Manager of from DTSRun (e.g. scheduled).
If I have been run from the GUI I can request input, or show errors in
an
activex, but if not, I would want to quit immediately.



Reply With Quote
  #3  
Old   
Fergus
 
Posts: n/a

Default Re: Can I tell if I'm Scheduled or Run from Enterprise - 04-25-2006 , 03:43 PM



Thanks, I agree that I don't want to be doing UI stuff in a scheduled DTS job.
However, in another response (to IMcphee) you had written:
"You pass in the connection info to the package on the cmdline using DTSRun."
How would I do this? I was under the impression that DTSRun could not pass
anything to a package.
--
Thanks and Good Luck.
Fergus



"Allan Mitchell" wrote:

Quote:
Hello Fergus,

Once the package is loaded up there is no way from within DTS to tell how
you was executed AFAIK. DTS is one of those apps where I never think it
good to request user input. A lot of the uses for DTS are scheduled and
unattended so asking the user to enter something in a box will probably not
work very well.

Try having the user enter the values for the scheduled running into an external
medium that can be read by the Dynamic Properties Task.

To see what errors have occured you should enable logging.


Allan Mitchell
www.SQLDTS.com
www.SQLIS.com
www.Konesans.com

Is there an env var or property that tells me if I have been run from
Enterprise Manager of from DTSRun (e.g. scheduled).
If I have been run from the GUI I can request input, or show errors in
an
activex, but if not, I would want to quit immediately.




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

Default Re: Can I tell if I'm Scheduled or Run from Enterprise - 04-25-2006 , 07:44 PM



Hello Fergus,

Have a look at the /A switch. It allows you to set GV values from the cmd
line


Allan Mitchell
www.SQLDTS.com
www.SQLIS.com
www.Konesans.com

Quote:
Thanks, I agree that I don't want to be doing UI stuff in a scheduled
DTS job.
However, in another response (to IMcphee) you had written:
"You pass in the connection info to the package on the cmdline using
DTSRun."
How would I do this? I was under the impression that DTSRun could not
pass
anything to a package.
"Allan Mitchell" wrote:

Hello Fergus,

Once the package is loaded up there is no way from within DTS to tell
how you was executed AFAIK. DTS is one of those apps where I never
think it good to request user input. A lot of the uses for DTS are
scheduled and unattended so asking the user to enter something in a
box will probably not work very well.

Try having the user enter the values for the scheduled running into
an external medium that can be read by the Dynamic Properties Task.

To see what errors have occured you should enable logging.

Allan Mitchell
www.SQLDTS.com
www.SQLIS.com
www.Konesans.com
Is there an env var or property that tells me if I have been run
from
Enterprise Manager of from DTSRun (e.g. scheduled).
If I have been run from the GUI I can request input, or show errors
in
an
activex, but if not, I would want to quit immediately.



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.