odbx_column_name(3)

NAME
odbx_column_name - Get the name of a column in the current result set

SYNOPSIS
\FC#include <opendbx/api.h>\F[]

\FCchar* odbx_column_name\F[]
\FC(odbx_result_t* result, unsigned long pos);\F[]

DESCRIPTION
\FCodbx_column_name\F[]() gets the name of the column specified by pos in the current result set returned by \FCodbx_result\F[](). The column names will not change within the result set with the exception described for MySQL in \FCodbx_column_count\F[]() when the first result set wasn't retrieved completely before \FCodbx_result\F[]() was called again.

The \FCresult\F[] parameter required by this function must be a valid result set returned by \FCodbx_result\F[]() and must not have been feed to \FCodbx_result_finish\F[]() before.

Valid column indices for the requested column provided via \FCpos\F[] start with zero and end with the value returned by \FCodbx_column_count\F[]() minus one.

RETURN VALUE
The return value of \FCodbx_column_name\F[]() is a pointer to a zero terminated string which consists of the name of the requested column. This pointer is allocated by the database client library and must not be freed by the application. The content of the string may be overwritten by the next call to \FCodbx_column_name\F[]()

ERRORS
Errors can occur if the given \FCresult\F[] parameter is NULL or invalid or if the value of \FCpos\F[] is out of range, i.e. more than \FCodbx_column_count\F[]() minus one.

SEE ALSO
\FCodbx_column_count\F[](), \FCodbx_column_type\F[](), \FCodbx_result\F[]()