home *** CD-ROM | disk | FTP | other *** search
- Global Const CS_TS_SIZE = 8
- Global Const CS_TP_SIZE = 16
- Global Const CS_OBJ_NAME = ((CS_MAX_NAME * 3) + 4)
- ' Define all the library versions currently supported.
-
- Global Const CS_VERSION_100 = 112
-
- ' Action flags used.
-
- Global Const CS_GET = 33
- Global Const CS_SET = 34
- Global Const CS_CLEAR = 35
- Global Const CS_INIT = 36
- Global Const CS_STATUS = 37
- Global Const CS_MSGLIMIT = 38
- Global Const CS_SEND = 39
-
- ' Bind indicator values. These are preferred when passing data into
- ' Client Library or Server Library, since they add the appropriate cast.
-
- Global Const CS_GOODDATA = 0
- Global Const CS_NULLDATA = (-1)
-
-
- ' Define ct_debug() operations.
-
- Global Const CS_SET_FLAG = 1700
- Global Const CS_CLEAR_FLAG = 1701
- Global Const CS_SET_DBG_FILE = 1702
- Global Const CS_SET_PROTOCOL_FILE = 1703
-
-
- ' Define ct_debug() types of trace information.
-
- Global Const CS_DBG_ALL = 1
- Global Const CS_DBG_ASYNC = 2
- Global Const CS_DBG_ERROR = 4
- Global Const CS_DBG_MEM = 8
- Global Const CS_DBG_PROTOCOL = 16
- Global Const CS_DBG_PROTOCOL_STATES = 32
- Global Const CS_DBG_API_STATES = 64
- Global Const CS_DBG_DIAG = 128
- Global Const CS_DBG_NETWORK = 256
- Global Const CS_DBG_API_LOGCALL = 512
-
-
- 'Cancel types.
-
- Global Const CS_CANCEL_CURRENT = 6000
- Global Const CS_CANCEL_ALL = 6001
- Global Const CS_CANCEL_ATTN = 6002
-
-
- ' Cursor fetch options. Currently these are not supported within Open
- ' Client and Open Server.
-
- Global Const CS_FIRST = 3000
- Global Const CS_NEXT = 3001
- Global Const CS_PREV = 3002
- Global Const CS_LAST = 3003
- Global Const CS_ABSOLUTE = 3004
- Global Const CS_RELATIVE = 3005
-
-
- ' Op codes used in cs_calc().
-
- Global Const CS_ADD = 1
- Global Const CS_SUB = 2
- Global Const CS_MULT = 3
- Global Const CS_DIV = 4
- Global Const CS_ZERO = 5
-
-
- ' The cs_dt_info() types.
-
- Global Const CS_MONTH = 7340
- Global Const CS_SHORTMONTH = 7341
- Global Const CS_DAYNAME = 7342
- Global Const CS_DATEORDER = 7343
- Global Const CS_12HOUR = 7344
- Global Const CS_DT_CONVFMT = 7345
-
-
- ' The cs_strcmp() options.
-
- Global Const CS_COMPARE = 7440
- Global Const CS_SORT = 7441
-
-
- ' Callback types.
-
- Global Const CS_COMPLETION_CB = 1
- Global Const CS_SERVERMSG_CB = 2
- Global Const CS_CLIENTMSG_CB = 3
- Global Const CS_NOTIF_CB = 4
- Global Const CS_ENCRYPT_CB = 5
- Global Const CS_CHALLENGE_CB = 6
-
- ' To install a signal callback, the type needs to calculated as an
- ' offset of the operating-system-specific signal number and the
- ' following define. For example, to install a callback handler for a
- ' SIGALRM signal, pass (CS_SIGNAL_CB + SIGALRM) to the ct_callback()
- ' routine.
-
- Global Const CS_SIGNAL_CB = 100
-
-
- ' Exit and close flags.
-
- Global Const CS_FORCE_EXIT = 300
- Global Const CS_FORCE_CLOSE = 301
-
-
- ' ct_diag() and cs_diag() type flags.
-
- Global Const CS_CLIENTMSG_TYPE = 4700
- Global Const CS_SERVERMSG_TYPE = 4701
- Global Const CS_ALLMSG_TYPE = 4702
- Global Const SQLCA_TYPE = 4703
- Global Const SQLCODE_TYPE = 4704
- Global Const SQLSTATE_TYPE = 4705
-
-
- ' Compute info types.
-
- Global Const CS_COMP_OP = 5350
- Global Const CS_COMP_ID = 5351
- Global Const CS_COMP_COLID = 5352
- Global Const CS_COMP_BYLIST = 5353
- Global Const CS_BYLIST_LEN = 5354
-
-
- ' Compute info operators.
-
- Global Const CS_OP_SUM = 5370
- Global Const CS_OP_AVG = 5371
- Global Const CS_OP_COUNT = 5372
- Global Const CS_OP_MIN = 5373
- Global Const CS_OP_MAX = 5374
-
-
- ' Browse types.
-
- Global Const CS_ISBROWSE = 9000
- Global Const CS_TABNUM = 9001
- Global Const CS_TABNAME = 9002
-
-
- ' Result types from ct_results().
-
- Global Const CS_ROW_RESULT = 4040
- Global Const CS_CURSOR_RESULT = 4041
- Global Const CS_PARAM_RESULT = 4042
- Global Const CS_STATUS_RESULT = 4043
- Global Const CS_MSG_RESULT = 4044
- Global Const CS_COMPUTE_RESULT = 4045
- Global Const CS_CMD_DONE = 4046
- Global Const CS_CMD_SUCCEED = 4047
- Global Const CS_CMD_FAIL = 4048
- Global Const CS_ROWFMT_RESULT = 4049
- Global Const CS_COMPUTEFMT_RESULT = 4050
- Global Const CS_DESCRIBE_RESULT = 4051
-
-
- ' Flags for getting result info using ct_res_info().
-
- Global Const CS_ROW_COUNT = 800
- Global Const CS_CMD_NUMBER = 801
- Global Const CS_NUM_COMPUTES = 802
- Global Const CS_NUMDATA = 803
- Global Const CS_ORDERBY_COLS = 804
- Global Const CS_NUMORDERCOLS = 805
- Global Const CS_MSGTYPE = 806
- Global Const CS_BROWSE_INFO = 807
- Global Const CS_TRANS_STATE = 808
-
-
- ' Possible values for CS_TRANS_STATE.
-
- Global Const CS_TRAN_UNDEFINED = 0
- Global Const CS_TRAN_IN_PROGRESS = 1
- Global Const CS_TRAN_COMPLETED = 2
- Global Const CS_TRAN_FAIL = 3
- Global Const CS_TRAN_STMT_FAIL = 4
-
-
- ' Define the invalid count that the application gets when
- ' ct_res_info() is called at the wrong time.
-
- Global Const CS_NO_COUNT = -1
-
-
- '
- ' Commands in Open Client/Server APIs.
- '
-
-
-
- ' ct_command() command types.
-
- Global Const CS_LANG_CMD = 148
- Global Const CS_RPC_CMD = 149
- Global Const CS_MSG_CMD = 150
- Global Const CS_SEND_DATA_CMD = 151
- Global Const CS_PACKAGE_CMD = 152
- Global Const CS_SEND_BULK_CMD = 153
-
-
- ' ct_cursor() command types.
-
- Global Const CS_CURSOR_DECLARE = 700
- Global Const CS_CURSOR_OPEN = 701
- Global Const CS_CURSOR_ROWS = 703
- Global Const CS_CURSOR_UPDATE = 704
- Global Const CS_CURSOR_DELETE = 705
- Global Const CS_CURSOR_CLOSE = 706
- Global Const CS_CURSOR_DEALLOC = 707
- Global Const CS_CURSOR_OPTION = 725
-
-
- ' Open Server-specific cursor command types.
-
- Global Const CS_CURSOR_FETCH = 708
- Global Const CS_CURSOR_INFO = 709
-
-
- ' ct_dyndesc() command types.
-
- Global Const CS_ALLOC = 710
- Global Const CS_DEALLOC = 711
- Global Const CS_USE_DESC = 712
- Global Const CS_GETCNT = 713
- Global Const CS_SETCNT = 714
- Global Const CS_GETATTR = 715
- Global Const CS_SETATTR = 716
-
-
- ' ct_dynamic() command types.
-
- Global Const CS_PREPARE = 717
- Global Const CS_EXECUTE = 718
- Global Const CS_EXEC_IMMEDIATE = 719
- Global Const CS_DESCRIBE_INPUT = 720
- Global Const CS_DESCRIBE_OUTPUT = 721
- Global Const CS_DYN_CURSOR_DECLARE = 722
-
-
- ' Open Server-specific dynamic command types.
-
- Global Const CS_PROCNAME = 723
- Global Const CS_ACK = 724
-
-
-
- ' Command options
-
- Global Const CS_RECOMPILE = 188
- Global Const CS_NO_RECOMPILE = 189
- Global Const CS_BULK_INIT = 190
- Global Const CS_BULK_CONT = 191
- Global Const CS_BULK_DATA = 192
- Global Const CS_COLUMN_DATA = 193
-
-
- ' Cursor options.
-
- Global Const CS_FOR_UPDATE = 1
- Global Const CS_READ_ONLY = 2
- Global Const CS_DYNAMIC = 4 ' Open Server only
-
-
- ' Sybase-defined message ids for CS_MSG_CMDs.
-
- Global Const CS_MSG_GETLABELS = 6
- Global Const CS_MSG_LABELS = 7
- Global Const CS_MSG_TABLENAME = 8
- Global Const CS_PARSE_TREE = 8710
-
-
- ' Minimum and maximum user-defined message id for CS_MSG_CMDs.
-
- Global Const CS_USER_MSGID = 32768
- Global Const CS_USER_MAX_MSGID = 65535
- Global Const CS_MAX_MSG = 1024
- Global Const CS_SQLSTATE_SIZE = 8
-
- ' Defines for sp_regwatch registered procedure
-
- Global Const CS_NOTIFY_ONCE = 2 ' one-time notification request.
- Global Const CS_NOTIFY_ALWAYS = 4 ' permanent notification request.
- Global Const CS_NOTIFY_WAIT = 32 ' blocking notification request.
- Global Const CS_NOTIFY_NOWAIT = 64 ' non-blocking notification request.
-
-
-
- ' Open Client properties.
-
-
- ' Properties that are used in *_props() functions.
-
- Global Const CS_USERNAME = 9100
- Global Const CS_PASSWORD = 9101
- Global Const CS_APPNAME = 9102
- Global Const CS_HOSTNAME = 9103
- Global Const CS_LOGIN_STATUS = 9104
- Global Const CS_TDS_VERSION = 9105
- Global Const CS_CHARSETCNV = 9106
- Global Const CS_PACKETSIZE = 9107
- Global Const CS_USERDATA = 9108
- Global Const CS_COMMBLOCK = 9109
- Global Const CS_NETIO = 9110
- Global Const CS_NOINTERRUPT = 9111
- Global Const CS_TEXTLIMIT = 9112
- Global Const CS_HIDDEN_KEYS = 9113
- Global Const CS_VERSION = 9114
- Global Const CS_IFILE = 9115
- Global Const CS_LOGIN_TIMEOUT = 9116
- Global Const CS_TIMEOUT = 9117
- Global Const CS_MAX_CONNECT = 9118
- Global Const CS_MESSAGE_CB = 9119
- Global Const CS_EXPOSE_FMTS = 9120
- Global Const CS_EXTRA_INF = 9121
- Global Const CS_TRANSACTION_NAME = 9122
- Global Const CS_ANSI_BINDS = 9123
- Global Const CS_BULK_LOGIN = 9124
- Global Const CS_LOC_PROP = 9125
- Global Const CS_CUR_STATUS = 9126
- Global Const CS_CUR_ID = 9127
- Global Const CS_CUR_NAME = 9128
- Global Const CS_CUR_ROWCOUNT = 9129
- Global Const CS_PARENT_HANDLE = 9130
- Global Const CS_EED_CMD = 9131
- Global Const CS_DIAG_TIMEOUT = 9132
- Global Const CS_DISABLE_POLL = 9133
- Global Const CS_NOTIF_CMD = 9134
- Global Const CS_SEC_ENCRYPTION = 9135
- Global Const CS_SEC_CHALLENGE = 9136
- Global Const CS_SEC_NEGOTIATE = 9137
- Global Const CS_MEM_POOL = 9138
- Global Const CS_USER_ALLOC = 9139
- Global Const CS_USER_FREE = 9140
- Global Const CS_ENDPOINT = 9141
- Global Const CS_NO_TRUNCATE = 9142
- Global Const CS_CON_STATUS = 9143
- Global Const CS_VER_STRING = 9144
- Global Const CS_ASYNC_NOTIFS = 9145
- Global Const CS_SERVERNAME = 9146
- Global Const CS_THREAD_RESOURCE = 9147
- Global Const CS_NOAPI_CHK = 9148
- Global Const CS_SEC_APPDEFINED = 9149
-
-
- ' Possible values for the CS_NETIO property.
-
- Global Const CS_SYNC_IO = 8111
- Global Const CS_ASYNC_IO = 8112
- Global Const CS_DEFER_IO = 8113
-
-
- ' Possible bit values for the CS_LOGIN_STATUS property.
-
- Global Const CS_CONSTAT_CONNECTED = 1
- Global Const CS_CONSTAT_DEAD = 2
-
-
-
- ' Possible bit values for the CS_CUR_STATUS property.
-
- Global Const CS_CURSTAT_NONE = 0
- Global Const CS_CURSTAT_DECLARED = 1
- Global Const CS_CURSTAT_OPEN = 2
- Global Const CS_CURSTAT_CLOSED = 4
- Global Const CS_CURSTAT_RDONLY = 8
- Global Const CS_CURSTAT_UPDATABLE = 16
- Global Const CS_CURSTAT_ROWCOUNT = 32
- Global Const CS_CURSTAT_DEALLOC = 64
-
-
- ' Possible values for the CS_TDS_VERSION property.
-
- Global Const CS_TDS_40 = 7360
- Global Const CS_TDS_42 = 7361
- Global Const CS_TDS_46 = 7362
- Global Const CS_TDS_495 = 7363
- Global Const CS_TDS_50 = 7364
-
-
- '
- ' Open Client/Server options.
- '
-
-
-
- ' The following is the list of all valid options:
-
- Global Const CS_OPT_DATEFIRST = 5001 'Set first day of week
- Global Const CS_OPT_TEXTSIZE = 5002 'Text size
- Global Const CS_OPT_STATS_TIME = 5003 'Server time statistics
- Global Const CS_OPT_STATS_IO = 5004 'Server I/O statistics
- Global Const CS_OPT_ROWCOUNT = 5005 'Maximum row count
- Global Const CS_OPT_NATLANG = 5006 'National Language
- Global Const CS_OPT_DATEFORMAT = 5007 'Date format
- Global Const CS_OPT_ISOLATION = 5008 'Transaction isolation
- ' level
- Global Const CS_OPT_AUTHON = 5009 'Set authority level on
- Global Const CS_OPT_CHARSET = 5010 'Character set
- Global Const CS_OPT_SHOWPLAN = 5013 'show execution plan
-
- Global Const CS_OPT_NOEXEC = 5014 'don't execute query
- Global Const CS_OPT_ARITHIGNORE = 5015 'ignore arithmetic
- ' exceptions
- Global Const CS_OPT_TRUNCIGNORE = 5016 'support ANSI null values
- Global Const CS_OPT_ARITHABORT = 5017 'abort on arithmetic
- ' exceptions
- Global Const CS_OPT_PARSEONLY = 5018 'parse only, return error
- ' msgs
- Global Const CS_OPT_GETDATA = 5020 'return trigger data
- Global Const CS_OPT_NOCOUNT = 5021 'don't print done count
- Global Const CS_OPT_FORCEPLAN = 5023 'force variable substitute
- ' order
- Global Const CS_OPT_FORMATONLY = 5024 'send format w/o row
- Global Const CS_OPT_CHAINXACTS = 5025 'chained transaction mode
- Global Const CS_OPT_CURCLOSEONXACT = 5026 'close cursor on end trans
- Global Const CS_OPT_FIPSFLAG = 5027 'FIPS flag
- Global Const CS_OPT_RESTREES = 5028 'return resolution trees
- Global Const CS_OPT_IDENTITYON = 5029 'turn on explicit identity
- Global Const CS_OPT_CURREAD = 5030 'Set session label
- ' @@ curread
- Global Const CS_OPT_CURWRITE = 5031 'Set session label
- ' @@curwrite
- Global Const CS_OPT_IDENTITYOFF = 5032 'turn off explicit identity
- Global Const CS_OPT_AUTHOFF = 5033 'Set authority level off
- Global Const CS_OPT_ANSINULL = 5034 'ANSI NULLS behavior
- Global Const CS_OPT_QUOTED_IDENT = 5035 'Quoted identifiers
- Global Const CS_OPT_ANSIPERM = 5036 'ANSI permission checking
- Global Const CS_OPT_STR_RTRUNC = 5037 'ANSI right truncation
-
- 'global const CS_MIN_OPTION CS_OPT_DATEFIRST
- 'global const CS_MAX_OPTION CS_OPT_STR_RTRUNC
-
-
- ' The supported options are summarized below with their defined values
- ' for `ArgSize' and `OptionArg'. ArgSize specifies the domain of valid
- ' values that are allowed.
- '
- ' Option ArgSize OptionArg
- ' --------------- --------- ---------
- ' CS_OPT_DATEFIRST 1 byte Defines below
- ' CS_OPT_TEXTSIZE 4 bytes Size in bytes
- ' CS_OPT_ROWCOUNT 4 bytes Number of rows
- ' CS_OPT_NATLANG OptionArg Len National Lang (string)
- ' CS_OPT_DATEFORMAT 1 byte Defines below
- ' CS_OPT_ISOLATION 1 byte Defines below
- ' CS_OPT_AUTHON OptionArg Len Table Name (string)
- ' CS_OPT_CHARSET OptionArg Len Character set (string)
- ' CS_OPT_IDENTITYON OptionArg Len Table Name (string)
- ' CS_OPT_CURREAD OptionArg Len Read Label(string)
- ' CS_OPT_CURWRITE OptionArg Len Write Label(string)
- ' CS_OPT_IDENTITYOFF OptionArg Len Table Name (string)
- ' CS_OPT_AUTHOFF OptionArg Len Table Name (string)
- ' (All remaining options) 1 byte Boolean value
- '
- ' All string values must be sent in 7 bit ASCII.
- '
-
-
-
-
- Global Const CS_OPT_MONDAY = 1
- Global Const CS_OPT_TUESDAY = 2
- Global Const CS_OPT_WEDNESDAY = 3
- Global Const CS_OPT_THURSDAY = 4
- Global Const CS_OPT_FRIDAY = 5
- Global Const CS_OPT_SATURDAY = 6
- Global Const CS_OPT_SUNDAY = 7
-
- ' CS_OPT_DATEFORMAT
- Global Const CS_OPT_FMTMDY = 1
- Global Const CS_OPT_FMTDMY = 2
- Global Const CS_OPT_FMTYMD = 3
- Global Const CS_OPT_FMTYDM = 4
- Global Const CS_OPT_FMTMYD = 5
- Global Const CS_OPT_FMTDYM = 6
-
- ' CS_OPT_ISOLATION
- Global Const CS_OPT_LEVEL1 = 1
- Global Const CS_OPT_LEVEL3 = 3
-
-
- '
- ' Open Client/Server capabilities.
- '
-
-
-
- ' Capability types.
-
- Global Const CS_CAP_REQUEST = 1
- Global Const CS_CAP_RESPONSE = 2
-
-
- ' Special capability value to set/get all capability values at once.
-
- Global Const CS_ALL_CAPS = 2700
-
-
- ' Capability request values.
-
- Global Const CS_REQ_LANG = 1
- Global Const CS_REQ_RPC = 2
- Global Const CS_REQ_NOTIF = 3
- Global Const CS_REQ_MSTMT = 4
- Global Const CS_REQ_BCP = 5
- Global Const CS_REQ_CURSOR = 6
- Global Const CS_REQ_DYN = 7
- Global Const CS_REQ_MSG = 8
- Global Const CS_REQ_PARAM = 9
- Global Const CS_DATA_INT1 = 10
- Global Const CS_DATA_INT2 = 11
- Global Const CS_DATA_INT4 = 12
- Global Const CS_DATA_BIT = 13
- Global Const CS_DATA_CHAR = 14
- Global Const CS_DATA_VCHAR = 15
- Global Const CS_DATA_BIN = 16
- Global Const CS_DATA_VBIN = 17
- Global Const CS_DATA_MNY8 = 18
- Global Const CS_DATA_MNY4 = 19
- Global Const CS_DATA_DATE8 = 20
- Global Const CS_DATA_DATE4 = 21
- Global Const CS_DATA_FLT4 = 22
- Global Const CS_DATA_FLT8 = 23
- Global Const CS_DATA_NUM = 24
- Global Const CS_DATA_TEXT = 25
- Global Const CS_DATA_IMAGE = 26
- Global Const CS_DATA_DEC = 27
- Global Const CS_DATA_LCHAR = 28
- Global Const CS_DATA_LBIN = 29
- Global Const CS_DATA_INTN = 30
- Global Const CS_DATA_DATETIMEN = 31
- Global Const CS_DATA_MONEYN = 32
- Global Const CS_CSR_PREV = 33
- Global Const CS_CSR_FIRST = 34
- Global Const CS_CSR_LAST = 35
- Global Const CS_CSR_ABS = 36
- Global Const CS_CSR_REL = 37
- Global Const CS_CSR_MULTI = 38
- Global Const CS_CON_OOB = 39
- Global Const CS_CON_INBAND = 40
- Global Const CS_CON_LOGICAL = 41
- Global Const CS_PROTO_TEXT = 42
- Global Const CS_PROTO_BULK = 43
- Global Const CS_REQ_URGNOTIF = 44
- Global Const CS_DATA_SENSITIVITY = 45
- Global Const CS_DATA_BOUNDARY = 46
- Global Const CS_PROTO_DYNAMIC = 47
- Global Const CS_PROTO_DYNPROC = 48
- Global Const CS_DATA_FLTN = 49
- Global Const CS_DATA_BITN = 50
- Global Const CS_OPTION_GET = 51
- Global Const CS_DATA_INT8 = 52
-
-
- ' Minimum and maximum request capability values.
-
- 'global const CS_MIN_REQ_CAP CS_REQ_LANG
- 'global const CS_MAX_REQ_CAP CS_DATA_INT8
-
-
- ' Capability response values.
-
- Global Const CS_RES_NOMSG = 1
- Global Const CS_RES_NOEED = 2
- Global Const CS_RES_NOPARAM = 3
- Global Const CS_DATA_NOINT1 = 4
- Global Const CS_DATA_NOINT2 = 5
- Global Const CS_DATA_NOINT4 = 6
- Global Const CS_DATA_NOBIT = 7
- Global Const CS_DATA_NOCHAR = 8
- Global Const CS_DATA_NOVCHAR = 9
- Global Const CS_DATA_NOBIN = 10
- Global Const CS_DATA_NOVBIN = 11
- Global Const CS_DATA_NOMNY8 = 12
- Global Const CS_DATA_NOMNY4 = 13
- Global Const CS_DATA_NODATE8 = 14
- Global Const CS_DATA_NODATE4 = 15
- Global Const CS_DATA_NOFLT4 = 16
- Global Const CS_DATA_NOFLT8 = 17
- Global Const CS_DATA_NONUM = 18
- Global Const CS_DATA_NOTEXT = 19
- Global Const CS_DATA_NOIMAGE = 20
- Global Const CS_DATA_NODEC = 21
- Global Const CS_DATA_NOLCHAR = 22
- Global Const CS_DATA_NOLBIN = 23
- Global Const CS_DATA_NOINTN = 24
- Global Const CS_DATA_NODATETIMEN = 25
- Global Const CS_DATA_NOMONEYN = 26
- Global Const CS_CON_NOOOB = 27
- Global Const CS_CON_NOINBAND = 28
- Global Const CS_PROTO_NOTEXT = 29
- Global Const CS_PROTO_NOBULK = 30
- Global Const CS_DATA_NOSENSITIVITY = 31
- Global Const CS_DATA_NOBOUNDARY = 32
- Global Const CS_RES_NOTDSDEBUG = 33
- Global Const CS_RES_NOSTRIPBLANKS = 34
- Global Const CS_DATA_NOINT8 = 35
-
-
- ' Minimum and maximum response capability values.
-
- 'global const CS_MIN_RES_CAP CS_RES_NOMSG
- 'global const CS_MAX_RES_CAP CS_DATA_NOINT8
-
-
- ' Minimum and maximum of all capabilities defined above.
-
- 'global const CS_MIN_CAPVALUE CS_REQ_LANG
- 'global const CS_MAX_CAPVALUE CS_DATA_INT8
-
-
- ' Size of area to store capabilities. The array len must be greater than
- ' ((CS_CAP_MAX / CS_BITS_PER_BYTE) + 1). The current value allows
- ' additional capabilities to be added.
-
- Global Const CS_CAP_ARRAYLEN = 16
-
-
-
- ' Data structure defining storage for capabilities.
-
- 'typedef struct _cs_cap_type
- '{
- ' CS_BYTE mask[CS_CAP_ARRAYLEN];
- '} CS_CAP_TYPE;
-
-
-
- '
- ' Defines used in Open Client/Server structures.
- '
-
-
-
- ' Define I/O types in the CS_IODESC structure.
-
- Global Const CS_IODATA = 1600
-
-
- ' Define status values for the status field of the CS_SERVERMSG and
- ' CS_CLIENTMSG structures.
-
- Global Const CS_HASEED = 1
- Global Const CS_FIRST_CHUNK = 2
- Global Const CS_LAST_CHUNK = 4
-
-
- ''''''''''''''''''''''''''''''''''''''
- '
- ' User-accessible information structures.
- '
- ''''''''''''''''''''''''''''''''''''''
-
-
- ' Define the I/O descriptor structure used by Open Client/Server.
- '
- ' iotype Indicates the type of I/O to perform. For text
- ' and image operations, iotype always has the
- ' value CS_IODATA.
- '
- ' datatype The datatype of the data object. The only legal
- ' values for datatype are CS_TEXT_TYPE and
- ' CS_IMAGE_TYPE.
- '
- ' *locale A pointer to a CS_LOCALE structure containing
- ' localization information for the text or image
- ' value. Set locale to NULL if localization
- ' information is not required.
- '
- ' usertype The SQL Server user-defined datatype of the data
- ' object, if any.
- '
- ' total_txtlen The total length, in bytes, of the text or image
- ' value.
- '
- ' offset Reserved for future use.
- '
- ' log_on_update Whether the update for this text object should
- ' be logged or not.
- '
- ' name The name of the text or image column. name is a
- ' string of the form table.column.
- '
- ' namelen The actual length of name
- '
- ' timestamp The text timestamp of the column. A text
- ' timestamp marks the time of a text or image
- ' column's last modification.
- '
- ' timestamplen The length, in bytes, of timestamp.
- '
- ' textptr The text pointer for the column. A text pointer
- ' is an internal server pointer that points to the
- ' data for a text or image column. textptr identifies
- ' the target column in a send-data operation.
- '
- ' textptrlen The length, in bytes, of textptr.
-
-
- 'typedef struct _cs_iodesc
- '{
- ' CS_INT iotype;
- ' CS_INT datatype;
- ' CS_LOCALE *locale;
- ' CS_INT usertype;
- ' CS_INT total_txtlen;
- ' CS_INT offset;
- ' CS_BOOL log_on_update;
- ' CS_CHAR name[CS_OBJ_NAME];
- ' CS_INT namelen;
- ' CS_BYTE timestamp[CS_TS_SIZE];
- ' CS_INT timestamplen;
- ' CS_BYTE textptr[CS_TP_SIZE];
- ' CS_INT textptrlen;
- '} CS_IODESC;
-
- Type CS_IODESC
- iotype As Long
- datatype As Long
- locale As Long
- usertype As Long
- total_txtlen As Long
- log_on_update As Long
- nam As String * CS_OBJ_NAME
- namelen As Long
- timestamp As String * CS_TS_SIZE
- timestamplen As Long
- textptr As String * CS_TP_SIZE
- textptrlen As Long
- End Type
-
- ' Define the browse descriptor structure used by Open Client/Server.
- '
- ' status A bit mask of either CS_EXPRESSION and/or CS_RENAMED.
- '
- ' isbrowse CS_TRUE the column can be browse-mode updated.
- '
- ' origname The original name of the column in the database.
- '
- ' orignlen Length of origname in bytes.
- '
- ' tablenum The number of the table to which the column
- ' belongs. The first table in a select statement's
- ' from-list is table number 1, the second number 2,
- ' and so forth.
- '
- ' tablename The name of the table to which the column belongs.
- '
- ' tabnlen Length of tablename in bytes.
- '
-
- 'typedef struct _cs_browsedesc
- '{
- ' CS_INT status;
- ' CS_BOOL isbrowse;
- ' CS_CHAR origname[CS_MAX_NAME];
- ' CS_INT orignlen;
- ' CS_INT tablenum;
- ' CS_CHAR tablename[CS_OBJ_NAME];
- ' CS_INT tabnlen;
- '} CS_BROWSEDESC;
-
-
-
- ' Define the server message structure used by Open Client/Server.
- '
- ' msgnumber The server message number.
- '
- ' state The server error state.
- '
- ' severity The severity of the message.
- '
- ' text The text of the error string. If an application
- ' is not sequencing messages, text is guaranteed
- ' to be null-terminated, even if it has been
- ' truncated. If an application is sequencing
- ' messages, text is null-terminated only if it is
- ' the last chunk of a sequenced message.
- '
- ' textlen The length, in bytes, of text.
- '
- ' svrname The name of the server that generated the message.
- '
- ' svrnlen The length, in bytes, of svrname.
- '
- ' proc The name of the stored procedure which caused
- ' the message, if any.
- '
- ' proclen The length, in bytes, of proc.
- '
- ' line The line number, if any, of the line that caused
- ' the message. line can be a line number in a
- ' stored procedure or a line number in a command
- ' batch.
- '
- ' status A bitmask used to indicate various types of
- ' information, such as whether or not extended
- ' error data is included with the message.
- '
- ' sqlstate SQL state information.
- '
- ' sqlstatelen The length, in bytes, of sqlstate.
- '
-
- 'typedef struct _cs_servermsg
- '{
- Type CS_SERVERMSG
- msgnumber As Long
- state As Long
- severity As Long
- text As String * CS_MAX_MSG
- textlen As Long
- svrname As String * CS_MAX_NAME
- svrnlen As Long
- proc As String * CS_MAX_NAME
- proclen As Long
- line As Long
- status As Long
- sqlstate As String * CS_SQLSTATE_SIZE
- sqlstatelen As Long
- End Type
- '} CS_SERVERMSG;
-
-
- ' Define the client message structure used by Open Client/Server.
- '
- ' severity A symbolic value representing the severity of
- ' the message.
- '
- ' msgnumber The message number. For information on how to
- ' interpret this number in Client-Library
- ' applications, see the Client-Library Messages
- ' topics in the Open Client documentation.
- '
- ' msgstring The message string. If an application is not
- ' sequencing messages, msgstring is guaranteed to
- ' be null-terminated, even if it has been truncated.
- ' If an application is sequencing messages,
- ' msgstring is null-terminated only if it is the
- ' last chunk of a sequenced message.
- '
- ' msgstringlen The length, in bytes, of msgstring.
- '
- ' osnumber An error may have involved interactions the
- ' operating system (OS). If so, the OS error
- ' number would be stored here. Otherwise,
- ' this will be zero.
- '
- ' osstring The operating system error text (if any).
- '
- ' osstringlen The length, in bytes, of osstring.
- '
- ' status A bitmask used to indicate various types of
- ' information, such as whether or not this is the
- ' first, a middle, or the last chunk of an error
- ' message.
- '
- ' sqlstate SQL state information.
- '
- ' sqlstatelen The length, in bytes, of sqlstate.
- '
-
- 'typedef struct _cs_clientmsg
- '{
- Type CS_CLIENTMSG
- severity As Long
- msgnumber As Long
- msgstring As String * 1024
- msgstringlen As Long
- osnumber As Long
- osstring As String * 1024
- osstringlen As Long
- status As Long
- sqlstate As String * 8
- sqlstatelen As Long
- End Type
- '} CS_CLIENTMSG;
-
-
- '
- ' Define user-accessable functions for Client/Server Library here.
- '
-
-
-
-
-