'\" -*- coding: us-ascii -*- .if \n(.g .ds T< \\FC .if \n(.g .ds T> \\F[\n[.fam]] .de URL \\$2 \(la\\$1\(ra\\$3 .. .if \n(.g .mso www.tmac .TH odbx_column_type 3 "5 September 2014" "" OpenDBX .SH NAME odbx_column_type \- Returns the SQL data type of a column in the current result set .SH SYNOPSIS 'nh .nf \*(T<#include \*(T> .fi .sp 1 .PP .fi .ad l \*(T \kx .if (\nx>(\n(.l/2)) .nr x (\n(.l/5) 'in \n(.iu+\nxu \*(T<(odbx_result_t* \fIresult\fR, unsigned long \fIpos\fR);\*(T> 'in \n(.iu-\nxu .ad b 'hy .SH DESCRIPTION \*(T<\fBodbx_column_type\fR\*(T>() returns the data type of the requested column within the current result set returned by \*(T<\fBodbx_result\fR\*(T>(). The column type applies to all fields at the same position of the rows fetched via \*(T<\fBodbx_row_fetch\fR\*(T>(). The definitions are based on the SQL2003 standard and the data types of the database server have to comply to the specification of the standard. Data types provided by database implementations which are not covered by the SQL2003 standard are subsumed as \*(T. .PP The \*(T parameter required by this function must be a valid result set returned by \*(T<\fBodbx_result\fR\*(T>() and must not has been feed to \*(T<\fBodbx_result_finish\fR\*(T>() before. .PP Valid column indices for the requested column provided via \*(T start with zero and end with the value returned by \*(T<\fBodbx_column_count\fR\*(T>() minus one. .SH "RETURN VALUE" If a values less than zero is returned, an error occurred. Possible error codes are listed in the error section and the application can retrieve a textual message of the error by calling \*(T<\fBodbx_error\fR\*(T>(). .PP A positive return value including zero indicates one of the SQL2003 compliant data types listed below. Before release 1.1.5 of the OpenDBX library, types were defined as ODBX_* instead of ODBX_TYPE_*. The old definitions are kept for backward compatibility but shouldn't be used any more. They will be removed at some point in the future. .PP Exact numeric values: .TP 0.2i \(bu \*(T: True/false values .TP 0.2i \(bu \*(T: Signed 16 bit integer .TP 0.2i \(bu \*(T: Signed 32 bit integer .TP 0.2i \(bu \*(T: Signed 64 bit integer .TP 0.2i \(bu \*(T: Exact signed numeric values with user defined precision .PP Approximate numeric values: .TP 0.2i \(bu \*(T: Approximate numeric values (signed) with 32 bit precision .TP 0.2i \(bu \*(T: Approximate numeric values (signed) with 64 bit precision .TP 0.2i \(bu \*(T: Approximate numeric values (signed) with user defined precision .PP String values: .TP 0.2i \(bu \*(T: Fixed number of characters .TP 0.2i \(bu \*(T: Fixed number of characters using a national character set .TP 0.2i \(bu \*(T: Variable number of characters .TP 0.2i \(bu \*(T: Variable number of characters using a national character set .PP Large objects: .TP 0.2i \(bu \*(T: Large text object .TP 0.2i \(bu \*(T: Large text object using a national character set .TP 0.2i \(bu \*(T: XML tree in text format .TP 0.2i \(bu \*(T: Large binary object .PP Date and time values: .TP 0.2i \(bu \*(T: Time including hours, minutes and seconds .TP 0.2i \(bu \*(T: Time with timezone information .TP 0.2i \(bu \*(T: Date and time .TP 0.2i \(bu \*(T: Date and time with timezone information .TP 0.2i \(bu \*(T: Date including year, month and day .TP 0.2i \(bu \*(T: Date interval .PP Arrays and sets: .TP 0.2i \(bu \*(T: Array of values .TP 0.2i \(bu \*(T: Associative arrays .PP External links: .TP 0.2i \(bu \*(T: URI locators like URL links .PP Vendor specific: .TP 0.2i \(bu \*(T: Vendor specific data type without representation in SQL2003 .SH ERRORS .TP -\*(T The native database library returned an error .TP -\*(T Either the \*(T parameter is NULL respectively is invalid or the value of \*(T is out of range .SH "SEE ALSO" \*(T<\fBodbx_column_count\fR\*(T>(), \*(T<\fBodbx_column_name\fR\*(T>(), \*(T<\fBodbx_field_value\fR\*(T>(), \*(T<\fBodbx_result\fR\*(T>()