dbTalk Databases Forums  

DTS: Strange error when calling a sub-package.

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


Discuss DTS: Strange error when calling a sub-package. in the microsoft.public.sqlserver.dts forum.



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

Default DTS: Strange error when calling a sub-package. - 06-07-2004 , 10:59 PM






(SQL Server 2000, SP3a)

Hello all!

I've been wrestling with a bear of a problem with my DTS Package. It has a sub-package
(several of them, actually), and when I run the package in the DTS "designer" (from
Enterprise Manager) or DTSRUN.exe, everything works splendidly!

I have since made a VBScript "driver" program that is using the COM interface to DTS, and
when I execute the package, it fails with the following error:

Execution was canceled by user.

This error occurs just before calling the sub-package (which is invoked with the "Execute
Package Task"), but the previous two tasks (Dynamic Properties and ActiveX Tasks) are
successful before that Execute Package Task fails with the above error.

I've been pulling my hair out all day trying to figure out what's causing this.

If anyone can help shed some light on this issue, I'd be *hugely* obliged! Thanks in
advance!

John Peterson



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

Default Re: Strange error when calling a sub-package. - 06-08-2004 , 03:15 AM






Set all your tasks to execute on the main thread.

Are you using Events ?

--

----------------------------

Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
I support PASS - the definitive, global community
for SQL Server professionals - http://www.sqlpass.org


"John Peterson" <j0hnp (AT) comcast (DOT) net> wrote

Quote:
(SQL Server 2000, SP3a)

Hello all!

I've been wrestling with a bear of a problem with my DTS Package. It has
a sub-package
(several of them, actually), and when I run the package in the DTS
"designer" (from
Enterprise Manager) or DTSRUN.exe, everything works splendidly!

I have since made a VBScript "driver" program that is using the COM
interface to DTS, and
when I execute the package, it fails with the following error:

Execution was canceled by user.

This error occurs just before calling the sub-package (which is invoked
with the "Execute
Package Task"), but the previous two tasks (Dynamic Properties and ActiveX
Tasks) are
successful before that Execute Package Task fails with the above error.

I've been pulling my hair out all day trying to figure out what's causing
this.

If anyone can help shed some light on this issue, I'd be *hugely* obliged!
Thanks in
advance!

John Peterson





Reply With Quote
  #3  
Old   
John Peterson
 
Posts: n/a

Default Re: Strange error when calling a sub-package. - 06-08-2004 , 08:18 AM



Hey Allan!

Yeah...all my tasks were executing on the Main thread. I'm not sure what you mean by
"using Events"?

I did stumble across this issue:

http://support.microsoft.com/default...b;EN-US;319058



But I don't know how to handle events in VBScript. My guess is that I can't. :-(



"Allan Mitchell" <allan (AT) no-spam (DOT) sqldts.com> wrote

Quote:
Set all your tasks to execute on the main thread.

Are you using Events ?

--

----------------------------

Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
I support PASS - the definitive, global community
for SQL Server professionals - http://www.sqlpass.org


"John Peterson" <j0hnp (AT) comcast (DOT) net> wrote in message
news:eJTre0QTEHA.2716 (AT) tk2msftngp13 (DOT) phx.gbl...
(SQL Server 2000, SP3a)

Hello all!

I've been wrestling with a bear of a problem with my DTS Package. It has
a sub-package
(several of them, actually), and when I run the package in the DTS
"designer" (from
Enterprise Manager) or DTSRUN.exe, everything works splendidly!

I have since made a VBScript "driver" program that is using the COM
interface to DTS, and
when I execute the package, it fails with the following error:

Execution was canceled by user.

This error occurs just before calling the sub-package (which is invoked
with the "Execute
Package Task"), but the previous two tasks (Dynamic Properties and ActiveX
Tasks) are
successful before that Execute Package Task fails with the above error.

I've been pulling my hair out all day trying to figure out what's causing
this.

If anyone can help shed some light on this issue, I'd be *hugely* obliged!
Thanks in
advance!

John Peterson







Reply With Quote
  #4  
Old   
John Peterson
 
Posts: n/a

Default Re: Strange error when calling a sub-package. - 06-08-2004 , 11:44 PM



Well...I got to the heart of my problem, and it can be best explained by this MS KB
article:

http://support.microsoft.com/default...b;EN-US;319058

I had someone help me write a quick-n-dirty .NET C# wrapper for the DTS package, and when
we put in the event handler for OnQueryCancel, sure enough, this bug reared its ugly head.
:-(

It's unfortunate, because I had some measure of work invested in my VBScript application,
but because I can't write an event handler in VBScript, I cannot rectify this situation in
that environment.


"John Peterson" <j0hnp (AT) comcast (DOT) net> wrote

Quote:
Hey Allan!

Yeah...all my tasks were executing on the Main thread. I'm not sure what you mean by
"using Events"?

I did stumble across this issue:

http://support.microsoft.com/default...b;EN-US;319058



But I don't know how to handle events in VBScript. My guess is that I can't. :-(



"Allan Mitchell" <allan (AT) no-spam (DOT) sqldts.com> wrote in message
news:OrnlCDTTEHA.3944 (AT) TK2MSFTNGP12 (DOT) phx.gbl...
Set all your tasks to execute on the main thread.

Are you using Events ?

--

----------------------------

Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
I support PASS - the definitive, global community
for SQL Server professionals - http://www.sqlpass.org


"John Peterson" <j0hnp (AT) comcast (DOT) net> wrote in message
news:eJTre0QTEHA.2716 (AT) tk2msftngp13 (DOT) phx.gbl...
(SQL Server 2000, SP3a)

Hello all!

I've been wrestling with a bear of a problem with my DTS Package. It has
a sub-package
(several of them, actually), and when I run the package in the DTS
"designer" (from
Enterprise Manager) or DTSRUN.exe, everything works splendidly!

I have since made a VBScript "driver" program that is using the COM
interface to DTS, and
when I execute the package, it fails with the following error:

Execution was canceled by user.

This error occurs just before calling the sub-package (which is invoked
with the "Execute
Package Task"), but the previous two tasks (Dynamic Properties and ActiveX
Tasks) are
successful before that Execute Package Task fails with the above error.

I've been pulling my hair out all day trying to figure out what's causing
this.

If anyone can help shed some light on this issue, I'd be *hugely* obliged!
Thanks in
advance!

John Peterson









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.