#ifndef SQLCA_INCL

#define SQLCA_INCL

#include "sqport.h"

struct sqlca_s
    {
    long sqlcode;
    char sqlerrm[72]; /* error message parameters */
    char sqlerrp[8];
    long sqlerrd[6];
		    /* 0 - estimated number of rows returned */
		    /* 1 - serial value after insert or  ISAM error code */
		    /* 2 - number of rows processed */
		    /* 3 - estimated cost */
		    /* 4 - offset of the error into the SQL statement */
		    /* 5 - rowid after insert  */
    struct sqlcaw_s
	{
	char sqlwarn0; /* = W if any of sqlwarn[1-7] = W */
	char sqlwarn1; /* = W if any truncation occurred or
				database has transactions */
	char sqlwarn2; /* = W if a null value returned or
				ANSI database */
	char sqlwarn3; /* = W if no. in select list != no. in into list or
				turbo backend */
	char sqlwarn4; /* = W if no where clause on prepared update, delete or
				incompatible float format */
	char sqlwarn5; /* = W if non-ANSI statement */
	char sqlwarn6; /* reserved */
	char sqlwarn7; /* reserved */
	} sqlwarn;
    };


#ifdef VMS
noshare
#endif /* VMS */

M_TLS extern struct sqlca_s sqlca;
M_TLS extern long SQLCODE;

#define SQLNOTFOUND 100

#endif /* SQLCA_INCL */
