Develop a user-defined routine

A C user-defined routine (UDR) is a UDR that is written in the C language and uses the server-side implementation of the DataBlade API to communicate with the database server. C UDRs (functions and procedures) are implemented as C-language functions. DataBlade modules often include C UDRs that are made available for use by registering them in the database.

Tip: The terms C UDR and UDR are used interchangeably in this publication.
The development process for a C UDR follows these steps:
  1. Design the use and development process for the UDR
  2. Code a C routine that uses the DataBlade API functions to interact with the database server
  3. Compile and link the C routine to create a shared-object file
  4. Register the C routine with the CREATE FUNCTION or CREATE PROCEDURE statement
  5. Execute the UDR
  6. Use tracing and the debugging features to work out any problems in the UDR
  7. Change any characteristics of the UDR that are required during its lifetime
  8. Optimize performance of the UDR

This section describes each of these steps in the development of a C UDR. For general information about the development steps of a UDR, see the IBM® Informix® User-Defined Routines and Data Types Developer's Guide.

This section covers topics specific to the development of a C UDR. This material does not apply to the creation of client LIBMI applications with the client-side implementation of the DataBlade API.


Copyright© 2018 HCL Technologies Limited