dbTalk Databases Forums  

Re: failure message for entire package

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


Discuss Re: failure message for entire package in the microsoft.public.sqlserver.dts forum.



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

Default Re: failure message for entire package - 07-15-2004 , 02:04 PM






In message <A7C5BB66-DBEE-4109-B737-EDF317363784 (AT) microsoft (DOT) com>, Dan D.
<DanD (AT) discussions (DOT) microsoft.com> writes
Quote:
Is there a way to send a message if any part of a package fails. This
way I'd only have to put one send mail task rather than have to put a
send mail task on each step.

Thanks,
Not from within the package no.
You can do some stuff outside of the package, perhaps by using the log
to SQL server option in the package and querying this afterwards for
example.

--
Darren Green (SQL Server MVP)
DTS - http://www.sqldts.com

PASS - the definitive, global community for SQL Server professionals
http://www.sqlpass.org



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

Default Re: failure message for entire package - 07-15-2004 , 02:21 PM






That would normally be done as a post DTS process. You could fire the
package in VB and look for errors there. If any were discovered you
could send a mail from VB.




Allan Mitchell (Microsoft SQL Server MVP)
MCSE,MCDBA
www.SQLDTS.com
www.konesans.com - for all your consultancy needs




Reply With Quote
  #3  
Old   
Dan D.
 
Posts: n/a

Default Re: failure message for entire package - 07-15-2004 , 02:27 PM



How do I pick out only the most recent verson of the package in sysdtspackagelog?
--
Dan D.


"Allan Mitchell" wrote:

Quote:
That would normally be done as a post DTS process. You could fire the
package in VB and look for errors there. If any were discovered you
could send a mail from VB.




Allan Mitchell (Microsoft SQL Server MVP)
MCSE,MCDBA
www.SQLDTS.com
www.konesans.com - for all your consultancy needs





Reply With Quote
  #4  
Old   
Darren Green
 
Posts: n/a

Default Re: failure message for entire package - 07-15-2004 , 02:39 PM



In message <E3CDE22B-C4A9-4428-A880-5FB99757BF4C (AT) microsoft (DOT) com>, Dan D.
<DanD (AT) discussions (DOT) microsoft.com> writes
Quote:
Do you mean querying the sysdtspackagelog and sysdtssteplog tables?

Thanks,
Yep that's right.

Whilst you can just run a query and order by date and such like, one tip
I like doing is to use the lineage variables. Turn them on, from on the
last tab of package properties. You can then use them as global
variables, and store the elsewhere, and or use them in queries to help
retrieve the exact run from the log tables.


--
Darren Green (SQL Server MVP)
DTS - http://www.sqldts.com

PASS - the definitive, global community for SQL Server professionals
http://www.sqlpass.org



Reply With Quote
  #5  
Old   
Dan D.
 
Posts: n/a

Default Re: failure message for entire package - 07-15-2004 , 02:59 PM



What does "show lineage variables as source column" mean? Where is it going to show them? How do you the latest version of the package (the one that is currently running) from sysdtspackagelog table?

Thanks,
--
Dan D.


"Darren Green" wrote:

Quote:
In message <E3CDE22B-C4A9-4428-A880-5FB99757BF4C (AT) microsoft (DOT) com>, Dan D.
DanD (AT) discussions (DOT) microsoft.com> writes
Do you mean querying the sysdtspackagelog and sysdtssteplog tables?

Thanks,

Yep that's right.

Whilst you can just run a query and order by date and such like, one tip
I like doing is to use the lineage variables. Turn them on, from on the
last tab of package properties. You can then use them as global
variables, and store the elsewhere, and or use them in queries to help
retrieve the exact run from the log tables.


--
Darren Green (SQL Server MVP)
DTS - http://www.sqldts.com

PASS - the definitive, global community for SQL Server professionals
http://www.sqlpass.org



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

Default Re: failure message for entire package - 07-15-2004 , 03:21 PM



In article <687E9DFD-9483-45BC-9AEA-2A2DB2F04057 (AT) microsoft (DOT) com>, Dan D. wrote:
Quote:
How do I pick out only the most recent verson of the package in sysdtspackagelog?

What about

SELECT .................... FROM msdb.dbo.sysdtspackagelog T1 WHERE
LogDate = (SELECT MAX(LogDate) FROM msdb.dbo.sysdtspackagelog T2 WHERE T1.name =
T2.name



Allan Mitchell (Microsoft SQL Server MVP)
MCSE,MCDBA
www.SQLDTS.com
www.konesans.com - for all your consultancy needs





Reply With Quote
  #7  
Old   
Darren Green
 
Posts: n/a

Default Re: failure message for entire package - 07-15-2004 , 03:34 PM



In message <846E4664-535E-447D-A48B-3371BC019C04 (AT) microsoft (DOT) com>, Dan D.
<DanD (AT) discussions (DOT) microsoft.com> writes
Quote:
Is a new lineagefull number generated every time the package runs?
Yes.

The variables are available as sources in a DataPump, and also as global
variables.

Allan's method my be simpler, but the lineage variables offer greater
precision and a degree of flexibility not available elsewhere. Choose
which works best for you.

For example my main ETL processes are controlled by a single master
package. The lineage variables are passed into all child packages and
used in explicit Exec SQL Task based logging calls to my own tables. I
can then combine the DTS logs with my own logs for example.




--
Darren Green (SQL Server MVP)
DTS - http://www.sqldts.com

PASS - the definitive, global community for SQL Server professionals
http://www.sqlpass.org



Reply With Quote
  #8  
Old   
Dan D.
 
Posts: n/a

Default Re: failure message for entire package - 07-15-2004 , 03:47 PM



I understand it better now. Thanks.
--
Dan D.


"Darren Green" wrote:

Quote:
In message <846E4664-535E-447D-A48B-3371BC019C04 (AT) microsoft (DOT) com>, Dan D.
DanD (AT) discussions (DOT) microsoft.com> writes
Is a new lineagefull number generated every time the package runs?

Yes.

The variables are available as sources in a DataPump, and also as global
variables.

Allan's method my be simpler, but the lineage variables offer greater
precision and a degree of flexibility not available elsewhere. Choose
which works best for you.

For example my main ETL processes are controlled by a single master
package. The lineage variables are passed into all child packages and
used in explicit Exec SQL Task based logging calls to my own tables. I
can then combine the DTS logs with my own logs for example.




--
Darren Green (SQL Server MVP)
DTS - http://www.sqldts.com

PASS - the definitive, global community for SQL Server professionals
http://www.sqlpass.org



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.