MemCom Reference Manual > MemCom C API Manual Pages > Array Table Functions > mcATinqColAtt

Name

mcATinqColAtt — Get column attributes of array table

Synopsis

#include <memcom.h>

int mcATinqColAtt(int handle, const char* name, mcOff col,
                  mcATColAttributes* att);

Description

mcATinqColAtt returns the attributes of a column col of the array table name residing on the database handle in a buffer att. If completed successfully, the function returns 1. If the column does not exist 0 is returned. A negative value indicates an error.

Parameters

handle

Database handle (input).

name

Name of a new dataset defining the array table (input).

col

Column number (not name) of array table for which attributes are required (input). col must be greater or equal to 1 and less or equal to the number of defined columns.

att

Attribute buffer (output). The attribute buffer is defined as

typedef struct {
    char    name[MC_AT_COL_NAME_SIZE];  /* Column name */
    char    type[4];                    /* Cell type */
    mcSize  num;                        /* Number of elements */
} mcATColAttributes;

If the column size is variable num contains 0, else num is strictly positive and contains the number of element of the column.