Using PowerCenter to replace characters in a string with a single character, multiple characters, or no character by using an External Procedure transformation that calls the stringfunction.dll. (Please note that in PowerCenter there is the Replacechr and Replacestr function that does exactly what the stringfunction.dll does. The goal of this mapping template is simply to illustrate the ability to extend PowerCenter functionality with external programs such as stringfunction.dll).
External Procedure transformations operate in conjunction with procedures you create outside of the Designer interface to extend PowerCenter functionality. Although the standard transformations provide you with a wide range of options, there are occasions when you might want to extend the functionality provided with PowerCenter and PowerMart. For example, the range of standard transformations, such as Expression and Filter transformations, may not provide the exact functionality you need. If you are an experienced programmer, you may want to develop complex functions within a dynamic link library (DLL) or UNIX shared a library, instead of creating the necessary Expression transformations in a mapping.
There are many uses of the External Procedure transformation, depending on the client's need. If Informatica cannot provide the logic, and certain code can, Informatica can still support this by using the External Procedure transformation. This mapping template illustrates just one method of using a PowerCenter External Procedure transformation. The mapping replaces characters in a string with a single character, multiple characters, or no character by using an External Procedure transformation that calls the stringfunction.dll.
An external procedure exists separately from the Integration Service. It consists of C, C++, or Visual Basic code written by a user to define a transformation. This code is compiled and linked into a DLL or shared library, which is loaded by the Integration Service at runtime. An external procedure is "bound" to an External Procedure transformation. It allows an external procedure to be referenced in a mapping. By adding an instance of an External Procedure transformation to a mapping, you call the external procedure bound to that transformation. This mapping template uses the stringfunction.dll. To use the dll, place it in the ExtProc directory, under the Informatica server installation directory. Then the register the dll at the command prompt, ExampleD:\Program Files\Informatica\PowerCenter Server\EXTPROC>regsvr32 stringfunctions.dll. A window prompt acknowledges that the dll is registered. In Designer, under the Transformation Developer tab, import the external procedure called Replace_Single_Char.On the Properties tab on this transformation, you must
What can we do to improve this information (2000 or fewer characters)