INFORMIX
Informix-ESQL/C Programmer's Manual
Chapter 13: Using Informix Libraries
Home Contents Index Master Index New Book

Using ESQL/C Thread-Safe Decimal Functions

The dececvt() and decfcvt() functions of the ESQL/C library return a character string that can be overwritten if two threads simultaneously call these functions. For this reason, use the following thread-safe versions of these two functions.
Function Name Description

ifx_dececvt()

Thread-safe version of the dececvt() ESQL/C function

ifx_decfcvt()

Thread-safe version of the decfcvt() ESQL/C function

Both of these functions convert a decimal value to an ASCII string and return it in the user-defined buffer.

When you compile your ESQL/C program with the -thread command-line option of the esql command, esql automatically links these functions to your program. These functions are described on the following pages.

ifx_dececvt(), ifx_decfcvt()

The ifx_dececvt() and ifx_decfcvt() functions are the thread-safe versions of the dececvt() and decfcvt() ESQL/C library functions.

Syntax

Usage

The ifx_dececvt() function is the thread-safe version of the dececvt() function. The ifx_decfcvt() function is the thread-safe version of decfcvt() function. Each function returns a character string that cannot be overwritten when two threads simultaneously call the function. For information on how to use dececvt() and decfcvt(), see page 4-28.

Return Codes

0

The conversion was successful.

<0

The conversion was not successful.

-1273

Output buffer is null or too small to hold the result.




Informix-ESQL/C Programmer's Manual, version 9.1
Copyright © 1998, Informix Software, Inc. All rights reserved.