/***********************************************************************/ /* Definitions to be used in function prototypes. */ /* The SQL_API is to be used only for those functions exported for */ /* driver manager use. */ /* The EXPFUNC is to be used only for those functions exported but */ /* used internally, ie, dialog procs. */ /* The INTFUNC is to be used for all other functions. */ /***********************************************************************/ #ifdefined(WIN32) #define INTFUNC __stdcall #define EXPFUNC __stdcall #else #define INTFUNC FAR PASCAL #define EXPFUNC __export CALLBACK #endif
/***********************************************************************/ /* Additional values used by PlugDB for ODBC. */ /***********************************************************************/ #define RES_TYPE_PREPARE 1/* Result from SQLPrepare */ #define RES_TYPE_CATALOG 2/* Result from catalog funcs */ #define MAXPATHLEN _MAX_PATH /* Max path length */ #define MAXKEYLEN 16/* Max keyword length */ #define MAXDESC 256/* Max description length */ #define MAXDSNAME 33/* Max data source name length */ #define MAXCRNAME 18/* Max stmt cursor name length */ #define DEFMAXRES 6300/* Default MaxRes value */ #define NAM_LEN 128/* Length of col and tab names */
// This definition MUST be identical to the value in plgdbsem.h #define XMOD_PREPARE 1
/***********************************************************************/ /* ODBC.INI keywords (use extern definition in SETUP.C) */ /***********************************************************************/ externcharconst *EMPTYSTR; /* Empty String */ externcharconst *OPTIONON; externcharconst *OPTIONOFF; externcharconst *INI_SDEFAULT; /* Default data source name */ externcharconst *ODBC_INI; /* ODBC initialization file */ externcharconst *INI_KDEFL; /* Is SQL to use by default? */ externcharconst *INI_KLANG; /* Application language */ externcharconst *INI_KDATA; /* Data description file */ externcharconst *INI_KSVR; /* PLG Server */
/************************************************************************/ /* Attribute key indexes (into an array of Attr structs, see below) */ /************************************************************************/ #define KEY_DSN 0 #define KEY_DEFL 1 #define KEY_LANG 2 #define KEY_DATA 3 #define KEY_SERVER 4 #define LAST_KEY 5/* Number of keys in TAG's */ #define KEY_DESC 5 #define KEY_TRANSNAME 6 #define KEY_TRANSOPTION 7 #define KEY_TRANSDLL 8 #define NUMOFKEYS 9/* Number of keys supported */
#define FOURYEARS 126230400// Four years in seconds (1 leap)
/***********************************************************************/ /* This is used when an "out of memory" error happens, because this */ /* error recording system allocates memory when it logs an error, */ /* and it would be bad if it tried to allocate memory when it got an */ /* out of memory error. */ /***********************************************************************/ typedefenum _ERRSTAT {
errstatOK,
errstatNO_MEMORY,
} ERRSTAT;
typedefstruct _parscons { /* Parse constants */ int Slen; /* String length */ int Ntag; /* Number of entries in tags */ int Nlook; /* Number of entries in lookup */ char Sep; /* Separator */
} PARC, *PPARC;
/***********************************************************************/ /* This is info about a single error. */ /***********************************************************************/ typedefstruct _ERRBLK *PERRBLK;
typedefstruct _ERRBLK {
PERRBLK Next; /* Next block in linked list of error blocks */
DWORD Native_Error; /* Native error */
DWORD Stderr; /* SQLC error code */
PSZ Message; /* Points to text of message */
} ERRBLK;
/***********************************************************************/ /* This is a header block, it records information about a list of */ /* errors (ERRBLOCK's). */ /***********************************************************************/ typedefstruct _ERRINFO {
PERRBLK First; /* First block in linked list of error blocks. */
PERRBLK Last; /* Last block in above list. */
ERRSTAT Errstat; /* Status for special condition out of memory */
} ERRINFO, *PERRINFO;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.