int KISAMGetString(KHAND handle, char *lpRecbuf, char *lpName, int nOcc, char *lpBuf, int nBuflen)
Parameter | Type | Purpose |
handle | KHAND | handle of table to which the row buffer applies |
lpRecbuf | char * | record buffer containing a database row |
lpName | char * | name of the column as defined in the data dictionary for the table. |
nOcc | int | occurrence number for array columns counted from 1. Use zero if not applicable. |
lpBuf | char * | location to receive the string |
nBuflen | int | size of the lpBuf buffer. This should be big enough to hold all the string and a terminating null character. If shorter then the string will be truncated. |
This returns the value of column as a string copying it into the buffer lpBuf. Any trailing blanks are removed and the string will be null terminated. The buffer must be big enough to hold the value and the terminating null character or an error KE_BADBUFFER (28) will be returned.
This function will return a value for all the KISAM data types and not just CHAR data. Dates are converted to a CCYY-MM-DD string and numbers are represented as ascii.