CUBRID Engine
latest
|
Go to the source code of this file.
Classes | |
struct | t_fk_info_result |
Macros | |
#define | CAS_TYPE_SET(TYPE) ((TYPE) | CCI_CODE_SET) |
#define | CAS_TYPE_MULTISET(TYPE) ((TYPE) | CCI_CODE_MULTISET) |
#define | CAS_TYPE_SEQUENCE(TYPE) ((TYPE) | CCI_CODE_SEQUENCE) |
#define | CAS_TYPE_COLLECTION(DB_TYPE, SET_TYPE) |
#define | IS_ERROR_INFO_SET() is_error_info_set() |
#define | ERROR_INFO_SET(ERR_CODE, ERR_INDICATOR) error_info_set(ERR_CODE, ERR_INDICATOR, __FILE__, __LINE__) |
#define | ERROR_INFO_SET_FORCE(ERR_CODE, ERR_INDICATOR) error_info_set_force(ERR_CODE, ERR_INDICATOR, __FILE__, __LINE__) |
#define | ERROR_INFO_SET_WITH_MSG(ERR_CODE, ERR_INDICATOR, ERR_MSG) error_info_set_with_msg(ERR_CODE, ERR_INDICATOR, ERR_MSG, false, __FILE__, __LINE__) |
#define | NET_BUF_ERR_SET(NET_BUF) err_msg_set(NET_BUF, __FILE__, __LINE__) |
Typedefs | |
typedef struct t_fk_info_result | T_FK_INFO_RESULT |
Functions | |
int | ux_check_connection (void) |
int | ux_database_connect (char *db_name, char *db_user, char *db_passwd, char **db_err_msg) |
int | ux_database_reconnect (void) |
int | ux_is_database_connected (void) |
int | ux_prepare (char *sql_stmt, int flag, char auto_commit_mode, T_NET_BUF *ne_buf, T_REQ_INFO *req_info, unsigned int query_seq_num) |
int | ux_end_tran (int tran_type, bool reset_con_status) |
int | ux_end_session (void) |
int | ux_get_row_count (T_NET_BUF *net_buf) |
int | ux_get_last_insert_id (T_NET_BUF *net_buf) |
int | ux_auto_commit (T_NET_BUF *CAS_FN_ARG_NET_BUF, T_REQ_INFO *CAS_FN_ARG_REQ_INFO) |
int | ux_execute (T_SRV_HANDLE *srv_handle, char flag, int max_col_size, int max_row, int argc, void **argv, T_NET_BUF *, T_REQ_INFO *req_info, CACHE_TIME *clt_cache_time, int *clt_cache_reusable) |
void | ux_get_tran_setting (int *lock_wait, int *isol_level) |
int | ux_set_isolation_level (int isol_level, T_NET_BUF *net_buf) |
void | ux_set_lock_timeout (int lock_timeout) |
void | ux_set_cas_change_mode (int mode, T_NET_BUF *net_buf) |
int | ux_fetch (T_SRV_HANDLE *srv_handle, int cursor_pos, int fetch_count, char fetch_flag, int result_set_index, T_NET_BUF *net_buf, T_REQ_INFO *req_info) |
int | ux_oid_get (int argc, void **argv, T_NET_BUF *net_buf) |
int | ux_cursor (int srv_h_id, int offset, int origin, T_NET_BUF *net_buf) |
void | ux_database_shutdown (void) |
int | ux_get_db_version (T_NET_BUF *net_buf, T_REQ_INFO *req_info) |
int | ux_get_class_num_objs (char *class_name, int flag, T_NET_BUF *net_buf) |
void | ux_col_get (DB_COLLECTION *col, char col_type, char ele_type, DB_DOMAIN *ele_domain, T_NET_BUF *net_buf) |
void | ux_col_size (DB_COLLECTION *col, T_NET_BUF *net_buf) |
int | ux_col_set_drop (DB_COLLECTION *col, DB_VALUE *ele_val, T_NET_BUF *net_buf) |
int | ux_col_set_add (DB_COLLECTION *col, DB_VALUE *ele_val, T_NET_BUF *net_buf) |
int | ux_col_seq_drop (DB_COLLECTION *col, int index, T_NET_BUF *net_buf) |
int | ux_col_seq_insert (DB_COLLECTION *col, int index, DB_VALUE *ele_val, T_NET_BUF *net_buf) |
int | ux_col_seq_put (DB_COLLECTION *col, int index, DB_VALUE *ele_val, T_NET_BUF *net_buf) |
char | get_set_domain (DB_DOMAIN *col, int *precision, short *scale, char *db_type, char *charset) |
int | ux_next_result (T_SRV_HANDLE *srv_h_id, char flag, T_NET_BUF *net_buf, T_REQ_INFO *req_info) |
int | ux_execute_all (T_SRV_HANDLE *srv_handle, char flag, int max_col_size, int max_row, int argc, void **argv, T_NET_BUF *net_buf, T_REQ_INFO *req_info, CACHE_TIME *clt_cache_time, int *clt_cache_reusable) |
int | ux_execute_array (T_SRV_HANDLE *srv_h_id, int argc, void **argv, T_NET_BUF *net_buf, T_REQ_INFO *req_info) |
int | ux_execute_batch (int argc, void **argv, T_NET_BUF *net_buf, T_REQ_INFO *req_info, char auto_commit_mode) |
int | ux_cursor_update (T_SRV_HANDLE *srv_handle, int cursor_pos, int argc, void **argv, T_NET_BUF *net_buf) |
void | ux_cursor_close (T_SRV_HANDLE *srv_handle) |
int | ux_oid_put (int argc, void **argv, T_NET_BUF *net_buf) |
int | make_bind_value (int num_bind, int argc, void **argv, DB_VALUE **ret_val, T_NET_BUF *net_buf, char desired_type) |
int | ux_get_attr_type_str (char *class_name, char *attr_name, T_NET_BUF *net_buf, T_REQ_INFO *) |
int | ux_get_query_info (int srv_h_id, char info_type, T_NET_BUF *net_buf) |
int | ux_get_parameter_info (int srv_h_id, T_NET_BUF *net_buf) |
void | ux_get_default_setting (void) |
void | ux_get_system_parameter (const char *param, bool *value) |
void | ux_set_default_setting (void) |
int | ux_check_object (DB_OBJECT *obj, T_NET_BUF *net_buf) |
void | ux_free_result (void *res) |
char | ux_db_type_to_cas_type (int db_type) |
void | ux_set_utype_for_enum (char u_type) |
void | ux_set_utype_for_timestamptz (char u_type) |
void | ux_set_utype_for_datetimetz (char u_type) |
void | ux_set_utype_for_timestampltz (char u_type) |
void | ux_set_utype_for_datetimeltz (char u_type) |
void | ux_set_utype_for_json (char u_type) |
int | ux_schema_info (int schema_type, char *arg1, char *arg2, char flag, T_NET_BUF *net_buf, T_REQ_INFO *req_info, unsigned int query_seq_num) |
void | ux_prepare_call_info_free (T_PREPARE_CALL_INFO *call_info) |
int | ux_execute_call (T_SRV_HANDLE *srv_handle, char flag, int max_col_size, int max_row, int argc, void **argv, T_NET_BUF *net_buf, T_REQ_INFO *req_info, CACHE_TIME *clt_cache_time, int *clt_cache_reusable) |
void | ux_call_info_cp_param_mode (T_SRV_HANDLE *srv_handle, char *param_mode, int num_param) |
int | ux_make_out_rs (int srv_h_id, T_NET_BUF *net_buf, T_REQ_INFO *req_info) |
int | ux_get_generated_keys (T_SRV_HANDLE *srv_handle, T_NET_BUF *net_buf) |
SESSION_ID | ux_get_session_id (void) |
void | ux_set_session_id (const SESSION_ID session_id) |
void | release_all_fk_info_results (T_FK_INFO_RESULT *fk_res) |
int | is_error_info_set (void) |
void | err_msg_set (T_NET_BUF *net_buf, const char *file, int line) |
int | error_info_set (int err_number, int err_indicator, const char *file, int line) |
int | error_info_set_force (int err_number, int err_indicator, const char *file, int line) |
int | error_info_set_with_msg (int err_number, int err_indicator, const char *err_msg, bool force, const char *file, int line) |
void | error_info_clear (void) |
void | set_server_aborted (bool is_aborted) |
bool | is_server_aborted (void) |
void | cas_log_error_handler (unsigned int eid) |
void | cas_log_error_handler_begin (void) |
void | cas_log_error_handler_end (void) |
void | cas_log_error_handler_clear (void) |
char * | cas_log_error_handler_asprint (char *buf, size_t bufsz, bool clear) |
void | set_optimization_level (int level) |
void | reset_optimization_level_as_saved (void) |
int | ux_lob_new (int lob_type, T_NET_BUF *net_buf) |
int | ux_lob_write (DB_VALUE *lob_dbval, int64_t offset, int size, char *data, T_NET_BUF *net_buf) |
int | ux_lob_read (DB_VALUE *lob_dbval, int64_t offset, int size, T_NET_BUF *net_buf) |
int | get_tuple_count (T_SRV_HANDLE *srv_handle) |
#define CAS_TYPE_COLLECTION | ( | DB_TYPE, | |
SET_TYPE | |||
) |
Definition at line 43 of file cas_execute.h.
Referenced by set_extended_cas_type().
#define CAS_TYPE_MULTISET | ( | TYPE | ) | ((TYPE) | CCI_CODE_MULTISET) |
Definition at line 40 of file cas_execute.h.
#define CAS_TYPE_SEQUENCE | ( | TYPE | ) | ((TYPE) | CCI_CODE_SEQUENCE) |
Definition at line 41 of file cas_execute.h.
#define CAS_TYPE_SET | ( | TYPE | ) | ((TYPE) | CCI_CODE_SET) |
Definition at line 39 of file cas_execute.h.
#define ERROR_INFO_SET | ( | ERR_CODE, | |
ERR_INDICATOR | |||
) | error_info_set(ERR_CODE, ERR_INDICATOR, __FILE__, __LINE__) |
Definition at line 49 of file cas_execute.h.
Referenced by cfg_get_dbinfo(), cfg_read_dbinfo(), class_type(), create_srv_handle_with_query_result(), cur_tuple(), dbval_to_net_buf(), fetch_attribute(), fetch_call(), fetch_class(), fetch_methfile(), fetch_method(), fetch_privilege(), fetch_result(), fetch_trigger(), fn_check_cas(), fn_close_req_handle(), fn_collection(), fn_cursor(), fn_cursor_update(), fn_deprecated(), fn_end_tran(), fn_execute_internal(), fn_fetch(), fn_get_attr_type_str(), fn_get_class_num_objs(), fn_get_db_parameter(), fn_get_db_version(), fn_get_generated_keys(), fn_get_query_info(), fn_lob_new(), fn_lob_read(), fn_lob_write(), fn_make_out_rs(), fn_next_result(), fn_not_supported(), fn_oid(), fn_oid_get(), fn_oid_put(), fn_parameter_info(), fn_prepare_internal(), fn_savepoint(), fn_schema_info(), fn_set_cas_change_mode(), fn_set_db_parameter(), fn_xa_end_tran(), fn_xa_prepare(), fn_xa_recover(), get_attr_name(), get_attr_name_from_argv(), hm_new_srv_handle(), make_bind_value(), net_read_to_file(), netval_to_dbval(), oid_attr_info_set(), prepare_column_list_info_set(), sch_attr_priv(), sch_class_priv(), sch_exported_keys_or_cross_reference(), sch_imported_keys(), sch_query_execute(), sch_superclass(), set_host_variables(), ux_auto_commit(), ux_check_object(), ux_col_seq_drop(), ux_col_seq_insert(), ux_col_seq_put(), ux_col_set_add(), ux_col_set_drop(), ux_cursor(), ux_cursor_update(), ux_database_connect(), ux_end_tran(), ux_execute(), ux_execute_all(), ux_execute_array(), ux_execute_batch(), ux_execute_call(), ux_fetch(), ux_get_attr_type_str(), ux_get_class_num_objs(), ux_get_generated_keys(), ux_get_generated_keys_client_insert(), ux_get_generated_keys_server_insert(), ux_get_last_insert_id(), ux_get_parameter_info(), ux_get_query_info(), ux_get_row_count(), ux_lob_new(), ux_lob_read(), ux_lob_write(), ux_make_out_rs(), ux_next_result(), ux_oid_put(), ux_prepare(), ux_schema_info(), and ux_set_isolation_level().
#define ERROR_INFO_SET_FORCE | ( | ERR_CODE, | |
ERR_INDICATOR | |||
) | error_info_set_force(ERR_CODE, ERR_INDICATOR, __FILE__, __LINE__) |
Definition at line 51 of file cas_execute.h.
Referenced by set_host_variables(), ux_execute(), and ux_execute_all().
#define ERROR_INFO_SET_WITH_MSG | ( | ERR_CODE, | |
ERR_INDICATOR, | |||
ERR_MSG | |||
) | error_info_set_with_msg(ERR_CODE, ERR_INDICATOR, ERR_MSG, false, __FILE__, __LINE__) |
Definition at line 53 of file cas_execute.h.
Referenced by netval_to_dbval(), sch_exported_keys_or_cross_reference(), sch_imported_keys(), and ux_database_connect().
#define IS_ERROR_INFO_SET | ( | ) | is_error_info_set() |
Definition at line 48 of file cas_execute.h.
Referenced by fn_prepare_and_execute().
#define NET_BUF_ERR_SET | ( | NET_BUF | ) | err_msg_set(NET_BUF, __FILE__, __LINE__) |
Definition at line 55 of file cas_execute.h.
Referenced by fetch_call(), fn_check_cas(), fn_close_req_handle(), fn_collection(), fn_cursor(), fn_cursor_update(), fn_deprecated(), fn_end_tran(), fn_execute_internal(), fn_fetch(), fn_get_attr_type_str(), fn_get_class_num_objs(), fn_get_db_parameter(), fn_get_db_version(), fn_get_generated_keys(), fn_get_query_info(), fn_lob_new(), fn_lob_read(), fn_lob_write(), fn_make_out_rs(), fn_next_result(), fn_not_supported(), fn_oid(), fn_oid_get(), fn_oid_put(), fn_parameter_info(), fn_prepare_internal(), fn_savepoint(), fn_schema_info(), fn_set_cas_change_mode(), fn_set_db_parameter(), fn_xa_end_tran(), fn_xa_prepare(), fn_xa_recover(), ux_auto_commit(), ux_col_seq_drop(), ux_col_seq_insert(), ux_col_seq_put(), ux_col_set_add(), ux_col_set_drop(), ux_cursor(), ux_cursor_update(), ux_execute(), ux_execute_all(), ux_execute_array(), ux_execute_batch(), ux_execute_call(), ux_fetch(), ux_get_attr_type_str(), ux_get_class_num_objs(), ux_get_generated_keys(), ux_get_generated_keys_client_insert(), ux_get_generated_keys_server_insert(), ux_get_last_insert_id(), ux_get_parameter_info(), ux_get_query_info(), ux_get_row_count(), ux_lob_new(), ux_lob_read(), ux_lob_write(), ux_make_out_rs(), ux_next_result(), ux_oid_get(), ux_oid_put(), ux_prepare(), ux_schema_info(), and ux_set_isolation_level().
typedef struct t_fk_info_result T_FK_INFO_RESULT |
Definition at line 59 of file cas_execute.h.
void cas_log_error_handler | ( | unsigned int | eid | ) |
Definition at line 9712 of file cas_execute.c.
References eid, cas_error_log_handle_context_s::from, NULL, and cas_error_log_handle_context_s::to.
Referenced by cas_log_error_handler_begin().
char* cas_log_error_handler_asprint | ( | char * | buf, |
size_t | bufsz, | ||
bool | clear | ||
) |
Definition at line 9780 of file cas_execute.c.
References cas_error_log_handle_context_s::from, NULL, and cas_error_log_handle_context_s::to.
Referenced by get_error_log_eids().
void cas_log_error_handler_begin | ( | void | ) |
Definition at line 9733 of file cas_execute.c.
References cas_log_error_handler(), db_register_error_log_handler(), cas_error_log_handle_context_s::from, NULL, and cas_error_log_handle_context_s::to.
Referenced by cas_main(), and shard_cas_main().
void cas_log_error_handler_clear | ( | void | ) |
Definition at line 9767 of file cas_execute.c.
References cas_error_log_handle_context_s::from, NULL, and cas_error_log_handle_context_s::to.
Referenced by cas_main(), and shard_cas_main().
void cas_log_error_handler_end | ( | void | ) |
Definition at line 9756 of file cas_execute.c.
References db_register_error_log_handler(), and NULL.
Referenced by cas_main(), and shard_cas_main().
Definition at line 58 of file cas_error.c.
References ARG_FILE_LINE, as_info, CAS_ERROR_INDICATOR, cas_log_debug(), cas_log_write_and_end(), cas_set_db_connect_status(), DB_CONNECTION_STATUS_NOT_CONNECTED, DBMS_ERROR_INDICATOR, ER_BO_CONNECT_FAILED, ER_NET_SERVER_CRASHED, ER_OBJ_NO_CONNECT, ER_TM_SERVER_DOWN_UNILATERALLY_ABORTED, t_error_info::err_file, t_error_info::err_indicator, err_info, t_error_info::err_line, t_error_info::err_number, t_error_info::err_string, FALSE, net_buf_error_msg_set(), NULL, t_appl_server_info::reset_flag, set_server_aborted(), and TRUE.
void error_info_clear | ( | void | ) |
Definition at line 217 of file cas_error.c.
References CAS_NO_ERROR, t_error_info::err_file, ERR_FILE_LENGTH, t_error_info::err_indicator, err_info, t_error_info::err_line, ERR_MSG_LENGTH, t_error_info::err_number, t_error_info::err_string, and ERROR_INDICATOR_UNSET.
Referenced by cas_main(), and process_request().
int error_info_set | ( | int | err_number, |
int | err_indicator, | ||
const char * | file, | ||
int | line | ||
) |
Definition at line 146 of file cas_error.c.
References error_info_set_with_msg(), and NULL.
int error_info_set_force | ( | int | err_number, |
int | err_indicator, | ||
const char * | file, | ||
int | line | ||
) |
Definition at line 152 of file cas_error.c.
References error_info_set_with_msg(), and NULL.
int error_info_set_with_msg | ( | int | err_number, |
int | err_indicator, | ||
const char * | err_msg, | ||
bool | force, | ||
const char * | file, | ||
int | line | ||
) |
Definition at line 158 of file cas_error.c.
References ARG_FILE_LINE, assert, CAS_ERROR_INDICATOR, cas_log_debug(), db_error_string(), DBMS_ERROR_INDICATOR, er_errid(), t_error_info::err_file, ERR_FILE_LENGTH, t_error_info::err_indicator, err_info, t_error_info::err_line, ERR_MSG_LENGTH, t_error_info::err_number, t_error_info::err_string, ERROR_INDICATOR_UNSET, NO_ERROR, and NULL.
Referenced by error_info_set(), and error_info_set_force().
char get_set_domain | ( | DB_DOMAIN * | col, |
int * | precision, | ||
short * | scale, | ||
char * | db_type, | ||
char * | charset | ||
) |
Definition at line 3123 of file cas_execute.c.
References db_domain_codeset(), db_domain_next(), db_domain_precision(), db_domain_scale(), db_domain_set(), DB_TYPE_NULL, lang_charset(), TP_DOMAIN_TYPE, and ux_db_type_to_cas_type().
Referenced by class_attr_info(), dbval_to_net_buf(), fetch_method(), fn_collection(), get_attr_type(), oid_attr_info_set(), prepare_column_list_info_set(), ux_get_parameter_info(), and ux_make_out_rs().
int get_tuple_count | ( | T_SRV_HANDLE * | srv_handle | ) |
Definition at line 9834 of file cas_execute.c.
References t_srv_handle::q_result, and t_query_result::tuple_count.
Referenced by fn_execute_array(), and fn_execute_internal().
int is_error_info_set | ( | void | ) |
Definition at line 211 of file cas_error.c.
References t_error_info::err_indicator, err_info, and ERROR_INDICATOR_UNSET.
bool is_server_aborted | ( | void | ) |
Definition at line 234 of file cas_error.c.
References server_aborted.
Referenced by cas_main().
int make_bind_value | ( | int | num_bind, |
int | argc, | ||
void ** | argv, | ||
DB_VALUE ** | ret_val, | ||
T_NET_BUF * | net_buf, | ||
char | desired_type | ||
) |
Definition at line 3176 of file cas_execute.c.
References CAS_ER_NO_MORE_MEMORY, CAS_ER_NUM_BIND, CAS_ERROR_INDICATOR, db_value_clear(), ERROR_INFO_SET, FREE_MEM, i, MALLOC, netval_to_dbval(), and NULL.
Referenced by fn_collection(), ux_cursor_update(), ux_execute(), ux_execute_all(), ux_execute_array(), ux_execute_call(), and ux_oid_put().
void release_all_fk_info_results | ( | T_FK_INFO_RESULT * | fk_res | ) |
Definition at line 8460 of file cas_execute.c.
References t_fk_info_result::fk_name, t_fk_info_result::fkcolumn_name, t_fk_info_result::fktable_name, FREE_MEM, t_fk_info_result::next, NULL, t_fk_info_result::pk_name, t_fk_info_result::pkcolumn_name, and t_fk_info_result::pktable_name.
Referenced by add_fk_info_result(), sch_exported_keys_or_cross_reference(), sch_imported_keys(), and srv_handle_content_free().
void reset_optimization_level_as_saved | ( | void | ) |
Definition at line 9850 of file cas_execute.c.
References CHK_OPTIMIZATION_LEVEL_VALID, PRM_ID_OPTIMIZATION_LEVEL, prm_set_integer_value(), and saved_Optimization_level.
Referenced by fn_get_query_info(), and ux_execute().
void set_optimization_level | ( | int | level | ) |
Definition at line 9843 of file cas_execute.c.
References prm_get_integer_value(), PRM_ID_OPTIMIZATION_LEVEL, prm_set_integer_value(), and saved_Optimization_level.
Referenced by cas_log_query_info_init(), and ux_execute().
void set_server_aborted | ( | bool | is_aborted | ) |
Definition at line 228 of file cas_error.c.
References server_aborted.
Referenced by err_msg_set().
int ux_auto_commit | ( | T_NET_BUF * | CAS_FN_ARG_NET_BUF, |
T_REQ_INFO * | CAS_FN_ARG_REQ_INFO | ||
) |
Definition at line 9594 of file cas_execute.c.
References as_info, CAS_ER_INTERNAL, CAS_ERROR_INDICATOR, cas_log_end(), cas_log_write(), ERROR_INFO_SET, errors_in_transaction, FALSE, logddl_set_msg(), t_shm_appl_server::long_transaction_time, MAX_DIAG_DATA_VALUE, t_req_info::need_auto_commit, t_req_info::need_rollback, NET_BUF_ERR_SET, NULL, t_appl_server_info::num_long_transactions, query_start_time, query_timeout, shm_appl, SQL_LOG_MODE_ERROR, SQL_LOG_MODE_NONE, SQL_LOG_MODE_TIMEOUT, TRAN_AUTOCOMMIT, TRAN_AUTOROLLBACK, tran_start_time, tran_timeout, tran_was_latest_query_aborted(), tran_was_latest_query_committed(), TRUE, ut_check_timeout(), and ux_end_tran().
Referenced by process_request().
void ux_call_info_cp_param_mode | ( | T_SRV_HANDLE * | srv_handle, |
char * | param_mode, | ||
int | num_param | ||
) |
Definition at line 3645 of file cas_execute.c.
References NULL, t_prepare_call_info::num_args, t_prepare_call_info::param_mode, and t_srv_handle::prepare_call_info.
Referenced by fn_execute_internal().
int ux_check_connection | ( | void | ) |
Definition at line 406 of file cas_execute.c.
References ARG_FILE_LINE, as_info, cas_log_debug(), cas_log_write_and_end(), t_appl_server_info::cur_statement_pooling, database_name, database_passwd, database_user, db_ping_server(), dbname, dbpasswd, dbuser, MAX_HA_DBINFO_LENGTH, NULL, SRV_CON_DBPASSWD_SIZE, SRV_CON_DBUSER_SIZE, strncpy_bufsize, ux_database_connect(), ux_database_shutdown(), and ux_is_database_connected().
Referenced by fn_check_cas().
Definition at line 3421 of file cas_execute.c.
References CAS_ER_OBJECT, CAS_ERROR_INDICATOR, db_error_code(), db_is_instance(), DBMS_ERROR_INDICATOR, er_clear(), ERROR_INFO_SET, and NULL.
Referenced by fn_collection(), fn_oid(), netval_to_dbval(), ux_oid_get(), and ux_oid_put().
void ux_col_get | ( | DB_COLLECTION * | col, |
char | col_type, | ||
char | ele_type, | ||
DB_DOMAIN * | ele_domain, | ||
T_NET_BUF * | net_buf | ||
) |
Definition at line 2889 of file cas_execute.c.
References db_col_get(), db_col_size(), db_domain_codeset(), db_domain_precision(), db_domain_scale(), db_make_null(), db_value_clear(), dbval_to_net_buf(), i, net_buf_column_info_set(), net_buf_cp_byte(), net_buf_cp_int(), and NULL.
Referenced by fn_collection().
int ux_col_seq_drop | ( | DB_COLLECTION * | col, |
int | index, | ||
T_NET_BUF * | net_buf | ||
) |
Definition at line 2986 of file cas_execute.c.
References db_seq_drop(), DBMS_ERROR_INDICATOR, ERROR_INFO_SET, errors_in_transaction, net_buf_cp_int(), NET_BUF_ERR_SET, and NULL.
Referenced by fn_collection().
int ux_col_seq_insert | ( | DB_COLLECTION * | col, |
int | index, | ||
DB_VALUE * | ele_val, | ||
T_NET_BUF * | net_buf | ||
) |
Definition at line 3006 of file cas_execute.c.
References db_seq_insert(), DBMS_ERROR_INDICATOR, ERROR_INFO_SET, errors_in_transaction, net_buf_cp_int(), NET_BUF_ERR_SET, and NULL.
Referenced by fn_collection().
int ux_col_seq_put | ( | DB_COLLECTION * | col, |
int | index, | ||
DB_VALUE * | ele_val, | ||
T_NET_BUF * | net_buf | ||
) |
Definition at line 3026 of file cas_execute.c.
References db_seq_put(), DBMS_ERROR_INDICATOR, ERROR_INFO_SET, errors_in_transaction, net_buf_cp_int(), NET_BUF_ERR_SET, and NULL.
Referenced by fn_collection().
int ux_col_set_add | ( | DB_COLLECTION * | col, |
DB_VALUE * | ele_val, | ||
T_NET_BUF * | net_buf | ||
) |
Definition at line 2966 of file cas_execute.c.
References db_set_add(), DBMS_ERROR_INDICATOR, ERROR_INFO_SET, errors_in_transaction, net_buf_cp_int(), NET_BUF_ERR_SET, and NULL.
Referenced by fn_collection().
int ux_col_set_drop | ( | DB_COLLECTION * | col, |
DB_VALUE * | ele_val, | ||
T_NET_BUF * | net_buf | ||
) |
Definition at line 2946 of file cas_execute.c.
References db_set_drop(), DBMS_ERROR_INDICATOR, ERROR_INFO_SET, errors_in_transaction, net_buf_cp_int(), NET_BUF_ERR_SET, and NULL.
Referenced by fn_collection().
void ux_col_size | ( | DB_COLLECTION * | col, |
T_NET_BUF * | net_buf | ||
) |
Definition at line 2927 of file cas_execute.c.
References db_col_size(), net_buf_cp_int(), and NULL.
Referenced by fn_collection().
int ux_cursor | ( | int | srv_h_id, |
int | offset, | ||
int | origin, | ||
T_NET_BUF * | net_buf | ||
) |
Definition at line 2674 of file cas_execute.c.
References CAS_ER_SRV_HANDLE, CAS_ERROR_INDICATOR, cubregex::count(), t_srv_handle::cur_result, ERROR_INFO_SET, errors_in_transaction, FREE_MEM, hm_find_srv_handle(), if(), net_buf_cp_int(), NET_BUF_ERR_SET, NULL, t_srv_handle::schema_type, and t_query_result::tuple_count.
Referenced by fn_cursor().
void ux_cursor_close | ( | T_SRV_HANDLE * | srv_handle | ) |
Definition at line 2805 of file cas_execute.c.
References as_info, t_srv_handle::cur_result_index, t_query_result::is_holdable, NULL, t_appl_server_info::num_holdable_results, t_srv_handle::q_result, t_query_result::result, and ux_free_result().
Referenced by fetch_result(), and fn_cursor_close().
int ux_cursor_update | ( | T_SRV_HANDLE * | srv_handle, |
int | cursor_pos, | ||
int | argc, | ||
void ** | argv, | ||
T_NET_BUF * | net_buf | ||
) |
Definition at line 2710 of file cas_execute.c.
References t_col_update_info::attr_name, CAS_ER_SRV_HANDLE, CAS_ERROR_INDICATOR, t_query_result::col_updatable, t_query_result::col_update_info, t_srv_handle::cur_result, DB_CURSOR_SUCCESS, db_get_object(), db_put(), db_query_get_tuple_oid(), db_query_seek_tuple(), db_value_clear(), DBMS_ERROR_INDICATOR, ERROR_INFO_SET, errors_in_transaction, FALSE, FREE_MEM, get_attr_type(), make_bind_value(), net_arg_get_int(), net_buf_cp_int(), NET_BUF_ERR_SET, NULL, t_query_result::result, and t_srv_handle::schema_type.
Referenced by fn_cursor_update().
int ux_database_connect | ( | char * | db_name, |
char * | db_user, | ||
char * | db_passwd, | ||
char ** | db_err_msg | ||
) |
Definition at line 461 of file cas_execute.c.
References t_shm_appl_server::access_mode, ARG_FILE_LINE, as_info, au_login(), t_shm_appl_server::cache_user_info, CAS_ERROR_INDICATOR, cas_get_db_connect_status(), cas_log_debug(), t_shm_appl_server::connect_order, t_appl_server_info::database_host, t_appl_server_info::database_name, database_name, database_passwd, database_user, db_clear_host_connected(), DB_CLIENT_TYPE_BROKER, DB_CLIENT_TYPE_READ_ONLY_BROKER, DB_CLIENT_TYPE_RO_BROKER_REPLICA_ONLY, DB_CLIENT_TYPE_RW_BROKER_REPLICA_ONLY, DB_CLIENT_TYPE_SLAVE_ONLY_BROKER, DB_CLIENT_TYPE_SO_BROKER_REPLICA_ONLY, db_disable_trigger(), db_enable_trigger(), db_error_string(), db_find_or_create_session(), db_get_host_connected(), db_restart_ex(), db_set_connect_order(), db_set_max_num_delayed_hosts_lookup(), db_set_preferred_hosts(), DBMS_ERROR_INDICATOR, er_clear(), ERROR_INFO_SET, ERROR_INFO_SET_WITH_MSG, t_appl_server_info::force_reconnect, t_appl_server_info::last_connect_time, t_shm_appl_server::max_num_delayed_hosts_lookup, NULL, OFF, p, t_shm_appl_server::preferred_hosts, program_name, READ_ONLY_ACCESS_MODE, t_shm_appl_server::replica_only_flag, report_abnormal_host_status(), shm_appl, SLAVE_ONLY_ACCESS_MODE, strlen, t_shm_appl_server::trigger_action_flag, ux_database_connect(), ux_database_shutdown(), and ux_get_default_setting().
Referenced by cas_main(), process_request(), shard_cas_main(), ux_check_connection(), and ux_database_connect().
int ux_database_reconnect | ( | void | ) |
void ux_database_shutdown | ( | void | ) |
Definition at line 710 of file cas_execute.c.
References ARG_FILE_LINE, as_info, cas_default_isolation_level, cas_default_lock_timeout, cas_log_debug(), t_appl_server_info::database_host, t_appl_server_info::database_name, database_name, t_appl_server_info::database_passwd, database_passwd, t_appl_server_info::database_user, database_user, db_shutdown(), and t_appl_server_info::last_connect_time.
Referenced by cas_free(), cas_main(), restart_is_needed(), shard_cas_main(), ux_check_connection(), and ux_database_connect().
char ux_db_type_to_cas_type | ( | int | db_type | ) |
Definition at line 3458 of file cas_execute.c.
References cas_u_type, and DB_TYPE_LAST.
Referenced by dbval_to_net_buf(), fn_collection(), get_set_domain(), set_extended_cas_type(), ux_get_generated_keys_client_insert(), and ux_get_generated_keys_server_insert().
int ux_end_session | ( | void | ) |
Definition at line 1070 of file cas_execute.c.
References db_end_session().
Referenced by cas_main(), and shard_cas_main().
int ux_end_tran | ( | int | tran_type, |
bool | reset_con_status | ||
) |
Definition at line 984 of file cas_execute.c.
References ARG_FILE_LINE, as_info, assert_release, CAS_ER_INTERNAL, CAS_ERROR_INDICATOR, cas_get_db_connect_status(), cas_log_debug(), t_appl_server_info::con_status, CON_STATUS_IN_TRAN, CON_STATUS_OUT_TRAN, t_appl_server_info::cur_statement_pooling, db_abort_transaction(), db_commit_transaction(), DBMS_ERROR_INDICATOR, ERROR_INFO_SET, errors_in_transaction, hm_srv_handle_free_all(), hm_srv_handle_qresult_end_all(), need_reconnect_on_rctime(), t_appl_server_info::reset_flag, t_appl_server_info::transaction_start_time, TRUE, and unset_xa_prepare_flag().
Referenced by cas_main(), fn_end_tran(), fn_xa_end_tran(), shard_cas_main(), and ux_auto_commit().
int ux_execute | ( | T_SRV_HANDLE * | srv_handle, |
char | flag, | ||
int | max_col_size, | ||
int | max_row, | ||
int | argc, | ||
void ** | argv, | ||
T_NET_BUF * | , | ||
T_REQ_INFO * | req_info, | ||
CACHE_TIME * | clt_cache_time, | ||
int * | clt_cache_reusable | ||
) |
Definition at line 1126 of file cas_execute.c.
References as_info, t_srv_handle::auto_commit_mode, CAS_ER_STMT_POOLING, CAS_ERROR_INDICATOR, cas_log_query_info_init(), cas_log_query_plan_file(), t_req_info::client_version, CUBRID_STMT_SELECT, t_srv_handle::cur_result, t_srv_handle::cur_result_index, t_appl_server_info::cur_sql_log2, db_check_single_query(), db_compile_statement(), DB_CURSOR_END, db_error_code(), db_execute_and_keep_statement(), db_get_cacheinfo(), db_get_statement_type(), db_is_client_cache_reusable(), db_open_buffer(), db_query_seek_tuple(), db_query_set_copy_tplvalue(), db_query_tuple_count(), db_session_set_holdable(), db_session_set_return_generated_keys(), db_session_set_xasl_cache_pinned(), db_set_client_cache_time(), db_set_statement_auto_commit(), DB_TYPE_NULL, db_value_clear(), DBMS_ERROR_INDICATOR, do_commit_after_execute(), DOES_CLIENT_UNDERSTAND_THE_PROTOCOL, ER_HEAP_UNKNOWN_OBJECT, ER_QPROC_INVALID_XASLNODE, ERROR_INFO_SET, ERROR_INFO_SET_FORCE, errors_in_transaction, execute_info_set(), FALSE, FREE_MEM, get_client_result_cache_lifetime(), t_srv_handle::has_result_set, has_stmt_result_set(), hm_qresult_end(), hm_session_free(), i, t_srv_handle::id, if(), t_srv_handle::is_from_current_transaction, t_query_result::is_holdable, t_srv_handle::is_holdable, t_srv_handle::is_pooled, t_srv_handle::is_prepared, make_bind_value(), t_srv_handle::max_col_size, t_srv_handle::max_row, t_req_info::need_auto_commit, net_buf_cp_byte(), net_buf_cp_int(), NET_BUF_ERR_SET, NO_ERROR, NULL, t_appl_server_info::num_holdable_results, t_srv_handle::num_markers, t_srv_handle::num_q_result, prepare_column_list_info_set(), t_srv_handle::prepare_flag, PROTOCOL_V2, PROTOCOL_V5, t_srv_handle::q_result, t_srv_handle::query_info_flag, reset_optimization_level_as_saved(), t_query_result::result, t_srv_handle::session, set_host_variables(), set_optimization_level(), shm_shard_id, SQL_LOG2_EXEC_APPEND, SQL_LOG2_EXEC_BEGIN, SQL_LOG2_EXEC_END, t_srv_handle::sql_stmt, t_query_result::stmt_id, t_query_result::stmt_type, TRAN_AUTOCOMMIT, TRAN_AUTOROLLBACK, TRUE, t_query_result::tuple_count, update_query_execution_count(), t_srv_handle::use_plan_cache, and t_srv_handle::use_query_cache.
Referenced by fn_execute_internal().
int ux_execute_all | ( | T_SRV_HANDLE * | srv_handle, |
char | flag, | ||
int | max_col_size, | ||
int | max_row, | ||
int | argc, | ||
void ** | argv, | ||
T_NET_BUF * | net_buf, | ||
T_REQ_INFO * | req_info, | ||
CACHE_TIME * | clt_cache_time, | ||
int * | clt_cache_reusable | ||
) |
Definition at line 1437 of file cas_execute.c.
References as_info, t_srv_handle::auto_commit_mode, BROKER_PATH_MAX, CAS_ER_NO_MORE_MEMORY, CAS_ER_STMT_POOLING, CAS_ERROR_INDICATOR, t_req_info::client_version, CUBRID_STMT_SELECT, t_srv_handle::cur_result, t_srv_handle::cur_result_index, t_appl_server_info::cur_sql_log2, db_abort_to_savepoint(), db_check_single_query(), db_compile_statement(), DB_CURSOR_END, db_error_code(), db_execute_and_keep_statement(), db_get_cacheinfo(), db_get_hostvars(), db_get_statement_type(), db_is_client_cache_reusable(), db_open_buffer(), db_query_end(), db_query_seek_tuple(), db_query_set_copy_tplvalue(), db_query_tuple_count(), db_rewind_statement(), db_savepoint_transaction(), db_session_set_holdable(), db_session_set_return_generated_keys(), db_session_set_xasl_cache_pinned(), db_set_client_cache_time(), db_set_statement_auto_commit(), db_statement_count(), DB_TYPE_NULL, db_value_clear(), DBMS_ERROR_INDICATOR, do_commit_after_execute(), DOES_CLIENT_UNDERSTAND_THE_PROTOCOL, ER_HEAP_UNKNOWN_OBJECT, ER_QPROC_INVALID_XASLNODE, ERROR_INFO_SET, ERROR_INFO_SET_FORCE, errors_in_transaction, execute_info_set(), FALSE, FREE_MEM, get_client_result_cache_lifetime(), t_srv_handle::has_result_set, has_stmt_result_set(), hm_qresult_clear(), hm_qresult_end(), hm_session_free(), i, if(), t_srv_handle::is_from_current_transaction, t_query_result::is_holdable, t_srv_handle::is_holdable, t_srv_handle::is_pooled, t_srv_handle::is_prepared, jsp_set_prepare_call(), jsp_unset_prepare_call(), make_bind_value(), t_srv_handle::max_col_size, t_srv_handle::max_row, t_req_info::need_auto_commit, net_buf_cp_byte(), net_buf_cp_int(), NET_BUF_ERR_SET, NO_ERROR, NULL, t_appl_server_info::num_holdable_results, t_srv_handle::num_markers, t_srv_handle::num_q_result, prepare_column_list_info_set(), t_srv_handle::prepare_flag, PROTOCOL_V2, PROTOCOL_V5, t_srv_handle::q_result, t_srv_handle::query_info_flag, REALLOC, t_query_result::result, t_srv_handle::session, set_host_variables(), shm_shard_id, SQL_LOG2_EXEC_BEGIN, SQL_LOG2_EXEC_END, t_srv_handle::sql_stmt, t_query_result::stmt_id, t_query_result::stmt_type, TRAN_AUTOCOMMIT, TRAN_AUTOROLLBACK, TRUE, t_query_result::tuple_count, update_query_execution_count(), t_srv_handle::use_plan_cache, and t_srv_handle::use_query_cache.
Referenced by fn_execute_internal().
int ux_execute_array | ( | T_SRV_HANDLE * | srv_h_id, |
int | argc, | ||
void ** | argv, | ||
T_NET_BUF * | net_buf, | ||
T_REQ_INFO * | req_info | ||
) |
Definition at line 2200 of file cas_execute.c.
References as_info, t_srv_handle::auto_commit_mode, CAS_ER_SRV_HANDLE, CAS_ERROR_INDICATOR, t_req_info::client_version, CUBRID_STMT_INSERT, t_appl_server_info::cur_sql_log2, db_abort_transaction(), db_close_session(), db_commit_transaction(), db_compile_statement(), db_error_code(), db_error_string(), db_execute_and_keep_statement(), db_get_cacheinfo(), db_get_object(), db_get_statement_type(), db_make_null(), db_open_buffer(), db_query_end(), db_query_get_tuple_value(), db_query_set_copy_tplvalue(), db_session_set_xasl_cache_pinned(), db_set_statement_auto_commit(), DB_TYPE_NULL, db_value_clear(), DBMS_ERROR_INDICATOR, dbobj_to_casobj(), DOES_CLIENT_UNDERSTAND_THE_PROTOCOL, ER_INTERRUPTED, ER_IS_ABORTED_DUE_TO_DEADLOCK, ER_IS_SERVER_DOWN_ERROR, ERROR_INFO_SET, errors_in_transaction, FALSE, FREE_MEM, hm_qresult_end(), hm_session_free(), i, t_srv_handle::is_prepared, make_bind_value(), net_buf_cp_int(), net_buf_cp_object(), net_buf_cp_str(), NET_BUF_ERR_SET, net_buf_overwrite_int(), NO_ERROR, NULL, t_srv_handle::num_markers, t_srv_handle::prepare_flag, PROTOCOL_V3, PROTOCOL_V5, t_srv_handle::q_result, t_srv_handle::schema_type, t_srv_handle::session, set_host_variables(), shm_shard_id, SQL_LOG2_EXEC_BEGIN, SQL_LOG2_EXEC_END, t_srv_handle::sql_stmt, t_query_result::stmt_id, strlen, TRUE, update_query_execution_count(), t_srv_handle::use_plan_cache, and t_srv_handle::use_query_cache.
Referenced by fn_execute_array().
int ux_execute_batch | ( | int | argc, |
void ** | argv, | ||
T_NET_BUF * | net_buf, | ||
T_REQ_INFO * | req_info, | ||
char | auto_commit_mode | ||
) |
Definition at line 2010 of file cas_execute.c.
References argc, as_info, cas_log_write2(), cas_log_write2_nonl(), cas_log_write_nonl(), cas_log_write_query_string_nonl(), t_req_info::client_version, CUBRID_MAX_STMT_TYPE, CUBRID_STMT_INSERT, t_appl_server_info::cur_sql_log2, db_abort_transaction(), db_close_session(), db_commit_transaction(), db_compile_statement(), db_error_code(), db_error_string(), db_execute_statement(), db_get_cacheinfo(), db_get_object(), db_get_statement_type(), db_make_null(), db_open_buffer(), db_query_end(), db_query_get_tuple_value(), db_query_set_copy_tplvalue(), db_set_statement_auto_commit(), db_value_clear(), DBMS_ERROR_INDICATOR, dbobj_to_casobj(), DOES_CLIENT_UNDERSTAND_THE_PROTOCOL, ER_INTERRUPTED, ER_IS_ABORTED_DUE_TO_DEADLOCK, ER_IS_SERVER_DOWN_ERROR, ERROR_INFO_SET, errors_in_transaction, FALSE, LOGDDL_RUN_EXECUTE_BATCH_FUNC, logddl_set_err_code(), logddl_set_execute_type(), logddl_set_msg(), logddl_set_sql_text(), logddl_set_stmt_type(), logddl_write(), logddl_write_end(), net_arg_get_str(), net_buf_cp_byte(), net_buf_cp_int(), net_buf_cp_object(), net_buf_cp_str(), NET_BUF_ERR_SET, net_buf_overwrite_int(), NO_ERROR, NULL, PROTOCOL_V3, PROTOCOL_V5, shm_shard_id, SQL_LOG2_COMPILE_BEGIN, SQL_LOG2_EXEC_BEGIN, SQL_LOG2_EXEC_END, strlen, TRUE, and update_query_execution_count().
Referenced by fn_execute_batch().
int ux_execute_call | ( | T_SRV_HANDLE * | srv_handle, |
char | flag, | ||
int | max_col_size, | ||
int | max_row, | ||
int | argc, | ||
void ** | argv, | ||
T_NET_BUF * | net_buf, | ||
T_REQ_INFO * | req_info, | ||
CACHE_TIME * | clt_cache_time, | ||
int * | clt_cache_reusable | ||
) |
Definition at line 1772 of file cas_execute.c.
References as_info, t_req_info::client_version, t_srv_handle::cur_result, t_srv_handle::cur_result_index, db_check_single_query(), db_execute_and_keep_statement(), db_get_hostvars(), db_get_statement_type(), db_query_get_tuple_value(), db_query_set_copy_tplvalue(), DB_TYPE_NULL, db_value_clear(), DBMS_ERROR_INDICATOR, t_prepare_call_info::dbval_args, DOES_CLIENT_UNDERSTAND_THE_PROTOCOL, ERROR_INFO_SET, execute_info_set(), FALSE, FREE_MEM, get_client_result_cache_lifetime(), t_srv_handle::has_result_set, hm_qresult_end(), i, if(), t_prepare_call_info::is_first_out, t_query_result::is_holdable, t_srv_handle::is_holdable, jsp_set_prepare_call(), jsp_unset_prepare_call(), make_bind_value(), t_srv_handle::max_col_size, t_srv_handle::max_row, net_buf_cp_byte(), net_buf_cp_int(), NET_BUF_ERR_SET, NO_ERROR, NULL, t_prepare_call_info::num_args, t_appl_server_info::num_holdable_results, t_srv_handle::num_markers, t_srv_handle::num_q_result, t_srv_handle::prepare_call_info, prepare_column_list_info_set(), t_srv_handle::prepare_flag, PROTOCOL_V2, PROTOCOL_V5, t_srv_handle::q_result, t_srv_handle::query_info_flag, t_query_result::result, t_srv_handle::session, set_host_variables(), shm_shard_id, t_query_result::stmt_id, t_query_result::stmt_type, t_query_result::tuple_count, and update_query_execution_count().
Referenced by fn_execute_internal().
int ux_fetch | ( | T_SRV_HANDLE * | srv_handle, |
int | cursor_pos, | ||
int | fetch_count, | ||
char | fetch_flag, | ||
int | result_set_index, | ||
T_NET_BUF * | net_buf, | ||
T_REQ_INFO * | req_info | ||
) |
Definition at line 2536 of file cas_execute.c.
References t_srv_handle::auto_commit_mode, CAS_ER_SCHEMA_TYPE, CAS_ER_SRV_HANDLE, CAS_ERROR_INDICATOR, cas_shard_flag, ERROR_INFO_SET, errors_in_transaction, fetch_call(), fetch_func, t_srv_handle::forward_only_cursor, t_req_info::need_auto_commit, net_buf_cp_int(), NET_BUF_ERR_SET, NULL, ON, t_srv_handle::prepare_flag, req_info, t_srv_handle::schema_type, TRAN_AUTOROLLBACK, and TRUE.
Referenced by fn_execute_internal(), and fn_fetch().
void ux_free_result | ( | void * | res | ) |
Definition at line 3452 of file cas_execute.c.
References db_query_end().
Referenced by hm_qresult_end(), and ux_cursor_close().
int ux_get_attr_type_str | ( | char * | class_name, |
char * | attr_name, | ||
T_NET_BUF * | net_buf, | ||
T_REQ_INFO * | |||
) |
Definition at line 3219 of file cas_execute.c.
References db_attribute_domain(), db_error_code(), db_find_class(), db_get_attribute(), DBMS_ERROR_INDICATOR, ERROR_INFO_SET, errors_in_transaction, FREE_MEM, get_domain_str(), net_buf_cp_byte(), net_buf_cp_int(), net_buf_cp_str(), NET_BUF_ERR_SET, NULL, and strlen.
Referenced by fn_get_attr_type_str().
int ux_get_class_num_objs | ( | char * | class_name, |
int | flag, | ||
T_NET_BUF * | net_buf | ||
) |
Definition at line 2853 of file cas_execute.c.
References db_error_code(), db_find_class(), db_get_class_num_objs_and_pages(), DBMS_ERROR_INDICATOR, ERROR_INFO_SET, errors_in_transaction, net_buf_cp_int(), NET_BUF_ERR_SET, and NULL.
Referenced by fn_get_class_num_objs().
int ux_get_db_version | ( | T_NET_BUF * | net_buf, |
T_REQ_INFO * | req_info | ||
) |
Definition at line 2833 of file cas_execute.c.
References net_buf_cp_byte(), net_buf_cp_int(), net_buf_cp_str(), NULL, p, rel_build_number(), and strlen.
Referenced by fn_get_db_version().
void ux_get_default_setting | ( | void | ) |
Definition at line 628 of file cas_execute.c.
References cas_db_sys_param, cas_default_ansi_quotes, cas_default_isolation_level, cas_default_lock_timeout, cas_default_no_backslash_escapes, db_get_system_parameters(), IS_VALID_ISOLATION_LEVEL, ux_get_system_parameter(), and ux_get_tran_setting().
Referenced by ux_database_connect().
int ux_get_generated_keys | ( | T_SRV_HANDLE * | srv_handle, |
T_NET_BUF * | net_buf | ||
) |
Definition at line 9130 of file cas_execute.c.
References CAS_NO_ERROR, DBMS_ERROR_INDICATOR, ERROR_INFO_SET, if(), NET_BUF_ERR_SET, NULL, t_srv_handle::q_result, t_query_result::result, T_CALL, T_SELECT, db_query_result::type, ux_get_generated_keys_client_insert(), and ux_get_generated_keys_server_insert().
Referenced by fn_get_generated_keys().
int ux_get_last_insert_id | ( | T_NET_BUF * | net_buf | ) |
Definition at line 1101 of file cas_execute.c.
References db_get_last_insert_id(), db_make_null(), db_value_clear(), DBMS_ERROR_INDICATOR, dbval_to_net_buf(), err, ERROR_INFO_SET, errors_in_transaction, net_buf_cp_int(), NET_BUF_ERR_SET, NO_ERROR, and NULL.
Referenced by fn_get_last_insert_id().
int ux_get_parameter_info | ( | int | srv_h_id, |
T_NET_BUF * | net_buf | ||
) |
Definition at line 3325 of file cas_execute.c.
References CAS_ER_SRV_HANDLE, CAS_ERROR_INDICATOR, db_domain_codeset(), db_domain_precision(), db_domain_scale(), db_get_input_markers(), db_marker_domain(), db_marker_next(), DB_TYPE_NULL, ERROR_INFO_SET, errors_in_transaction, get_set_domain(), hm_find_srv_handle(), i, net_buf_cp_byte(), net_buf_cp_cas_type_and_charset(), net_buf_cp_int(), net_buf_cp_short(), NET_BUF_ERR_SET, NULL, t_srv_handle::num_markers, t_srv_handle::q_result, t_srv_handle::schema_type, t_srv_handle::session, set_extended_cas_type(), t_query_result::stmt_id, TP_DOMAIN_TYPE, and TP_IS_SET_TYPE.
Referenced by fn_parameter_info().
int ux_get_query_info | ( | int | srv_h_id, |
char | info_type, | ||
T_NET_BUF * | net_buf | ||
) |
Definition at line 3272 of file cas_execute.c.
References CAS_ER_SRV_HANDLE, CAS_ERROR_INDICATOR, CAS_GET_QUERY_INFO_PLAN, cas_log_query_plan_file(), ERROR_INFO_SET, errors_in_transaction, FALSE, hm_find_srv_handle(), net_buf_cp_byte(), net_buf_cp_int(), net_buf_cp_str(), NET_BUF_ERR_SET, NULL, and t_srv_handle::query_info_flag.
Referenced by fn_get_query_info().
int ux_get_row_count | ( | T_NET_BUF * | net_buf | ) |
Definition at line 1076 of file cas_execute.c.
References db_get_row_count(), db_get_row_count_cache(), DB_ROW_COUNT_NOT_SET, DBMS_ERROR_INDICATOR, err, ERROR_INFO_SET, errors_in_transaction, net_buf_cp_int(), NET_BUF_ERR_SET, NO_ERROR, and NULL.
Referenced by fn_get_row_count().
SESSION_ID ux_get_session_id | ( | void | ) |
Definition at line 449 of file cas_execute.c.
References db_get_session_id().
Definition at line 654 of file cas_execute.c.
References db_get_system_parameters(), NO_ERROR, NULL, and p.
Referenced by ux_get_default_setting().
void ux_get_tran_setting | ( | int * | lock_wait, |
int * | isol_level | ||
) |
Definition at line 2476 of file cas_execute.c.
References tran_get_tran_settings().
Referenced by fn_get_db_parameter(), set_db_parameter(), ux_get_default_setting(), and ux_set_default_setting().
int ux_is_database_connected | ( | void | ) |
Definition at line 622 of file cas_execute.c.
References database_name.
Referenced by fn_end_tran(), process_request(), and ux_check_connection().
int ux_lob_new | ( | int | lob_type, |
T_NET_BUF * | net_buf | ||
) |
Definition at line 9864 of file cas_execute.c.
References ARG_FILE_LINE, cas_log_debug(), db_create_fbo(), db_get_elo(), DB_TYPE_BLOB, DB_TYPE_CLOB, db_value_clear(), dblob_to_caslob(), DBMS_ERROR_INDICATOR, ERROR_INFO_SET, errors_in_transaction, db_elo::locator, t_lob_handle::locator_size, net_buf_cp_int(), net_buf_cp_lob_handle(), NET_BUF_ERR_SET, NET_SIZE_INT, NET_SIZE_INT64, NULL, db_elo::size, and db_elo::type.
Referenced by fn_lob_new().
int ux_lob_write | ( | DB_VALUE * | lob_dbval, |
int64_t | offset, | ||
int | size, | ||
char * | data, | ||
T_NET_BUF * | net_buf | ||
) |
int ux_make_out_rs | ( | int | srv_h_id, |
T_NET_BUF * | net_buf, | ||
T_REQ_INFO * | req_info | ||
) |
Definition at line 9444 of file cas_execute.c.
References CAS_ER_NO_MORE_MEMORY, CAS_ER_SRV_HANDLE, CAS_ERROR_INDICATOR, t_priv_table::class_name, t_req_info::client_version, t_query_result::column_info, CUBRID_STMT_SELECT, t_srv_handle::cur_result, db_domain_codeset(), db_domain_precision(), db_domain_scale(), db_query_format_class_name(), db_query_format_domain(), db_query_format_is_non_null(), db_query_format_name(), db_query_format_next(), db_query_format_original_name(), ERROR_INFO_SET, FALSE, get_set_domain(), hm_find_srv_handle(), i, if(), IS_NULL_CAS_TYPE, MALLOC, t_srv_handle::max_row, t_shm_appl_server::max_string_length, net_buf_cp_byte(), net_buf_cp_int(), NET_BUF_ERR_SET, NULL, t_query_result::null_type_column, t_query_result::num_column, set_column_info(), set_extended_cas_type(), shm_appl, t_query_result::stmt_type, stripped_column_name, TP_DOMAIN_TYPE, TP_IS_SET_TYPE, and ux_use_sp_out().
Referenced by fn_make_out_rs().
int ux_next_result | ( | T_SRV_HANDLE * | srv_h_id, |
char | flag, | ||
T_NET_BUF * | net_buf, | ||
T_REQ_INFO * | req_info | ||
) |
Definition at line 1946 of file cas_execute.c.
References CAS_ER_NO_MORE_RESULT_SET, CAS_ER_SRV_HANDLE, CAS_ERROR_INDICATOR, check_auto_commit_after_getting_result(), t_req_info::client_version, t_srv_handle::cur_result, t_srv_handle::cur_result_index, db_query_end(), ERROR_INFO_SET, has_stmt_result_set(), t_req_info::need_auto_commit, net_buf_cp_byte(), net_buf_cp_int(), NET_BUF_ERR_SET, NULL, t_srv_handle::num_q_result, prepare_column_list_info_set(), t_srv_handle::prepare_flag, t_srv_handle::q_result, t_query_result::result, t_srv_handle::schema_type, t_srv_handle::session, t_query_result::stmt_type, TRAN_AUTOCOMMIT, and t_query_result::tuple_count.
Referenced by fn_next_result().
int ux_oid_get | ( | int | argc, |
void ** | argv, | ||
T_NET_BUF * | net_buf | ||
) |
Definition at line 2600 of file cas_execute.c.
References t_priv_table::class_name, db_get_class_name(), errors_in_transaction, FREE_MEM, get_attr_name(), get_attr_name_from_argv(), net_arg_get_dbobject(), net_buf_cp_byte(), net_buf_cp_int(), net_buf_cp_str(), NET_BUF_ERR_SET, NULL, oid_attr_info_set(), oid_data_set(), strlen, and ux_check_object().
Referenced by fn_oid_get().
int ux_oid_put | ( | int | argc, |
void ** | argv, | ||
T_NET_BUF * | net_buf | ||
) |
Definition at line 3046 of file cas_execute.c.
References db_error_code(), db_value_clear(), DBMS_ERROR_INDICATOR, dbt_abort_object(), dbt_edit_object(), dbt_finish_object(), dbt_put(), ERROR_INFO_SET, errors_in_transaction, FREE_MEM, get_attr_type(), make_bind_value(), net_arg_get_dbobject(), net_arg_get_str(), net_buf_cp_int(), NET_BUF_ERR_SET, NULL, and ux_check_object().
Referenced by fn_oid_put().
int ux_prepare | ( | char * | sql_stmt, |
int | flag, | ||
char | auto_commit_mode, | ||
T_NET_BUF * | ne_buf, | ||
T_REQ_INFO * | req_info, | ||
unsigned int | query_seq_num | ||
) |
Definition at line 729 of file cas_execute.c.
References ALLOC_COPY, t_srv_handle::auto_commit_mode, CAS_ER_HOLDABLE_NOT_ALLOWED, CAS_ER_INVALID_CALL_STMT, CAS_ER_NO_MORE_MEMORY, CAS_ERROR_INDICATOR, cas_log_query_info_init(), t_req_info::client_version, CUBRID_MAX_STMT_TYPE, CUBRID_STMT_CALL, t_srv_handle::cur_result, t_srv_handle::cur_result_index, db_close_session(), db_compile_statement(), db_error_code(), db_get_cacheinfo(), db_get_statement_type(), db_include_oid(), db_open_buffer(), DB_ROW_OIDS, db_session_set_xasl_cache_pinned(), DBMS_ERROR_INDICATOR, ER_PT_SEMANTIC, ERROR_INFO_SET, errors_in_transaction, FALSE, FREE_MEM, get_client_result_cache_lifetime(), get_num_markers(), get_stmt_type(), hm_new_srv_handle(), hm_qresult_clear(), hm_srv_handle_free(), t_srv_handle::id, t_srv_handle::is_holdable, t_srv_handle::is_prepared, t_srv_handle::is_updatable, logddl_set_stmt_type(), make_prepare_call_info(), t_req_info::need_auto_commit, net_buf_cp_byte(), net_buf_cp_int(), NET_BUF_ERR_SET, parser_node::node_type, NULL, t_srv_handle::num_markers, t_srv_handle::num_q_result, t_srv_handle::prepare_call_info, prepare_column_list_info_set(), t_srv_handle::prepare_flag, t_srv_handle::q_result, t_srv_handle::query_info_flag, t_srv_handle::schema_type, t_srv_handle::session, t_srv_handle::sql_stmt, db_session::statements, t_query_result::stmt_id, t_query_result::stmt_type, TRAN_AUTOROLLBACK, TRUE, t_srv_handle::use_plan_cache, t_srv_handle::use_query_cache, and ut_trim().
Referenced by fn_prepare_internal().
void ux_prepare_call_info_free | ( | T_PREPARE_CALL_INFO * | call_info | ) |
Definition at line 3626 of file cas_execute.c.
References t_prepare_call_info::dbval_args, t_prepare_call_info::dbval_ret, FREE_MEM, i, t_prepare_call_info::num_args, t_prepare_call_info::param_mode, and prepare_call_info_dbval_clear().
Referenced by srv_handle_content_free().
int ux_schema_info | ( | int | schema_type, |
char * | arg1, | ||
char * | arg2, | ||
char | flag, | ||
T_NET_BUF * | net_buf, | ||
T_REQ_INFO * | req_info, | ||
unsigned int | query_seq_num | ||
) |
Definition at line 3506 of file cas_execute.c.
References CAS_ER_SCHEMA_TYPE, CAS_ERROR_INDICATOR, t_req_info::client_version, t_srv_handle::cur_result, t_srv_handle::cursor_pos, ERROR_INFO_SET, errors_in_transaction, hm_new_srv_handle(), hm_srv_handle_free(), net_buf_cp_int(), NET_BUF_ERR_SET, NULL, sch_attr_info(), sch_attr_priv(), sch_class_info(), sch_class_priv(), sch_constraint(), sch_direct_super_class(), sch_exported_keys_or_cross_reference(), sch_imported_keys(), sch_methfile_info(), sch_method_info(), sch_primary_key(), sch_queryspec(), sch_superclass(), sch_trigger(), t_srv_handle::schema_type, and t_srv_handle::session.
Referenced by fn_schema_info().
void ux_set_cas_change_mode | ( | int | mode, |
T_NET_BUF * | net_buf | ||
) |
Definition at line 2519 of file cas_execute.c.
References as_info, t_appl_server_info::cas_change_mode, CAS_CHANGE_MODE_UNKNOWN, mode, net_buf_cp_int(), and NULL.
Referenced by fn_set_cas_change_mode().
void ux_set_default_setting | ( | void | ) |
Definition at line 686 of file cas_execute.c.
References cas_db_sys_param, cas_default_isolation_level, cas_default_lock_timeout, db_set_system_parameters(), NULL, ux_get_tran_setting(), ux_set_isolation_level(), and ux_set_lock_timeout().
Referenced by cas_main(), process_request(), and shard_cas_main().
int ux_set_isolation_level | ( | int | isol_level, |
T_NET_BUF * | net_buf | ||
) |
Definition at line 2496 of file cas_execute.c.
References db_set_isolation(), DBMS_ERROR_INDICATOR, ERROR_INFO_SET, errors_in_transaction, and NET_BUF_ERR_SET.
Referenced by fn_set_db_parameter(), set_db_parameter(), and ux_set_default_setting().
void ux_set_lock_timeout | ( | int | lock_timeout | ) |
Definition at line 2513 of file cas_execute.c.
References tran_reset_wait_times().
Referenced by fn_set_db_parameter(), set_db_parameter(), and ux_set_default_setting().
void ux_set_session_id | ( | const SESSION_ID | session_id | ) |
Definition at line 455 of file cas_execute.c.
References db_set_session_id().
void ux_set_utype_for_datetimeltz | ( | char | u_type | ) |
Definition at line 3494 of file cas_execute.c.
References cas_u_type, and DB_TYPE_DATETIMELTZ.
Referenced by process_request().
void ux_set_utype_for_datetimetz | ( | char | u_type | ) |
Definition at line 3482 of file cas_execute.c.
References cas_u_type, and DB_TYPE_DATETIMETZ.
Referenced by process_request().
void ux_set_utype_for_enum | ( | char | u_type | ) |
Definition at line 3470 of file cas_execute.c.
References cas_u_type, and DB_TYPE_ENUMERATION.
Referenced by process_request().
void ux_set_utype_for_json | ( | char | u_type | ) |
Definition at line 3500 of file cas_execute.c.
References cas_u_type, and DB_TYPE_JSON.
Referenced by process_request().
void ux_set_utype_for_timestampltz | ( | char | u_type | ) |
Definition at line 3488 of file cas_execute.c.
References cas_u_type, and DB_TYPE_TIMESTAMPLTZ.
Referenced by process_request().
void ux_set_utype_for_timestamptz | ( | char | u_type | ) |
Definition at line 3476 of file cas_execute.c.
References cas_u_type, and DB_TYPE_TIMESTAMPTZ.
Referenced by process_request().