Creating DTS Custom Transformations

Using DTS programmers can create custom transformation objects that can be integrated into third-party products. To create a custom transformation, you must create a COM object that supports the IDTSDataPumpTransform interface. Optionally, the COM can also support other interfaces, such as the ISupportErrorInfo interface for error handling. Programmers create custom transformations for the Data Pump using C or C++ by referencing Dtspump.h.

After inheriting from IDTSDataPumpTransform, a custom transformation calls these IDTSDataPumpTransform interface methods:

IDTSDataPumpTransform::AddVariable allows an application variable to be passed through to the transformation process. The data pump always calls this method to add the DTSErrorRecords object immediately after a call to IDTSDataPumpTransform::Initialize and before a call to IDTSDataPumpTransform::ValidateSchema. This allows ValidateSchema to add errors to the OLE DB error records collection for the thread if columns are found to be in error.

IDTSDataPumpTransform::Execute returns SUCCEED except when a fatal failure occurs. When Execute returns FAILED, the data pump terminates.


Note Custom transformations can significantly effect the execution speed of a DTS package. Use them carefully when building a package. An example program is available in DTS Custom Task.


See Also
Data Pump Interfaces Enhancing DTS Performance
DTS Custom Task IDTSDataPumpTransform

  


(c) 1988-98 Microsoft Corporation. All Rights Reserved.