297
297
connection. All uses of the connection(s) should be between these
300
bool STDCALL drizzle_thread_init(void);
301
void STDCALL drizzle_thread_end(void);
300
bool drizzle_thread_init(void);
301
void drizzle_thread_end(void);
304
304
Functions to get information from the DRIZZLE and DRIZZLE_RES structures
305
305
Should definitely be used if one uses shared libraries.
308
uint64_t STDCALL drizzle_num_rows(const DRIZZLE_RES *res);
309
unsigned int STDCALL drizzle_num_fields(const DRIZZLE_RES *res);
310
bool STDCALL drizzle_eof(const DRIZZLE_RES *res);
308
uint64_t drizzle_num_rows(const DRIZZLE_RES *res);
309
unsigned int drizzle_num_fields(const DRIZZLE_RES *res);
310
bool drizzle_eof(const DRIZZLE_RES *res);
311
311
const DRIZZLE_FIELD *STDCALL drizzle_fetch_field_direct(const DRIZZLE_RES *res,
312
312
unsigned int fieldnr);
313
const DRIZZLE_FIELD * STDCALL drizzle_fetch_fields(const DRIZZLE_RES *res);
314
DRIZZLE_ROW_OFFSET STDCALL drizzle_row_tell(const DRIZZLE_RES *res);
315
DRIZZLE_FIELD_OFFSET STDCALL drizzle_field_tell(const DRIZZLE_RES *res);
313
const DRIZZLE_FIELD * drizzle_fetch_fields(const DRIZZLE_RES *res);
314
DRIZZLE_ROW_OFFSET drizzle_row_tell(const DRIZZLE_RES *res);
315
DRIZZLE_FIELD_OFFSET drizzle_field_tell(const DRIZZLE_RES *res);
317
uint32_t STDCALL drizzle_field_count(const DRIZZLE *drizzle);
318
uint64_t STDCALL drizzle_affected_rows(const DRIZZLE *drizzle);
319
uint64_t STDCALL drizzle_insert_id(const DRIZZLE *drizzle);
320
uint32_t STDCALL drizzle_errno(const DRIZZLE *drizzle);
321
const char * STDCALL drizzle_error(const DRIZZLE *drizzle);
317
uint32_t drizzle_field_count(const DRIZZLE *drizzle);
318
uint64_t drizzle_affected_rows(const DRIZZLE *drizzle);
319
uint64_t drizzle_insert_id(const DRIZZLE *drizzle);
320
uint32_t drizzle_errno(const DRIZZLE *drizzle);
321
const char * drizzle_error(const DRIZZLE *drizzle);
322
322
const char *STDCALL drizzle_sqlstate(const DRIZZLE *drizzle);
323
uint32_t STDCALL drizzle_warning_count(const DRIZZLE *drizzle);
324
const char * STDCALL drizzle_info(const DRIZZLE *drizzle);
325
uint32_t STDCALL drizzle_thread_id(const DRIZZLE *drizzle);
326
const char * STDCALL drizzle_character_set_name(const DRIZZLE *drizzle);
327
int32_t STDCALL drizzle_set_character_set(DRIZZLE *drizzle, const char *csname);
323
uint32_t drizzle_warning_count(const DRIZZLE *drizzle);
324
const char * drizzle_info(const DRIZZLE *drizzle);
325
uint32_t drizzle_thread_id(const DRIZZLE *drizzle);
326
const char * drizzle_character_set_name(const DRIZZLE *drizzle);
327
int32_t drizzle_set_character_set(DRIZZLE *drizzle, const char *csname);
329
DRIZZLE * STDCALL drizzle_create(DRIZZLE *drizzle);
330
bool STDCALL drizzle_change_user(DRIZZLE *drizzle, const char *user,
329
DRIZZLE * drizzle_create(DRIZZLE *drizzle);
330
bool drizzle_change_user(DRIZZLE *drizzle, const char *user,
331
331
const char *passwd, const char *db);
332
DRIZZLE * STDCALL drizzle_connect(DRIZZLE *drizzle, const char *host,
332
DRIZZLE * drizzle_connect(DRIZZLE *drizzle, const char *host,
333
333
const char *user,
334
334
const char *passwd,
337
337
const char *unix_socket,
338
338
uint32_t clientflag);
339
int32_t STDCALL drizzle_select_db(DRIZZLE *drizzle, const char *db);
340
int32_t STDCALL drizzle_query(DRIZZLE *drizzle, const char *q);
341
int32_t STDCALL drizzle_send_query(DRIZZLE *drizzle, const char *q, uint32_t length);
342
int32_t STDCALL drizzle_real_query(DRIZZLE *drizzle, const char *q, uint32_t length);
343
DRIZZLE_RES * STDCALL drizzle_store_result(DRIZZLE *drizzle);
344
DRIZZLE_RES * STDCALL drizzle_use_result(DRIZZLE *drizzle);
339
int32_t drizzle_select_db(DRIZZLE *drizzle, const char *db);
340
int32_t drizzle_query(DRIZZLE *drizzle, const char *q);
341
int32_t drizzle_send_query(DRIZZLE *drizzle, const char *q, uint32_t length);
342
int32_t drizzle_real_query(DRIZZLE *drizzle, const char *q, uint32_t length);
343
DRIZZLE_RES * drizzle_store_result(DRIZZLE *drizzle);
344
DRIZZLE_RES * drizzle_use_result(DRIZZLE *drizzle);
346
void STDCALL drizzle_get_character_set_info(const DRIZZLE *drizzle,
346
void drizzle_get_character_set_info(const DRIZZLE *drizzle,
347
347
MY_CHARSET_INFO *charset);
349
349
/* local infile support */
361
361
drizzle_set_local_infile_default(DRIZZLE *drizzle);
363
int32_t STDCALL drizzle_shutdown(DRIZZLE *drizzle, enum drizzle_enum_shutdown_level shutdown_level);
364
int32_t STDCALL drizzle_dump_debug_info(DRIZZLE *drizzle);
365
int32_t STDCALL drizzle_refresh(DRIZZLE *drizzle, uint32_t refresh_options);
366
int32_t STDCALL drizzle_kill(DRIZZLE *drizzle, uint32_t pid);
367
int32_t STDCALL drizzle_set_server_option(DRIZZLE *drizzle, enum enum_drizzle_set_option option);
368
int32_t STDCALL drizzle_ping(DRIZZLE *drizzle);
369
const char * STDCALL drizzle_stat(DRIZZLE *drizzle);
370
const char * STDCALL drizzle_get_server_info(const DRIZZLE *drizzle);
371
const char * STDCALL drizzle_get_client_info(void);
372
uint32_t STDCALL drizzle_get_client_version(void);
373
const char * STDCALL drizzle_get_host_info(const DRIZZLE *drizzle);
374
uint32_t STDCALL drizzle_get_server_version(const DRIZZLE *drizzle);
375
uint32_t STDCALL drizzle_get_proto_info(const DRIZZLE *drizzle);
376
DRIZZLE_RES * STDCALL drizzle_list_tables(DRIZZLE *drizzle,const char *wild);
377
DRIZZLE_RES * STDCALL drizzle_list_processes(DRIZZLE *drizzle);
378
int32_t STDCALL drizzle_options(DRIZZLE *drizzle,enum drizzle_option option, const void *arg);
379
void STDCALL drizzle_free_result(DRIZZLE_RES *result);
380
void STDCALL drizzle_data_seek(DRIZZLE_RES *result, uint64_t offset);
381
DRIZZLE_ROW_OFFSET STDCALL drizzle_row_seek(DRIZZLE_RES *result, DRIZZLE_ROW_OFFSET offset);
382
DRIZZLE_FIELD_OFFSET STDCALL drizzle_field_seek(DRIZZLE_RES *result, DRIZZLE_FIELD_OFFSET offset);
383
DRIZZLE_ROW STDCALL drizzle_fetch_row(DRIZZLE_RES *result);
384
uint32_t * STDCALL drizzle_fetch_lengths(DRIZZLE_RES *result);
385
DRIZZLE_FIELD * STDCALL drizzle_fetch_field(DRIZZLE_RES *result);
386
DRIZZLE_RES * STDCALL drizzle_list_fields(DRIZZLE *drizzle, const char *table, const char *wild);
387
uint32_t STDCALL drizzle_escape_string(char *to,const char *from, uint32_t from_length);
388
uint32_t STDCALL drizzle_hex_string(char *to,const char *from, uint32_t from_length);
389
uint32_t STDCALL drizzle_real_escape_string(DRIZZLE *drizzle, char *to, const char *from, uint32_t length);
390
void STDCALL myodbc_remove_escape(const DRIZZLE *drizzle, char *name);
391
uint32_t STDCALL drizzle_thread_safe(void);
392
bool STDCALL drizzle_embedded(void);
393
bool STDCALL drizzle_read_query_result(DRIZZLE *drizzle);
363
int32_t drizzle_shutdown(DRIZZLE *drizzle, enum drizzle_enum_shutdown_level shutdown_level);
364
int32_t drizzle_dump_debug_info(DRIZZLE *drizzle);
365
int32_t drizzle_refresh(DRIZZLE *drizzle, uint32_t refresh_options);
366
int32_t drizzle_kill(DRIZZLE *drizzle, uint32_t pid);
367
int32_t drizzle_set_server_option(DRIZZLE *drizzle, enum enum_drizzle_set_option option);
368
int32_t drizzle_ping(DRIZZLE *drizzle);
369
const char * drizzle_stat(DRIZZLE *drizzle);
370
const char * drizzle_get_server_info(const DRIZZLE *drizzle);
371
const char * drizzle_get_client_info(void);
372
uint32_t drizzle_get_client_version(void);
373
const char * drizzle_get_host_info(const DRIZZLE *drizzle);
374
uint32_t drizzle_get_server_version(const DRIZZLE *drizzle);
375
uint32_t drizzle_get_proto_info(const DRIZZLE *drizzle);
376
DRIZZLE_RES * drizzle_list_tables(DRIZZLE *drizzle,const char *wild);
377
DRIZZLE_RES * drizzle_list_processes(DRIZZLE *drizzle);
378
int32_t drizzle_options(DRIZZLE *drizzle,enum drizzle_option option, const void *arg);
379
void drizzle_free_result(DRIZZLE_RES *result);
380
void drizzle_data_seek(DRIZZLE_RES *result, uint64_t offset);
381
DRIZZLE_ROW_OFFSET drizzle_row_seek(DRIZZLE_RES *result, DRIZZLE_ROW_OFFSET offset);
382
DRIZZLE_FIELD_OFFSET drizzle_field_seek(DRIZZLE_RES *result, DRIZZLE_FIELD_OFFSET offset);
383
DRIZZLE_ROW drizzle_fetch_row(DRIZZLE_RES *result);
384
uint32_t * drizzle_fetch_lengths(DRIZZLE_RES *result);
385
DRIZZLE_FIELD * drizzle_fetch_field(DRIZZLE_RES *result);
386
DRIZZLE_RES * drizzle_list_fields(DRIZZLE *drizzle, const char *table, const char *wild);
387
uint32_t drizzle_escape_string(char *to,const char *from, uint32_t from_length);
388
uint32_t drizzle_hex_string(char *to,const char *from, uint32_t from_length);
389
uint32_t drizzle_real_escape_string(DRIZZLE *drizzle, char *to, const char *from, uint32_t length);
390
void myodbc_remove_escape(const DRIZZLE *drizzle, char *name);
391
uint32_t drizzle_thread_safe(void);
392
bool drizzle_embedded(void);
393
bool drizzle_read_query_result(DRIZZLE *drizzle);
416
416
} DRIZZLE_METHODS;
419
bool STDCALL drizzle_commit(DRIZZLE *drizzle);
420
bool STDCALL drizzle_rollback(DRIZZLE *drizzle);
421
bool STDCALL drizzle_autocommit(DRIZZLE *drizzle, bool auto_mode);
422
bool STDCALL drizzle_more_results(const DRIZZLE *drizzle);
423
int STDCALL drizzle_next_result(DRIZZLE *drizzle);
424
void STDCALL drizzle_close(DRIZZLE *sock);
419
bool drizzle_commit(DRIZZLE *drizzle);
420
bool drizzle_rollback(DRIZZLE *drizzle);
421
bool drizzle_autocommit(DRIZZLE *drizzle, bool auto_mode);
422
bool drizzle_more_results(const DRIZZLE *drizzle);
423
int drizzle_next_result(DRIZZLE *drizzle);
424
void drizzle_close(DRIZZLE *sock);
427
427
/* status return codes */