PRB: DTS Execute Package Task May Fail to Execute Child Package (299354)



The information in this article applies to:

  • Microsoft SQL Server 2000 (all editions)

This article was previously published under Q299354

SYMPTOMS

The Data Transformation Services (DTS) Execute Package Task may fail to execute a child package when the following occurs:
  • A package is created that executes a child package.
  • The parent package is saved as a Microsoft Visual Basic file.
  • The child package is saved as a Visual Basic file.
  • The parent package is deleted.
  • The child package is deleted.
  • The parent and child packages are again re-created within SQL Server by using the Visual Basic files.
The following error messages occurs:
The Specified DTS Package ('Name = '<Child Package Name Here>'; ID.VersionID = { },{[not specified]}') does not exist.

CAUSE

The Child PackageId is stored in the the Parent Visual Basic file. The Parent and the Child package are re-created in SQL Server, and both are given new package ids. When the Parent package is run, it is not able to locate the Child package.

WORKAROUND

To work around this problem, comment out the PackageID property in the Parent Visual Basic file before you create the package in SQL Server. The Parent package is created without reference to the Child package id. The Parent package then locates the Child package by name and executes the Child package.

MORE INFORMATION

Here is an example of the Parent package code. Note that the PackageID is commented out:
oCustomTask1.Name = "DTSTask_DTSExecutePackageTask_1"
oCustomTask1.Description = "<Parent Package Name Here>"
oCustomTask1.ServerName = "<Server Name Here>"
oCustomTask1.UseTrustedConnection = True
oCustomTask1.UseRepository = False
oCustomTask1.PackageName = "<Child Package Name Here>"
'oCustomTask1.PackageID = "{999652F2-3125-45DC-A8A2-8422B183CF5D}"
				

Modification Type:MajorLast Reviewed:10/16/2003
Keywords:kbprb KB299354