home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 11 Util
/
11-Util.zip
/
TP1.ZIP
/
SQLFRONT.H
< prev
next >
Wrap
C/C++ Source or Header
|
1989-04-24
|
3KB
|
172 lines
/*
** Copyright (C) 1985-1988 Sybase, Inc.
** Copyright (C) 1988 Microsoft Corporation
*/
/*
** SQLfront.h: 34.1 5/10/88
**
** FRONT.H
**
** Your generic useful definitions file.
**
** Requires:
** nothing
**
** Sybase DB-LIBRARY Version 2.0
** Confidential Property of Sybase, Inc.
** (c) Copyright Sybase, Inc. 1985, 1986
** All rights reserved
*/
/*
** Version
*/
#define BSD42 0
#define VMS 0
#define VOS 0
#define LINT_ARGS 1
/*
** Machine
*/
#define SUN 0
#define PYRAMID 0
#define VAX 0
/* M_i86 1 */
/* M_i286 1 */
/* M_i386 1 */
/*
** Languages
*/
#define SQL_C 0
#define SQL_FORTRAN 1
#define SQL_COBOL 2
/*
** Return types
*/
typedef int RETCODE; /* SUCCEED or FAIL */
typedef int STATUS; /* OK or condition code */
/*
** Defines
*/
#if defined(BSD42) || defined(VOS) || defined(DBMSDOS) || defined(DBMSOS2) || defined(DBMSWIN)
#define STDEXIT 0
#define ERREXIT -1
#endif
#if VMS
#define STDEXIT 1
#define ERREXIT
#endif /* VMS */
#ifndef NULL
#define NULL 0
#endif /* NULL */
#ifndef FALSE
#define FALSE 0
#endif
#ifndef TRUE
#define TRUE 1
#endif
#define SUCCEED 1
#define FAIL 0
#define OK 0
/*
** SYBASE environment variable
*/
#define ENV_SYBASE "SYBASE"
/*
** Defines for the "answer" in interrupt pop-ups
*/
#define INT_EXIT 0
#define INT_CONTINUE 1
#define INT_CANCEL 2
/* force structures to be word alligned */
#pragma pack(2)
/* DataServer variable typedefs */
typedef unsigned char DBTINYINT; /* DataServer 1 byte integer */
typedef short DBSMALLINT; /* DataServer 2 byte integer */
typedef long DBINT; /* DataServer 4 byte integer */
typedef char DBCHAR; /* DataServer char type */
typedef char DBTEXT; /* DataServer text type */
typedef unsigned char DBBINARY; /* DataServer binary type */
typedef unsigned char DBARRAY; /* DataServer array type */
typedef unsigned char DBBIT; /* DataServer bit type */
typedef struct datetime /* DataServer datetime type */
{
long dtdays; /* number of days since 1/1/1900 */
unsigned long dttime; /* number 300th second since mid */
} DBDATETIME;
typedef struct money /* DataServer money type */
{
long mnyhigh;
unsigned long mnylow;
} DBMONEY;
typedef double DBFLT8; /* DataServer float type */
/*
** Typedefs
*/
typedef unsigned char BYTE;
typedef unsigned char DBBOOL; /* Less likely to collide than "BOOL". */
#if !defined(DBMSDOS) && !defined(DBMSOS2) && !defined(DBMSWIN)
typedef unsigned char BOOL; /* So older programs won't break yet.*/
#endif
#if defined (DBMSOS2)
typedef BYTE far *POINTER;
#else
typedef BYTE *POINTER;
#endif
/*
** Pointers to functions returning ...
*/
#if defined (DBMSOS2)
typedef int (far *INTFUNCPTR)();
typedef DBBOOL (far *BOOLFUNCPTR)();
#else
typedef int (*INTFUNCPTR)();
typedef DBBOOL (*BOOLFUNCPTR)();
#endif
/*
** REGION - Rectangular Area.
*/
typedef struct region
{
short rgx; /* Starting (upper left) coordinates */
short rgy;
short rgwidth; /* Width (horizontal extent) */
short rgheight; /* Height (vertical extent) */
} REGION;
/* set packing to default */
#pragma pack()
/* max length of sql statement buffer */
#define SQLMAXLEN 3072
/* max len of a file pathname */
#define FILENAME_LEN 255