20#ifndef _tdsguard_gH4tOYBTzynx4DgqFzOEbB_
21#define _tdsguard_gH4tOYBTzynx4DgqFzOEbB_
24#include <freetds/convert.h>
25#include <freetds/utils/string.h>
26#include <freetds/bool.h>
32#include <freetds/pushvis.h>
50 bool cs_expose_formats;
51 bool cs_note_empty_data;
69 CS_CHAR text[CS_MAX_MSG];
77 CS_BYTE sqlstate[CS_SQLSTATE_SIZE];
85 CS_CHAR text[CS_MAX_MSG];
93 CS_BYTE sqlstate[CS_SQLSTATE_SIZE];
101 CS_CHAR text[CS_MAX_MSG];
108 CS_BYTE sqlstate[CS_SQLSTATE_SIZE];
136 CS_INT date_convert_fmt;
137 CS_INT cs_errhandletype;
138 CS_INT cs_diag_msglimit;
143 CS_INT cs_diag_msglimit_client;
144 CS_INT cs_diag_msglimit_server;
145 CS_INT cs_diag_msglimit_total;
152 CS_CSLIBMSG_FUNC cslibmsg_cb;
153 CS_CLIENTMSG_FUNC clientmsg_cb;
154 CS_SERVERMSG_FUNC servermsg_cb;
155 CS_INTERRUPT_FUNC interrupt_cb;
169static inline size_t cs_servermsg_len(
CS_CONTEXT *ctx)
181 TDS_SMALLINT *indicator;
192 CS_CLIENTMSG_FUNC clientmsg_cb;
193 CS_SERVERMSG_FUNC servermsg_cb;
194 CS_INTERRUPT_FUNC interrupt_cb;
222 CS_INT datalen_value;
223 CS_SMALLINT indicator_value;
257#define CS_DYNAMIC_CMD 160
258#define CS_CUR_CMD 161
262#define _CS_RES_NONE -1
263#define _CS_RES_INIT 0
264#define _CS_RES_RESULTSET_EMPTY 1
265#define _CS_RES_RESULTSET_ROWS 2
266#define _CS_RES_STATUS 3
267#define _CS_RES_CMD_DONE 4
268#define _CS_RES_CMD_SUCCEED 5
269#define _CS_RES_END_RESULTS 6
270#define _CS_RES_DESCRIBE_RESULT 7
274#define _CS_COMMAND_IDLE 0
275#define _CS_COMMAND_BUILDING 1
276#define _CS_COMMAND_READY 2
277#define _CS_COMMAND_SENT 3
280#define _CS_CANCEL_NOCANCEL 0
281#define _CS_CANCEL_PENDING 1
286 CS_INT command_state;
287 CS_INT results_state;
296 int curr_result_type;
299 int get_data_bytes_returned;
301 CS_INT send_data_started;
304 CS_INT client_cursor_id;
316#define _CS_ERRHAND_INLINE 1
317#define _CS_ERRHAND_CB 2
329#define _CS_CURS_TYPE_UNACTIONED 0
330#define _CS_CURS_TYPE_REQUESTED 1
331#define _CS_CURS_TYPE_SENT 2
385int _ct_handle_interrupt(
void * ptr);
386TDS_SERVER_TYPE _ct_get_server_type(
TDSSOCKET *tds,
int datatype);
388int _ct_get_client_type(
const TDSCOLUMN *col,
bool describe);
390 int layer,
int origin,
int severity,
int number,
391 const char *fmt, ...);
392CS_INT _ct_diag_clearmsg(
CS_CONTEXT * context, CS_INT type);
396CS_INT _ct_get_string_length(
const char *buf, CS_INT buflen);
401 const CS_DATAFMT_COMMON * destfmt, CS_VOID * destdata, CS_INT * resultlen, TDS_SERVER_TYPE desttype);
402bool _ct_is_large_identifiers_version(CS_INT version);
408CS_RETCODE _ct_props_dstr(
CS_CONNECTION * con,
DSTR *s, CS_INT action, CS_VOID * buffer, CS_INT buflen, CS_INT * outlen);
417#include <freetds/popvis.h>
Main include file for libtds.
int login_timeout
not used unless positive
Definition ctlib.h:162
bool use_large_identifiers
structures uses large identifiers
Definition ctlib.h:166
int query_timeout
not used unless positive
Definition ctlib.h:163
Metadata about columns in regular and compute rows.
Definition tds.h:674
Hold information for any results.
Definition tds.h:754
Holds information about a cursor.
Definition tds.h:922
Holds information for a dynamic (also called prepared) query.
Definition tds.h:962
Information for a server connection.
Definition tds.h:1162
Structure to hold a string.
Definition string.h:36