dbTalk Databases Forums  

Disabling DTS Bulk insert task

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


Discuss Disabling DTS Bulk insert task in the microsoft.public.sqlserver.dts forum.



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

Default Disabling DTS Bulk insert task - 05-07-2004 , 08:13 AM






Is it possible to disable the DTS Bulk Insert task through ActiveX scripting
if so can anybody direct me to some good documentation?

Many thanks
Simon



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

Default Re: Disabling DTS Bulk insert task - 05-07-2004 , 08:59 AM






Look for the Step object and disable.

Have a look here and I do it in my package (Not the Bulk Insert task but the
theory is the same) points 2 & 4

Looping, Importing and Archiving
(http://www.sqldts.com/Default.aspx?246)

--
--

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote

Quote:
Is it possible to disable the DTS Bulk Insert task through ActiveX
scripting
if so can anybody direct me to some good documentation?

Many thanks
Simon





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

Default Re: Disabling DTS Bulk insert task - 05-08-2004 , 04:50 PM



In message <eOrIQUDNEHA.2976 (AT) TK2MSFTNGP10 (DOT) phx.gbl>, Simon Whale
<simon (AT) noway (DOT) ukdatait.com> writes
Quote:
Is it possible to disable the DTS Bulk Insert task through ActiveX scripting
if so can anybody direct me to some good documentation?

Many thanks
Simon


The article linked below also demonstrates "disabling" a task. Both
methods work fine, just personal taste.

Skip the execution of an individual Task
(http://www.sqldts.com/default.aspx?214)


--
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
  #4  
Old   
Simon Whale
 
Posts: n/a

Default Re: Disabling DTS Bulk insert task - 05-10-2004 , 03:56 AM



Allan,

have change the code in your example as suggested in step 4

<SNIPPET>
if ShouldILoop = True then
set BulkIns = pkg.Tasks("DTSTask_DTSBulkInsertTask_1").CustomTas k
BulkIns.DisableTask = False
BulkIns.DataFile = DTSGlobalVariables("gv_FileFullName").Value
else
....
....
End if

< END SNIPPET>

but when i run the package, i get the following error message

Error Code: 0
Error Source= Microsoft VBScript runtime error
Error Description: Object doesn't support this propery or method:
'BulkIns.DisableTask'

Error on Line 21

Many Thanks for your help

Simon Whale

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

Quote:
Look for the Step object and disable.

Have a look here and I do it in my package (Not the Bulk Insert task but
the
theory is the same) points 2 & 4

Looping, Importing and Archiving
(http://www.sqldts.com/Default.aspx?246)

--
--

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote in message
news:eOrIQUDNEHA.2976 (AT) TK2MSFTNGP10 (DOT) phx.gbl...
Is it possible to disable the DTS Bulk Insert task through ActiveX
scripting
if so can anybody direct me to some good documentation?

Many thanks
Simon







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

Default Re: Disabling DTS Bulk insert task - 05-10-2004 , 04:09 AM



There is no such method as DisableTask.

Check my code again.

I use DisableStep which is a method of the Step object.



--

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

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote

Quote:
Allan,

have change the code in your example as suggested in step 4

SNIPPET
if ShouldILoop = True then
set BulkIns = pkg.Tasks("DTSTask_DTSBulkInsertTask_1").CustomTas k
BulkIns.DisableTask = False
BulkIns.DataFile = DTSGlobalVariables("gv_FileFullName").Value
else
....
....
End if

END SNIPPET

but when i run the package, i get the following error message

Error Code: 0
Error Source= Microsoft VBScript runtime error
Error Description: Object doesn't support this propery or method:
'BulkIns.DisableTask'

Error on Line 21

Many Thanks for your help

Simon Whale

"Allan Mitchell" <allan (AT) no-spam (DOT) sqldts.com> wrote in message
news:us9qJrDNEHA.3572 (AT) tk2msftngp13 (DOT) phx.gbl...
Look for the Step object and disable.

Have a look here and I do it in my package (Not the Bulk Insert task but
the
theory is the same) points 2 & 4

Looping, Importing and Archiving
(http://www.sqldts.com/Default.aspx?246)

--
--

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote in message
news:eOrIQUDNEHA.2976 (AT) TK2MSFTNGP10 (DOT) phx.gbl...
Is it possible to disable the DTS Bulk Insert task through ActiveX
scripting
if so can anybody direct me to some good documentation?

Many thanks
Simon









Reply With Quote
  #6  
Old   
Simon Whale
 
Posts: n/a

Default Re: Disabling DTS Bulk insert task - 05-10-2004 , 06:02 AM



Error Code: 0
Error Source= Microsoft VBScript runtime error
Error Description: Object doesn't support this propery or
method:'BulkIns.DisableStep

this is the error message i get if i use the disablesetp method with the
bulk insert task.

Simon

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

Quote:
There is no such method as DisableTask.

Check my code again.

I use DisableStep which is a method of the Step object.



--

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

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote in message
news:e5zD9ymNEHA.2976 (AT) TK2MSFTNGP10 (DOT) phx.gbl...
Allan,

have change the code in your example as suggested in step 4

SNIPPET
if ShouldILoop = True then
set BulkIns = pkg.Tasks("DTSTask_DTSBulkInsertTask_1").CustomTas k
BulkIns.DisableTask = False
BulkIns.DataFile = DTSGlobalVariables("gv_FileFullName").Value
else
....
....
End if

END SNIPPET

but when i run the package, i get the following error message

Error Code: 0
Error Source= Microsoft VBScript runtime error
Error Description: Object doesn't support this propery or method:
'BulkIns.DisableTask'

Error on Line 21

Many Thanks for your help

Simon Whale

"Allan Mitchell" <allan (AT) no-spam (DOT) sqldts.com> wrote in message
news:us9qJrDNEHA.3572 (AT) tk2msftngp13 (DOT) phx.gbl...
Look for the Step object and disable.

Have a look here and I do it in my package (Not the Bulk Insert task
but
the
theory is the same) points 2 & 4

Looping, Importing and Archiving
(http://www.sqldts.com/Default.aspx?246)

--
--

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote in message
news:eOrIQUDNEHA.2976 (AT) TK2MSFTNGP10 (DOT) phx.gbl...
Is it possible to disable the DTS Bulk Insert task through ActiveX
scripting
if so can anybody direct me to some good documentation?

Many thanks
Simon











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

Default Re: Disabling DTS Bulk insert task - 05-10-2004 , 06:36 AM



OK

Here is code that I have just built and used successfully.


Function Main()

dim stp

set stp = DTSGlobalVariables.Parent.Steps("DTSStep_DTSBulkIn sertTask_1")

stp.DisableStep = True



Main = DTSTaskExecResult_Success
End Function


--

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

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote

Quote:
Error Code: 0
Error Source= Microsoft VBScript runtime error
Error Description: Object doesn't support this propery or
method:'BulkIns.DisableStep

this is the error message i get if i use the disablesetp method with the
bulk insert task.

Simon

"Allan Mitchell" <allan (AT) no-spam (DOT) sqldts.com> wrote in message
news:eKlnW6mNEHA.1608 (AT) TK2MSFTNGP12 (DOT) phx.gbl...
There is no such method as DisableTask.

Check my code again.

I use DisableStep which is a method of the Step object.



--

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

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote in message
news:e5zD9ymNEHA.2976 (AT) TK2MSFTNGP10 (DOT) phx.gbl...
Allan,

have change the code in your example as suggested in step 4

SNIPPET
if ShouldILoop = True then
set BulkIns = pkg.Tasks("DTSTask_DTSBulkInsertTask_1").CustomTas k
BulkIns.DisableTask = False
BulkIns.DataFile = DTSGlobalVariables("gv_FileFullName").Value
else
....
....
End if

END SNIPPET

but when i run the package, i get the following error message

Error Code: 0
Error Source= Microsoft VBScript runtime error
Error Description: Object doesn't support this propery or method:
'BulkIns.DisableTask'

Error on Line 21

Many Thanks for your help

Simon Whale

"Allan Mitchell" <allan (AT) no-spam (DOT) sqldts.com> wrote in message
news:us9qJrDNEHA.3572 (AT) tk2msftngp13 (DOT) phx.gbl...
Look for the Step object and disable.

Have a look here and I do it in my package (Not the Bulk Insert task
but
the
theory is the same) points 2 & 4

Looping, Importing and Archiving
(http://www.sqldts.com/Default.aspx?246)

--
--

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote in message
news:eOrIQUDNEHA.2976 (AT) TK2MSFTNGP10 (DOT) phx.gbl...
Is it possible to disable the DTS Bulk Insert task through ActiveX
scripting
if so can anybody direct me to some good documentation?

Many thanks
Simon













Reply With Quote
  #8  
Old   
Simon Whale
 
Posts: n/a

Default Re: Disabling DTS Bulk insert task - 05-10-2004 , 06:50 AM



Allan,

Thanks for that code it works, can you direct me to a good source that
shows me what methods i can use with Bulk insert Task, as i want to also be
able to specify the filename at runtime.

again many thanks

Simon

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

Quote:
OK

Here is code that I have just built and used successfully.


Function Main()

dim stp

set stp = DTSGlobalVariables.Parent.Steps("DTSStep_DTSBulkIn sertTask_1")

stp.DisableStep = True



Main = DTSTaskExecResult_Success
End Function


--

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

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote in message
news:u1fAd5nNEHA.628 (AT) TK2MSFTNGP11 (DOT) phx.gbl...
Error Code: 0
Error Source= Microsoft VBScript runtime error
Error Description: Object doesn't support this propery or
method:'BulkIns.DisableStep

this is the error message i get if i use the disablesetp method with the
bulk insert task.

Simon

"Allan Mitchell" <allan (AT) no-spam (DOT) sqldts.com> wrote in message
news:eKlnW6mNEHA.1608 (AT) TK2MSFTNGP12 (DOT) phx.gbl...
There is no such method as DisableTask.

Check my code again.

I use DisableStep which is a method of the Step object.



--

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

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote in message
news:e5zD9ymNEHA.2976 (AT) TK2MSFTNGP10 (DOT) phx.gbl...
Allan,

have change the code in your example as suggested in step 4

SNIPPET
if ShouldILoop = True then
set BulkIns =
pkg.Tasks("DTSTask_DTSBulkInsertTask_1").CustomTas k
BulkIns.DisableTask = False
BulkIns.DataFile = DTSGlobalVariables("gv_FileFullName").Value
else
....
....
End if

END SNIPPET

but when i run the package, i get the following error message

Error Code: 0
Error Source= Microsoft VBScript runtime error
Error Description: Object doesn't support this propery or method:
'BulkIns.DisableTask'

Error on Line 21

Many Thanks for your help

Simon Whale

"Allan Mitchell" <allan (AT) no-spam (DOT) sqldts.com> wrote in message
news:us9qJrDNEHA.3572 (AT) tk2msftngp13 (DOT) phx.gbl...
Look for the Step object and disable.

Have a look here and I do it in my package (Not the Bulk Insert
task
but
the
theory is the same) points 2 & 4

Looping, Importing and Archiving
(http://www.sqldts.com/Default.aspx?246)

--
--

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote in message
news:eOrIQUDNEHA.2976 (AT) TK2MSFTNGP10 (DOT) phx.gbl...
Is it possible to disable the DTS Bulk Insert task through
ActiveX
scripting
if so can anybody direct me to some good documentation?

Many thanks
Simon















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

Default Re: Disabling DTS Bulk insert task - 05-10-2004 , 09:11 AM



BOL is excellent for this

You want the DataFile property

mk:@MSITStore:C:\Program%20Files\Microsoft%20SQL%2 0Server\80\Tools\Books\dts
prog.chm::/dtsptasks_3b5g.htm

--
--

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote

Quote:
Allan,

Thanks for that code it works, can you direct me to a good source that
shows me what methods i can use with Bulk insert Task, as i want to also
be
able to specify the filename at runtime.

again many thanks

Simon

but using your
"Allan Mitchell" <allan (AT) no-spam (DOT) sqldts.com> wrote in message
news:OgoCbMoNEHA.3492 (AT) TK2MSFTNGP10 (DOT) phx.gbl...
OK

Here is code that I have just built and used successfully.


Function Main()

dim stp

set stp = DTSGlobalVariables.Parent.Steps("DTSStep_DTSBulkIn sertTask_1")

stp.DisableStep = True



Main = DTSTaskExecResult_Success
End Function


--

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

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote in message
news:u1fAd5nNEHA.628 (AT) TK2MSFTNGP11 (DOT) phx.gbl...
Error Code: 0
Error Source= Microsoft VBScript runtime error
Error Description: Object doesn't support this propery or
method:'BulkIns.DisableStep

this is the error message i get if i use the disablesetp method with
the
bulk insert task.

Simon

"Allan Mitchell" <allan (AT) no-spam (DOT) sqldts.com> wrote in message
news:eKlnW6mNEHA.1608 (AT) TK2MSFTNGP12 (DOT) phx.gbl...
There is no such method as DisableTask.

Check my code again.

I use DisableStep which is a method of the Step object.



--

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

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote in message
news:e5zD9ymNEHA.2976 (AT) TK2MSFTNGP10 (DOT) phx.gbl...
Allan,

have change the code in your example as suggested in step 4

SNIPPET
if ShouldILoop = True then
set BulkIns =
pkg.Tasks("DTSTask_DTSBulkInsertTask_1").CustomTas k
BulkIns.DisableTask = False
BulkIns.DataFile = DTSGlobalVariables("gv_FileFullName").Value
else
....
....
End if

END SNIPPET

but when i run the package, i get the following error message

Error Code: 0
Error Source= Microsoft VBScript runtime error
Error Description: Object doesn't support this propery or method:
'BulkIns.DisableTask'

Error on Line 21

Many Thanks for your help

Simon Whale

"Allan Mitchell" <allan (AT) no-spam (DOT) sqldts.com> wrote in message
news:us9qJrDNEHA.3572 (AT) tk2msftngp13 (DOT) phx.gbl...
Look for the Step object and disable.

Have a look here and I do it in my package (Not the Bulk Insert
task
but
the
theory is the same) points 2 & 4

Looping, Importing and Archiving
(http://www.sqldts.com/Default.aspx?246)

--
--

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


"Simon Whale" <simon (AT) noway (DOT) ukdatait.com> wrote in message
news:eOrIQUDNEHA.2976 (AT) TK2MSFTNGP10 (DOT) phx.gbl...
Is it possible to disable the DTS Bulk Insert task through
ActiveX
scripting
if so can anybody direct me to some good documentation?

Many thanks
Simon

















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.