/*- * Copyright 2005-2007 Guram Dukashvili * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. */ //--------------------------------------------------------------------------- #include //--------------------------------------------------------------------------- namespace fbcpp { //--------------------------------------------------------------------------- extern const ISCErrorDesc iscErrors[] = { { "arith_except", 335544321L }, { "bad_dbkey", 335544322L }, { "bad_db_format", 335544323L }, { "bad_db_handle", 335544324L }, { "bad_dpb_content", 335544325L }, { "bad_dpb_form", 335544326L }, { "bad_req_handle", 335544327L }, { "bad_segstr_handle", 335544328L }, { "bad_segstr_id", 335544329L }, { "bad_tpb_content", 335544330L }, { "bad_tpb_form", 335544331L }, { "bad_trans_handle", 335544332L }, { "bug_check", 335544333L }, { "convert_error", 335544334L }, { "db_corrupt", 335544335L }, { "deadlock", 335544336L }, { "excess_trans", 335544337L }, { "from_no_match", 335544338L }, { "infinap", 335544339L }, { "infona", 335544340L }, { "infunk", 335544341L }, { "integ_fail", 335544342L }, { "invalid_blr", 335544343L }, { "io_error", 335544344L }, { "lock_conflict", 335544345L }, { "metadata_corrupt", 335544346L }, { "not_valid", 335544347L }, { "no_cur_rec", 335544348L }, { "no_dup", 335544349L }, { "no_finish", 335544350L }, { "no_meta_update", 335544351L }, { "no_priv", 335544352L }, { "no_recon", 335544353L }, { "no_record", 335544354L }, { "no_segstr_close", 335544355L }, { "obsolete_metadata", 335544356L }, { "open_trans", 335544357L }, { "port_len", 335544358L }, { "read_only_field", 335544359L }, { "read_only_rel", 335544360L }, { "read_only_trans", 335544361L }, { "read_only_view", 335544362L }, { "req_no_trans", 335544363L }, { "req_sync", 335544364L }, { "req_wrong_db", 335544365L }, { "segment", 335544366L }, { "segstr_eof", 335544367L }, { "segstr_no_op", 335544368L }, { "segstr_no_read", 335544369L }, { "segstr_no_trans", 335544370L }, { "segstr_no_write", 335544371L }, { "segstr_wrong_db", 335544372L }, { "sys_request", 335544373L }, { "stream_eof", 335544374L }, { "unavailable", 335544375L }, { "unres_rel", 335544376L }, { "uns_ext", 335544377L }, { "wish_list", 335544378L }, { "wrong_ods", 335544379L }, { "wronumarg", 335544380L }, { "imp_exc", 335544381L }, { "random", 335544382L }, { "fatal_conflict", 335544383L }, { "badblk", 335544384L }, { "invpoolcl", 335544385L }, { "nopoolids", 335544386L }, { "relbadblk", 335544387L }, { "blktoobig", 335544388L }, { "bufexh", 335544389L }, { "syntaxerr", 335544390L }, { "bufinuse", 335544391L }, { "bdbincon", 335544392L }, { "reqinuse", 335544393L }, { "badodsver", 335544394L }, { "relnotdef", 335544395L }, { "fldnotdef", 335544396L }, { "dirtypage", 335544397L }, { "waifortra", 335544398L }, { "doubleloc", 335544399L }, { "nodnotfnd", 335544400L }, { "dupnodfnd", 335544401L }, { "locnotmar", 335544402L }, { "badpagtyp", 335544403L }, { "corrupt", 335544404L }, { "badpage", 335544405L }, { "badindex", 335544406L }, { "dbbnotzer", 335544407L }, { "tranotzer", 335544408L }, { "trareqmis", 335544409L }, { "badhndcnt", 335544410L }, { "wrotpbver", 335544411L }, { "wroblrver", 335544412L }, { "wrodpbver", 335544413L }, { "blobnotsup", 335544414L }, { "badrelation", 335544415L }, { "nodetach", 335544416L }, { "notremote", 335544417L }, { "trainlim", 335544418L }, { "notinlim", 335544419L }, { "traoutsta", 335544420L }, { "connect_reject", 335544421L }, { "dbfile", 335544422L }, { "orphan", 335544423L }, { "no_lock_mgr", 335544424L }, { "ctxinuse", 335544425L }, { "ctxnotdef", 335544426L }, { "datnotsup", 335544427L }, { "badmsgnum", 335544428L }, { "badparnum", 335544429L }, { "virmemexh", 335544430L }, { "blocking_signal", 335544431L }, { "lockmanerr", 335544432L }, { "journerr", 335544433L }, { "keytoobig", 335544434L }, { "nullsegkey", 335544435L }, { "sqlerr", 335544436L }, { "wrodynver", 335544437L }, { "funnotdef", 335544438L }, { "funmismat", 335544439L }, { "bad_msg_vec", 335544440L }, { "bad_detach", 335544441L }, { "noargacc_read", 335544442L }, { "noargacc_write", 335544443L }, { "read_only", 335544444L }, { "ext_err", 335544445L }, { "non_updatable", 335544446L }, { "no_rollback", 335544447L }, { "bad_sec_info", 335544448L }, { "invalid_sec_info", 335544449L }, { "misc_interpreted", 335544450L }, { "update_conflict", 335544451L }, { "unlicensed", 335544452L }, { "obj_in_use", 335544453L }, { "nofilter", 335544454L }, { "shadow_accessed", 335544455L }, { "invalid_sdl", 335544456L }, { "out_of_bounds", 335544457L }, { "invalid_dimension", 335544458L }, { "rec_in_limbo", 335544459L }, { "shadow_missing", 335544460L }, { "cant_validate", 335544461L }, { "cant_start_journal", 335544462L }, { "gennotdef", 335544463L }, { "cant_start_logging", 335544464L }, { "bad_segstr_type", 335544465L }, { "foreign_key", 335544466L }, { "high_minor", 335544467L }, { "tra_state", 335544468L }, { "trans_invalid", 335544469L }, { "buf_invalid", 335544470L }, { "indexnotdefined", 335544471L }, { "login", 335544472L }, { "invalid_bookmark", 335544473L }, { "bad_lock_level", 335544474L }, { "relation_lock", 335544475L }, { "record_lock", 335544476L }, { "max_idx", 335544477L }, { "jrn_enable", 335544478L }, { "old_failure", 335544479L }, { "old_in_progress", 335544480L }, { "old_no_space", 335544481L }, { "no_wal_no_jrn", 335544482L }, { "num_old_files", 335544483L }, { "wal_file_open", 335544484L }, { "bad_stmt_handle", 335544485L }, { "wal_failure", 335544486L }, { "walw_err", 335544487L }, { "logh_small", 335544488L }, { "logh_inv_version", 335544489L }, { "logh_open_flag", 335544490L }, { "logh_open_flag2", 335544491L }, { "logh_diff_dbname", 335544492L }, { "logf_unexpected_eof", 335544493L }, { "logr_incomplete", 335544494L }, { "logr_header_small", 335544495L }, { "logb_small", 335544496L }, { "wal_illegal_attach", 335544497L }, { "wal_invalid_wpb", 335544498L }, { "wal_err_rollover", 335544499L }, { "no_wal", 335544500L }, { "drop_wal", 335544501L }, { "stream_not_defined", 335544502L }, { "wal_subsys_error", 335544503L }, { "wal_subsys_corrupt", 335544504L }, { "no_archive", 335544505L }, { "shutinprog", 335544506L }, { "range_in_use", 335544507L }, { "range_not_found", 335544508L }, { "charset_not_found", 335544509L }, { "lock_timeout", 335544510L }, { "prcnotdef", 335544511L }, { "prcmismat", 335544512L }, { "wal_bugcheck", 335544513L }, { "wal_cant_expand", 335544514L }, { "codnotdef", 335544515L }, { "xcpnotdef", 335544516L }, { "except", 335544517L }, { "cache_restart", 335544518L }, { "bad_lock_handle", 335544519L }, { "jrn_present", 335544520L }, { "wal_err_rollover2", 335544521L }, { "wal_err_logwrite", 335544522L }, { "wal_err_jrn_comm", 335544523L }, { "wal_err_expansion", 335544524L }, { "wal_err_setup", 335544525L }, { "wal_err_ww_sync", 335544526L }, { "wal_err_ww_start", 335544527L }, { "shutdown", 335544528L }, { "existing_priv_mod", 335544529L }, { "primary_key_ref", 335544530L }, { "primary_key_notnull", 335544531L }, { "ref_cnstrnt_notfound", 335544532L }, { "foreign_key_notfound", 335544533L }, { "ref_cnstrnt_update", 335544534L }, { "check_cnstrnt_update", 335544535L }, { "check_cnstrnt_del", 335544536L }, { "integ_index_seg_del", 335544537L }, { "integ_index_seg_mod", 335544538L }, { "integ_index_del", 335544539L }, { "integ_index_mod", 335544540L }, { "check_trig_del", 335544541L }, { "check_trig_update", 335544542L }, { "cnstrnt_fld_del", 335544543L }, { "cnstrnt_fld_rename", 335544544L }, { "rel_cnstrnt_update", 335544545L }, { "constaint_on_view", 335544546L }, { "invld_cnstrnt_type", 335544547L }, { "primary_key_exists", 335544548L }, { "systrig_update", 335544549L }, { "not_rel_owner", 335544550L }, { "grant_obj_notfound", 335544551L }, { "grant_fld_notfound", 335544552L }, { "grant_nopriv", 335544553L }, { "nonsql_security_rel", 335544554L }, { "nonsql_security_fld", 335544555L }, { "wal_cache_err", 335544556L }, { "shutfail", 335544557L }, { "check_constraint", 335544558L }, { "bad_svc_handle", 335544559L }, { "shutwarn", 335544560L }, { "wrospbver", 335544561L }, { "bad_spb_form", 335544562L }, { "svcnotdef", 335544563L }, { "no_jrn", 335544564L }, { "transliteration_failed", 335544565L }, { "start_cm_for_wal", 335544566L }, { "wal_ovflow_log_required", 335544567L }, { "text_subtype", 335544568L }, { "dsql_error", 335544569L }, { "dsql_command_err", 335544570L }, { "dsql_constant_err", 335544571L }, { "dsql_cursor_err", 335544572L }, { "dsql_datatype_err", 335544573L }, { "dsql_decl_err", 335544574L }, { "dsql_cursor_update_err", 335544575L }, { "dsql_cursor_open_err", 335544576L }, { "dsql_cursor_close_err", 335544577L }, { "dsql_field_err", 335544578L }, { "dsql_internal_err", 335544579L }, { "dsql_relation_err", 335544580L }, { "dsql_procedure_err", 335544581L }, { "dsql_request_err", 335544582L }, { "dsql_sqlda_err", 335544583L }, { "dsql_var_count_err", 335544584L }, { "dsql_stmt_handle", 335544585L }, { "dsql_function_err", 335544586L }, { "dsql_blob_err", 335544587L }, { "collation_not_found", 335544588L }, { "collation_not_for_charset", 335544589L }, { "dsql_dup_option", 335544590L }, { "dsql_tran_err", 335544591L }, { "dsql_invalid_array", 335544592L }, { "dsql_max_arr_dim_exceeded", 335544593L }, { "dsql_arr_range_error", 335544594L }, { "dsql_trigger_err", 335544595L }, { "dsql_subselect_err", 335544596L }, { "dsql_crdb_prepare_err", 335544597L }, { "specify_field_err", 335544598L }, { "num_field_err", 335544599L }, { "col_name_err", 335544600L }, { "where_err", 335544601L }, { "table_view_err", 335544602L }, { "distinct_err", 335544603L }, { "key_field_count_err", 335544604L }, { "subquery_err", 335544605L }, { "expression_eval_err", 335544606L }, { "node_err", 335544607L }, { "command_end_err", 335544608L }, { "index_name", 335544609L }, { "exception_name", 335544610L }, { "field_name", 335544611L }, { "token_err", 335544612L }, { "union_err", 335544613L }, { "dsql_construct_err", 335544614L }, { "field_aggregate_err", 335544615L }, { "field_ref_err", 335544616L }, { "order_by_err", 335544617L }, { "return_mode_err", 335544618L }, { "extern_func_err", 335544619L }, { "alias_conflict_err", 335544620L }, { "procedure_conflict_error", 335544621L }, { "relation_conflict_err", 335544622L }, { "dsql_domain_err", 335544623L }, { "idx_seg_err", 335544624L }, { "node_name_err", 335544625L }, { "table_name", 335544626L }, { "proc_name", 335544627L }, { "idx_create_err", 335544628L }, { "wal_shadow_err", 335544629L }, { "dependency", 335544630L }, { "idx_key_err", 335544631L }, { "dsql_file_length_err", 335544632L }, { "dsql_shadow_number_err", 335544633L }, { "dsql_token_unk_err", 335544634L }, { "dsql_no_relation_alias", 335544635L }, { "indexname", 335544636L }, { "no_stream_plan", 335544637L }, { "stream_twice", 335544638L }, { "stream_not_found", 335544639L }, { "collation_requires_text", 335544640L }, { "dsql_domain_not_found", 335544641L }, { "index_unused", 335544642L }, { "dsql_self_join", 335544643L }, { "stream_bof", 335544644L }, { "stream_crack", 335544645L }, { "db_or_file_exists", 335544646L }, { "invalid_operator", 335544647L }, { "conn_lost", 335544648L }, { "bad_checksum", 335544649L }, { "page_type_err", 335544650L }, { "ext_readonly_err", 335544651L }, { "sing_select_err", 335544652L }, { "psw_attach", 335544653L }, { "psw_start_trans", 335544654L }, { "invalid_direction", 335544655L }, { "dsql_var_conflict", 335544656L }, { "dsql_no_blob_array", 335544657L }, { "dsql_base_table", 335544658L }, { "duplicate_base_table", 335544659L }, { "view_alias", 335544660L }, { "index_root_page_full", 335544661L }, { "dsql_blob_type_unknown", 335544662L }, { "req_max_clones_exceeded", 335544663L }, { "dsql_duplicate_spec", 335544664L }, { "unique_key_violation", 335544665L }, { "srvr_version_too_old", 335544666L }, { "drdb_completed_with_errs", 335544667L }, { "dsql_procedure_use_err", 335544668L }, { "dsql_count_mismatch", 335544669L }, { "blob_idx_err", 335544670L }, { "array_idx_err", 335544671L }, { "key_field_err", 335544672L }, { "no_delete", 335544673L }, { "del_last_field", 335544674L }, { "sort_err", 335544675L }, { "sort_mem_err", 335544676L }, { "version_err", 335544677L }, { "inval_key_posn", 335544678L }, { "no_segments_err", 335544679L }, { "crrp_data_err", 335544680L }, { "rec_size_err", 335544681L }, { "dsql_field_ref", 335544682L }, { "req_depth_exceeded", 335544683L }, { "no_field_access", 335544684L }, { "no_dbkey", 335544685L }, { "jrn_format_err", 335544686L }, { "jrn_file_full", 335544687L }, { "dsql_open_cursor_request", 335544688L }, { "ib_error", 335544689L }, { "cache_redef", 335544690L }, { "cache_too_small", 335544691L }, { "log_redef", 335544692L }, { "log_too_small", 335544693L }, { "partition_too_small", 335544694L }, { "partition_not_supp", 335544695L }, { "log_length_spec", 335544696L }, { "precision_err", 335544697L }, { "scale_nogt", 335544698L }, { "expec_short", 335544699L }, { "expec_long", 335544700L }, { "expec_ushort", 335544701L }, { "like_escape_invalid", 335544702L }, { "svcnoexe", 335544703L }, { "net_lookup_err", 335544704L }, { "service_unknown", 335544705L }, { "host_unknown", 335544706L }, { "grant_nopriv_on_base", 335544707L }, { "dyn_fld_ambiguous", 335544708L }, { "dsql_agg_ref_err", 335544709L }, { "complex_view", 335544710L }, { "unprepared_stmt", 335544711L }, { "expec_positive", 335544712L }, { "dsql_sqlda_value_err", 335544713L }, { "invalid_array_id", 335544714L }, { "extfile_uns_op", 335544715L }, { "svc_in_use", 335544716L }, { "err_stack_limit", 335544717L }, { "invalid_key", 335544718L }, { "net_init_error", 335544719L }, { "loadlib_failure", 335544720L }, { "network_error", 335544721L }, { "net_connect_err", 335544722L }, { "net_connect_listen_err", 335544723L }, { "net_event_connect_err", 335544724L }, { "net_event_listen_err", 335544725L }, { "net_read_err", 335544726L }, { "net_write_err", 335544727L }, { "integ_index_deactivate", 335544728L }, { "integ_deactivate_primary", 335544729L }, { "cse_not_supported", 335544730L }, { "tra_must_sweep", 335544731L }, { "unsupported_network_drive", 335544732L }, { "io_create_err", 335544733L }, { "io_open_err", 335544734L }, { "io_close_err", 335544735L }, { "io_read_err", 335544736L }, { "io_write_err", 335544737L }, { "io_delete_err", 335544738L }, { "io_access_err", 335544739L }, { "udf_exception", 335544740L }, { "lost_db_connection", 335544741L }, { "no_write_user_priv", 335544742L }, { "token_too_long", 335544743L }, { "max_att_exceeded", 335544744L }, { "login_same_as_role_name", 335544745L }, { "reftable_requires_pk", 335544746L }, { "usrname_too_long", 335544747L }, { "password_too_long", 335544748L }, { "usrname_required", 335544749L }, { "password_required", 335544750L }, { "bad_protocol", 335544751L }, { "dup_usrname_found", 335544752L }, { "usrname_not_found", 335544753L }, { "error_adding_sec_record", 335544754L }, { "error_modifying_sec_record", 335544755L }, { "error_deleting_sec_record", 335544756L }, { "error_updating_sec_db", 335544757L }, { "sort_rec_size_err", 335544758L }, { "bad_default_value", 335544759L }, { "invalid_clause", 335544760L }, { "too_many_handles", 335544761L }, { "optimizer_blk_exc", 335544762L }, { "invalid_string_constant", 335544763L }, { "transitional_date", 335544764L }, { "read_only_database", 335544765L }, { "must_be_dialect_2_and_up", 335544766L }, { "blob_filter_exception", 335544767L }, { "exception_access_violation", 335544768L }, { "exception_datatype_missalignment", 335544769L }, { "exception_array_bounds_exceeded", 335544770L }, { "exception_float_denormal_operand", 335544771L }, { "exception_float_divide_by_zero", 335544772L }, { "exception_float_inexact_result", 335544773L }, { "exception_float_invalid_operand", 335544774L }, { "exception_float_overflow", 335544775L }, { "exception_float_stack_check", 335544776L }, { "exception_float_underflow", 335544777L }, { "exception_integer_divide_by_zero", 335544778L }, { "exception_integer_overflow", 335544779L }, { "exception_unknown", 335544780L }, { "exception_stack_overflow", 335544781L }, { "exception_sigsegv", 335544782L }, { "exception_sigill", 335544783L }, { "exception_sigbus", 335544784L }, { "exception_sigfpe", 335544785L }, { "ext_file_delete", 335544786L }, { "ext_file_modify", 335544787L }, { "adm_task_denied", 335544788L }, { "extract_input_mismatch", 335544789L }, { "insufficient_svc_privileges", 335544790L }, { "file_in_use", 335544791L }, { "service_att_err", 335544792L }, { "ddl_not_allowed_by_db_sql_dial", 335544793L }, { "cancelled", 335544794L }, { "unexp_spb_form", 335544795L }, { "sql_dialect_datatype_unsupport", 335544796L }, { "svcnouser", 335544797L }, { "depend_on_uncommitted_rel", 335544798L }, { "svc_name_missing", 335544799L }, { "too_many_contexts", 335544800L }, { "datype_notsup", 335544801L }, { "dialect_reset_warning", 335544802L }, { "dialect_not_changed", 335544803L }, { "database_create_failed", 335544804L }, { "inv_dialect_specified", 335544805L }, { "valid_db_dialects", 335544806L }, { "sqlwarn", 335544807L }, { "dtype_renamed", 335544808L }, { "extern_func_dir_error", 335544809L }, { "date_range_exceeded", 335544810L }, { "inv_client_dialect_specified", 335544811L }, { "valid_client_dialects", 335544812L }, { "optimizer_between_err", 335544813L }, { "service_not_supported", 335544814L }, { "generator_name", 335544815L }, { "udf_name", 335544816L }, { "bad_limit_param", 335544817L }, { "bad_skip_param", 335544818L }, { "io_32bit_exceeded_err", 335544819L }, { "invalid_savepoint", 335544820L }, { "dsql_column_pos_err", 335544821L }, { "dsql_agg_where_err", 335544822L }, { "dsql_agg_group_err", 335544823L }, { "dsql_agg_column_err", 335544824L }, { "dsql_agg_having_err", 335544825L }, { "dsql_agg_nested_err", 335544826L }, { "exec_sql_invalid_arg", 335544827L }, { "exec_sql_invalid_req", 335544828L }, { "exec_sql_invalid_var", 335544829L }, { "exec_sql_max_call_exceeded", 335544830L }, { "conf_access_denied", 335544831L }, { "wrong_backup_state", 335544832L }, { "wal_backup_err", 335544833L }, { "cursor_not_open", 335544834L }, { "bad_shutdown_mode", 335544835L }, { "concat_overflow", 335544836L }, { "bad_substring_offset", 335544837L }, { "foreign_key_target_doesnt_exist", 335544838L }, { "foreign_key_references_present", 335544839L }, { "no_update", 335544840L }, { "cursor_already_open", 335544841L }, { "stack_trace", 335544842L }, { "ctx_var_not_found", 335544843L }, { "ctx_namespace_invalid", 335544844L }, { "ctx_too_big", 335544845L }, { "ctx_bad_argument", 335544846L }, { "identifier_too_long", 335544847L }, { "except2", 335544848L }, { "malformed_string", 335544849L }, { "prc_out_param_mismatch", 335544850L }, { "command_end_err2", 335544851L }, { "partner_idx_incompat_type", 335544852L }, { "bad_substring_length", 335544853L }, { "charset_not_installed", 335544854L }, { "collation_not_installed", 335544855L }, { "att_shutdown", 335544856L }, { "blobtoobig", 335544857L }, { "must_have_phys_field", 335544858L }, { "invalid_time_precision", 335544859L }, { "blob_convert_error", 335544860L }, { "array_convert_error", 335544861L }, { "record_lock_not_supp", 335544862L }, { "partner_idx_not_found", 335544863L }, { "tra_num_exc", 335544864L }, { "gfix_db_name", 335740929L }, { "gfix_invalid_sw", 335740930L }, { "gfix_incmp_sw", 335740932L }, { "gfix_replay_req", 335740933L }, { "gfix_pgbuf_req", 335740934L }, { "gfix_val_req", 335740935L }, { "gfix_pval_req", 335740936L }, { "gfix_trn_req", 335740937L }, { "gfix_full_req", 335740940L }, { "gfix_usrname_req", 335740941L }, { "gfix_pass_req", 335740942L }, { "gfix_subs_name", 335740943L }, { "gfix_wal_req", 335740944L }, { "gfix_sec_req", 335740945L }, { "gfix_nval_req", 335740946L }, { "gfix_type_shut", 335740947L }, { "gfix_retry", 335740948L }, { "gfix_retry_db", 335740951L }, { "gfix_exceed_max", 335740991L }, { "gfix_corrupt_pool", 335740992L }, { "gfix_mem_exhausted", 335740993L }, { "gfix_bad_pool", 335740994L }, { "gfix_trn_not_valid", 335740995L }, { "gfix_unexp_eoi", 335741012L }, { "gfix_recon_fail", 335741018L }, { "gfix_trn_unknown", 335741036L }, { "gfix_mode_req", 335741038L }, { "gfix_opt_SQL_dialect", 335741039L }, { "gfix_pzval_req", 335741042L }, { "dsql_dbkey_from_non_table", 336003074L }, { "dsql_transitional_numeric", 336003075L }, { "dsql_dialect_warning_expr", 336003076L }, { "sql_db_dialect_dtype_unsupport", 336003077L }, { "isc_sql_dialect_conflict_num", 336003079L }, { "dsql_warning_number_ambiguous", 336003080L }, { "dsql_warning_number_ambiguous1", 336003081L }, { "dsql_warn_precision_ambiguous", 336003082L }, { "dsql_warn_precision_ambiguous1", 336003083L }, { "dsql_warn_precision_ambiguous2", 336003084L }, { "dsql_ambiguous_field_name", 336003085L }, { "dsql_udf_return_pos_err", 336003086L }, { "dsql_invalid_label", 336003087L }, { "dsql_datatypes_not_comparable", 336003088L }, { "dsql_cursor_invalid", 336003089L }, { "dsql_cursor_redefined", 336003090L }, { "dsql_cursor_not_found", 336003091L }, { "dsql_cursor_exists", 336003092L }, { "dsql_cursor_rel_ambiguous", 336003093L }, { "dsql_cursor_rel_not_found", 336003094L }, { "dsql_cursor_not_open", 336003095L }, { "dsql_type_not_supp_ext_tab", 336003096L }, { "dyn_role_does_not_exist", 336068796L }, { "dyn_no_grant_admin_opt", 336068797L }, { "dyn_user_not_role_member", 336068798L }, { "dyn_delete_role_failed", 336068799L }, { "dyn_grant_role_to_user", 336068800L }, { "dyn_inv_sql_role_name", 336068801L }, { "dyn_dup_sql_role", 336068802L }, { "dyn_kywd_spec_for_role", 336068803L }, { "dyn_roles_not_supported", 336068804L }, { "dyn_domain_name_exists", 336068812L }, { "dyn_field_name_exists", 336068813L }, { "dyn_dependency_exists", 336068814L }, { "dyn_dtype_invalid", 336068815L }, { "dyn_char_fld_too_small", 336068816L }, { "dyn_invalid_dtype_conversion", 336068817L }, { "dyn_dtype_conv_invalid", 336068818L }, { "dyn_zero_len_id", 336068820L }, { "gbak_unknown_switch", 336330753L }, { "gbak_page_size_missing", 336330754L }, { "gbak_page_size_toobig", 336330755L }, { "gbak_redir_ouput_missing", 336330756L }, { "gbak_switches_conflict", 336330757L }, { "gbak_unknown_device", 336330758L }, { "gbak_no_protection", 336330759L }, { "gbak_page_size_not_allowed", 336330760L }, { "gbak_multi_source_dest", 336330761L }, { "gbak_filename_missing", 336330762L }, { "gbak_dup_inout_names", 336330763L }, { "gbak_inv_page_size", 336330764L }, { "gbak_db_specified", 336330765L }, { "gbak_db_exists", 336330766L }, { "gbak_unk_device", 336330767L }, { "gbak_blob_info_failed", 336330772L }, { "gbak_unk_blob_item", 336330773L }, { "gbak_get_seg_failed", 336330774L }, { "gbak_close_blob_failed", 336330775L }, { "gbak_open_blob_failed", 336330776L }, { "gbak_put_blr_gen_id_failed", 336330777L }, { "gbak_unk_type", 336330778L }, { "gbak_comp_req_failed", 336330779L }, { "gbak_start_req_failed", 336330780L }, { "gbak_rec_failed", 336330781L }, { "gbak_rel_req_failed", 336330782L }, { "gbak_db_info_failed", 336330783L }, { "gbak_no_db_desc", 336330784L }, { "gbak_db_create_failed", 336330785L }, { "gbak_decomp_len_error", 336330786L }, { "gbak_tbl_missing", 336330787L }, { "gbak_blob_col_missing", 336330788L }, { "gbak_create_blob_failed", 336330789L }, { "gbak_put_seg_failed", 336330790L }, { "gbak_rec_len_exp", 336330791L }, { "gbak_inv_rec_len", 336330792L }, { "gbak_exp_data_type", 336330793L }, { "gbak_gen_id_failed", 336330794L }, { "gbak_unk_rec_type", 336330795L }, { "gbak_inv_bkup_ver", 336330796L }, { "gbak_missing_bkup_desc", 336330797L }, { "gbak_string_trunc", 336330798L }, { "gbak_cant_rest_record", 336330799L }, { "gbak_send_failed", 336330800L }, { "gbak_no_tbl_name", 336330801L }, { "gbak_unexp_eof", 336330802L }, { "gbak_db_format_too_old", 336330803L }, { "gbak_inv_array_dim", 336330804L }, { "gbak_xdr_len_expected", 336330807L }, { "gbak_open_bkup_error", 336330817L }, { "gbak_open_error", 336330818L }, { "gbak_missing_block_fac", 336330934L }, { "gbak_inv_block_fac", 336330935L }, { "gbak_block_fac_specified", 336330936L }, { "gbak_missing_username", 336330940L }, { "gbak_missing_password", 336330941L }, { "gbak_missing_skipped_bytes", 336330952L }, { "gbak_inv_skipped_bytes", 336330953L }, { "gbak_err_restore_charset", 336330965L }, { "gbak_err_restore_collation", 336330967L }, { "gbak_read_error", 336330972L }, { "gbak_write_error", 336330973L }, { "gbak_db_in_use", 336330985L }, { "gbak_sysmemex", 336330990L }, { "gbak_restore_role_failed", 336331002L }, { "gbak_role_op_missing", 336331005L }, { "gbak_page_buffers_missing", 336331010L }, { "gbak_page_buffers_wrong_param", 336331011L }, { "gbak_page_buffers_restore", 336331012L }, { "gbak_inv_size", 336331014L }, { "gbak_file_outof_sequence", 336331015L }, { "gbak_join_file_missing", 336331016L }, { "gbak_stdin_not_supptd", 336331017L }, { "gbak_stdout_not_supptd", 336331018L }, { "gbak_bkup_corrupt", 336331019L }, { "gbak_unk_db_file_spec", 336331020L }, { "gbak_hdr_write_failed", 336331021L }, { "gbak_disk_space_ex", 336331022L }, { "gbak_size_lt_min", 336331023L }, { "gbak_svc_name_missing", 336331025L }, { "gbak_not_ownr", 336331026L }, { "gbak_mode_req", 336331031L }, { "gbak_just_data", 336331033L }, { "gbak_data_only", 336331034L }, { "dsql_too_old_ods", 336397205L }, { "dsql_table_not_found", 336397206L }, { "dsql_view_not_found", 336397207L }, { "dsql_line_col_error", 336397208L }, { "dsql_unknown_pos", 336397209L }, { "dsql_no_dup_name", 336397210L }, { "dsql_too_many_values", 336397211L }, { "gsec_cant_open_db", 336723983L }, { "gsec_switches_error", 336723984L }, { "gsec_no_op_spec", 336723985L }, { "gsec_no_usr_name", 336723986L }, { "gsec_err_add", 336723987L }, { "gsec_err_modify", 336723988L }, { "gsec_err_find_mod", 336723989L }, { "gsec_err_rec_not_found", 336723990L }, { "gsec_err_delete", 336723991L }, { "gsec_err_find_del", 336723992L }, { "gsec_err_find_disp", 336723996L }, { "gsec_inv_param", 336723997L }, { "gsec_op_specified", 336723998L }, { "gsec_pw_specified", 336723999L }, { "gsec_uid_specified", 336724000L }, { "gsec_gid_specified", 336724001L }, { "gsec_proj_specified", 336724002L }, { "gsec_org_specified", 336724003L }, { "gsec_fname_specified", 336724004L }, { "gsec_mname_specified", 336724005L }, { "gsec_lname_specified", 336724006L }, { "gsec_inv_switch", 336724008L }, { "gsec_amb_switch", 336724009L }, { "gsec_no_op_specified", 336724010L }, { "gsec_params_not_allowed", 336724011L }, { "gsec_incompat_switch", 336724012L }, { "gsec_inv_username", 336724044L }, { "gsec_inv_pw_length", 336724045L }, { "gsec_db_specified", 336724046L }, { "gsec_db_admin_specified", 336724047L }, { "gsec_db_admin_pw_specified", 336724048L }, { "gsec_sql_role_specified", 336724049L }, { "license_no_file", 336789504L }, { "license_op_specified", 336789523L }, { "license_op_missing", 336789524L }, { "license_inv_switch", 336789525L }, { "license_inv_switch_combo", 336789526L }, { "license_inv_op_combo", 336789527L }, { "license_amb_switch", 336789528L }, { "license_inv_parameter", 336789529L }, { "license_param_specified", 336789530L }, { "license_param_req", 336789531L }, { "license_syntx_error", 336789532L }, { "license_dup_id", 336789534L }, { "license_inv_id_key", 336789535L }, { "license_err_remove", 336789536L }, { "license_err_update", 336789537L }, { "license_err_convert", 336789538L }, { "license_err_unk", 336789539L }, { "license_svc_err_add", 336789540L }, { "license_svc_err_remove", 336789541L }, { "license_eval_exists", 336789563L }, { "gstat_unknown_switch", 336920577L }, { "gstat_retry", 336920578L }, { "gstat_wrong_ods", 336920579L }, { "gstat_unexpected_eof", 336920580L }, { "gstat_open_err", 336920605L }, { "gstat_read_err", 336920606L }, { "gstat_sysmemex", 336920607L } }; //--------------------------------------------------------------------------- utf8::String strErrorHandler(int32_t err) { ISCErrorDesc bs; bs.code_ = err; intptr_t c = sizeof(iscErrors) / sizeof(iscErrors[0]); uintptr_t i = ksys::bSearch(iscErrors, bs, c); if( c == 0 ) return iscErrors[i].error_; return utf8::String(); } //--------------------------------------------------------------------------- ///////////////////////////////////////////////////////////////////////////// //--------------------------------------------------------------------------- EClientServer::~EClientServer() { } //--------------------------------------------------------------------------- EClientServer::EClientServer(const ISC_STATUS_ARRAY stat,const utf8::String & what) { if( stat != NULL ){ ISC_STATUS_ARRAY status; memcpy(status,stat,sizeof(status)); clearError(); char error[1024]; if( api.fb_interpret != NULL ){ const ISC_STATUS * pStatus = status, * aStatus = pStatus; while( api.fb_interpret(error,sizeof(error),&pStatus) != 0 ){ if( *aStatus == 1 ){ utf8::String e(strErrorHandler(aStatus[1])); if( e.strlen() > 0 ){ strcat(error, ", isc_"); strcat(error, e.c_str()); } } addError(aStatus[1],error); aStatus = pStatus; } } else { ISC_STATUS * pStatus = status, * aStatus = pStatus; while( api.isc_interprete(error,&pStatus) != 0 ){ if( *aStatus == 1 ){ utf8::String e(strErrorHandler(aStatus[1])); if( e.strlen() > 0 ){ strcat(error, ", isc_"); strcat(error, e.c_str()); } } addError(aStatus[1],error); aStatus = pStatus; } } } else { addError(EINVAL,what); } } //--------------------------------------------------------------------------- bool EClientServer::isFatalError() const { return searchCode( isc_network_error, isc_net_read_err, isc_net_write_err, isc_lost_db_connection ); } //--------------------------------------------------------------------------- } // namespace fbcpp //---------------------------------------------------------------------------