Oracle Call Interface Programmer's Guide Release 9.0.1 Part Number A89857-01 |
|
OCI Datatype Mapping and Manipulation Functions, 30 of 135
Converts a date type to a character string.
sword OCIDateToText ( OCIError *err, CONST OCIDate *date, CONSTOraText OraText *fmt, ub1 fmt_length, CONST OraText *lang_name, ub4 lang_length, ub4 *buf_size, OraText *buf );
The OCI error handle. If there is an error, it is recorded in err
and this function returns OCI_ERROR. Obtain diagnostic information by calling OCIErrorGet()
.
Oracle date to be converted.
Conversion format, if NULL, (text *) 0
, then the date is converted to a character string in the default date format, DD-MON-YY.
Length of the fmt
parameter.
Specifies the language in which names and abbreviations of months and days are returned; default language of session is used if lang_name
is null ((text *) 0
).
Length of the lang_name
parameter.
Buffer into which the converted string is placed.
Converts the given date to a string according to the specified format. The converted null-terminated date string is stored in buf
.
Refer to the TO_DATE
conversion function described in Chapter 3 of the Oracle8i SQL Reference for a description of format and multilingual arguments.
This function returns an error if the buffer is too small, or if the function is passed an invalid format or unknown language. Overflow also causes an error. For example, converting a value of 10 into format '9' causes an error.
|
Copyright © 1996-2001, Oracle Corporation. All Rights Reserved. |
|