From: <mro...@us...> - 2012-11-17 10:42:34
|
Revision: 57358 http://firebird.svn.sourceforge.net/firebird/?rev=57358&view=rev Author: mrotteveel Date: 2012-11-17 10:42:26 +0000 (Sat, 17 Nov 2012) Log Message: ----------- Update errors and sqlstate (from currentFB 3 trunk) + changes to MessageDump utility Modified Paths: -------------- client-java/trunk/src/main/org/firebirdsql/gds/ISCConstants.java client-java/trunk/src/messages/org/firebirdsql/util/MessageDump.java client-java/trunk/src/resources/isc_error_msg.properties client-java/trunk/src/resources/isc_error_sqlstates.properties Modified: client-java/trunk/src/main/org/firebirdsql/gds/ISCConstants.java =================================================================== --- client-java/trunk/src/main/org/firebirdsql/gds/ISCConstants.java 2012-11-17 03:40:35 UTC (rev 57357) +++ client-java/trunk/src/main/org/firebirdsql/gds/ISCConstants.java 2012-11-17 10:42:26 UTC (rev 57358) @@ -752,6 +752,7 @@ public final static int isc_arg_netware = 16; /* NetWare error code */ public final static int isc_arg_win32 = 17; /* Win32 error code */ public final static int isc_arg_warning = 18; /* warning argument */ + public final static int isc_arg_sql_state = 19; /* SQLSTATE */ public final static int isc_arith_except = 335544321; public final static int isc_bad_dbkey = 335544322; @@ -1131,10 +1132,10 @@ public final static int isc_log_length_spec = 335544696; public final static int isc_precision_err = 335544697; public final static int isc_scale_nogt = 335544698; - public final static int isc_expec_int = 335544699; + public final static int isc_expec_short = 335544699; public final static int isc_expec_long = 335544700; - public final static int isc_expec_uint = 335544701; - public final static int isc_like_escape_invalid = 335544702; + public final static int isc_expec_ushort = 335544701; + public final static int isc_escape_invalid = 335544702; public final static int isc_svcnoexe = 335544703; public final static int isc_net_lookup_err = 335544704; public final static int isc_service_unknown = 335544705; @@ -1264,6 +1265,221 @@ public final static int isc_exec_sql_invalid_var = 335544829; public final static int isc_exec_sql_max_call_exceeded = 335544830; public final static int isc_conf_access_denied = 335544831; + public final static int isc_wrong_backup_state = 335544832; + public final static int isc_wal_backup_err = 335544833; + public final static int isc_cursor_not_open = 335544834; + public final static int isc_bad_shutdown_mode = 335544835; + public final static int isc_concat_overflow = 335544836; + public final static int isc_bad_substring_offset = 335544837; + public final static int isc_foreign_key_target_doesnt_exist = 335544838; + public final static int isc_foreign_key_references_present = 335544839; + public final static int isc_no_update = 335544840; + public final static int isc_cursor_already_open = 335544841; + public final static int isc_stack_trace = 335544842; + public final static int isc_ctx_var_not_found = 335544843; + public final static int isc_ctx_namespace_invalid = 335544844; + public final static int isc_ctx_too_big = 335544845; + public final static int isc_ctx_bad_argument = 335544846; + public final static int isc_identifier_too_long = 335544847; + public final static int isc_except2 = 335544848; + public final static int isc_malformed_string = 335544849; + public final static int isc_prc_out_param_mismatch = 335544850; + public final static int isc_command_end_err2 = 335544851; + public final static int isc_partner_idx_incompat_type = 335544852; + public final static int isc_bad_substring_length = 335544853; + public final static int isc_charset_not_installed = 335544854; + public final static int isc_collation_not_installed = 335544855; + public final static int isc_att_shutdown = 335544856; + public final static int isc_blobtoobig = 335544857; + public final static int isc_must_have_phys_field = 335544858; + public final static int isc_invalid_time_precision = 335544859; + public final static int isc_blob_convert_error = 335544860; + public final static int isc_array_convert_error = 335544861; + public final static int isc_record_lock_not_supp = 335544862; + public final static int isc_partner_idx_not_found = 335544863; + public final static int isc_tra_num_exc = 335544864; + public final static int isc_field_disappeared = 335544865; + public final static int isc_met_wrong_gtt_scope = 335544866; + public final static int isc_subtype_for_internal_use = 335544867; + public final static int isc_illegal_prc_type = 335544868; + public final static int isc_invalid_sort_datatype = 335544869; + public final static int isc_collation_name = 335544870; + public final static int isc_domain_name = 335544871; + public final static int isc_domnotdef = 335544872; + public final static int isc_array_max_dimensions = 335544873; + public final static int isc_max_db_per_trans_allowed = 335544874; + public final static int isc_bad_debug_format = 335544875; + public final static int isc_bad_proc_BLR = 335544876; + public final static int isc_key_too_big = 335544877; + public final static int isc_concurrent_transaction = 335544878; + public final static int isc_not_valid_for_var = 335544879; + public final static int isc_not_valid_for = 335544880; + public final static int isc_need_difference = 335544881; + public final static int isc_long_login = 335544882; + public final static int isc_fldnotdef2 = 335544883; + public final static int isc_invalid_similar_pattern = 335544884; + public final static int isc_bad_teb_form = 335544885; + public final static int isc_tpb_multiple_txn_isolation = 335544886; + public final static int isc_tpb_reserv_before_table = 335544887; + public final static int isc_tpb_multiple_spec = 335544888; + public final static int isc_tpb_option_without_rc = 335544889; + public final static int isc_tpb_conflicting_options = 335544890; + public final static int isc_tpb_reserv_missing_tlen = 335544891; + public final static int isc_tpb_reserv_long_tlen = 335544892; + public final static int isc_tpb_reserv_missing_tname = 335544893; + public final static int isc_tpb_reserv_corrup_tlen = 335544894; + public final static int isc_tpb_reserv_null_tlen = 335544895; + public final static int isc_tpb_reserv_relnotfound = 335544896; + public final static int isc_tpb_reserv_baserelnotfound = 335544897; + public final static int isc_tpb_missing_len = 335544898; + public final static int isc_tpb_missing_value = 335544899; + public final static int isc_tpb_corrupt_len = 335544900; + public final static int isc_tpb_null_len = 335544901; + public final static int isc_tpb_overflow_len = 335544902; + public final static int isc_tpb_invalid_value = 335544903; + public final static int isc_tpb_reserv_stronger_wng = 335544904; + public final static int isc_tpb_reserv_stronger = 335544905; + public final static int isc_tpb_reserv_max_recursion = 335544906; + public final static int isc_tpb_reserv_virtualtbl = 335544907; + public final static int isc_tpb_reserv_systbl = 335544908; + public final static int isc_tpb_reserv_temptbl = 335544909; + public final static int isc_tpb_readtxn_after_writelock = 335544910; + public final static int isc_tpb_writelock_after_readtxn = 335544911; + public final static int isc_time_range_exceeded = 335544912; + public final static int isc_datetime_range_exceeded = 335544913; + public final static int isc_string_truncation = 335544914; + public final static int isc_blob_truncation = 335544915; + public final static int isc_numeric_out_of_range = 335544916; + public final static int isc_shutdown_timeout = 335544917; + public final static int isc_att_handle_busy = 335544918; + public final static int isc_bad_udf_freeit = 335544919; + public final static int isc_eds_provider_not_found = 335544920; + public final static int isc_eds_connection = 335544921; + public final static int isc_eds_preprocess = 335544922; + public final static int isc_eds_stmt_expected = 335544923; + public final static int isc_eds_prm_name_expected = 335544924; + public final static int isc_eds_unclosed_comment = 335544925; + public final static int isc_eds_statement = 335544926; + public final static int isc_eds_input_prm_mismatch = 335544927; + public final static int isc_eds_output_prm_mismatch = 335544928; + public final static int isc_eds_input_prm_not_set = 335544929; + public final static int isc_too_big_blr = 335544930; + public final static int isc_montabexh = 335544931; + public final static int isc_modnotfound = 335544932; + public final static int isc_nothing_to_cancel = 335544933; + public final static int isc_ibutil_not_loaded = 335544934; + public final static int isc_circular_computed = 335544935; + public final static int isc_psw_db_error = 335544936; + public final static int isc_invalid_type_datetime_op = 335544937; + public final static int isc_onlycan_add_timetodate = 335544938; + public final static int isc_onlycan_add_datetotime = 335544939; + public final static int isc_onlycansub_tstampfromtstamp = 335544940; + public final static int isc_onlyoneop_mustbe_tstamp = 335544941; + public final static int isc_invalid_extractpart_time = 335544942; + public final static int isc_invalid_extractpart_date = 335544943; + public final static int isc_invalidarg_extract = 335544944; + public final static int isc_sysf_argmustbe_exact = 335544945; + public final static int isc_sysf_argmustbe_exact_or_fp = 335544946; + public final static int isc_sysf_argviolates_uuidtype = 335544947; + public final static int isc_sysf_argviolates_uuidlen = 335544948; + public final static int isc_sysf_argviolates_uuidfmt = 335544949; + public final static int isc_sysf_argviolates_guidigits = 335544950; + public final static int isc_sysf_invalid_addpart_time = 335544951; + public final static int isc_sysf_invalid_add_datetime = 335544952; + public final static int isc_sysf_invalid_addpart_dtime = 335544953; + public final static int isc_sysf_invalid_add_dtime_rc = 335544954; + public final static int isc_sysf_invalid_diff_dtime = 335544955; + public final static int isc_sysf_invalid_timediff = 335544956; + public final static int isc_sysf_invalid_tstamptimediff = 335544957; + public final static int isc_sysf_invalid_datetimediff = 335544958; + public final static int isc_sysf_invalid_diffpart = 335544959; + public final static int isc_sysf_argmustbe_positive = 335544960; + public final static int isc_sysf_basemustbe_positive = 335544961; + public final static int isc_sysf_argnmustbe_nonneg = 335544962; + public final static int isc_sysf_argnmustbe_positive = 335544963; + public final static int isc_sysf_invalid_zeropowneg = 335544964; + public final static int isc_sysf_invalid_negpowfp = 335544965; + public final static int isc_sysf_invalid_scale = 335544966; + public final static int isc_sysf_argmustbe_nonneg = 335544967; + public final static int isc_sysf_binuuid_mustbe_str = 335544968; + public final static int isc_sysf_binuuid_wrongsize = 335544969; + public final static int isc_missing_required_spb = 335544970; + public final static int isc_net_server_shutdown = 335544971; + public final static int isc_bad_conn_str = 335544972; + public final static int isc_bad_epb_form = 335544973; + public final static int isc_no_threads = 335544974; + public final static int isc_net_event_connect_timeout = 335544975; + public final static int isc_sysf_argmustbe_nonzero = 335544976; + public final static int isc_sysf_argmustbe_range_inc1_1 = 335544977; + public final static int isc_sysf_argmustbe_gteq_one = 335544978; + public final static int isc_sysf_argmustbe_range_exc1_1 = 335544979; + public final static int isc_internal_rejected_params = 335544980; + public final static int isc_sysf_fp_overflow = 335544981; + public final static int isc_udf_fp_overflow = 335544982; + public final static int isc_udf_fp_nan = 335544983; + public final static int isc_instance_conflict = 335544984; + public final static int isc_out_of_temp_space = 335544985; + public final static int isc_eds_expl_tran_ctrl = 335544986; + public final static int isc_no_trusted_spb = 335544987; + public final static int isc_package_name = 335544988; + public final static int isc_cannot_make_not_null = 335544989; + public final static int isc_feature_removed = 335544990; + public final static int isc_view_name = 335544991; + public final static int isc_lock_dir_access = 335544992; + public final static int isc_invalid_fetch_option = 335544993; + public final static int isc_bad_fun_BLR = 335544994; + public final static int isc_func_pack_not_implemented = 335544995; + public final static int isc_proc_pack_not_implemented = 335544996; + public final static int isc_eem_func_not_returned = 335544997; + public final static int isc_eem_proc_not_returned = 335544998; + public final static int isc_eem_trig_not_returned = 335544999; + public final static int isc_eem_bad_plugin_ver = 335545000; + public final static int isc_eem_engine_notfound = 335545001; + public final static int isc_attachment_in_use = 335545002; + public final static int isc_transaction_in_use = 335545003; + public final static int isc_pman_plugin_notfound = 335545004; + public final static int isc_pman_cannot_load_plugin = 335545005; + public final static int isc_pman_entrypoint_notfound = 335545006; + public final static int isc_pman_bad_conf_index = 335545007; + public final static int isc_pman_unknown_instance = 335545008; + public final static int isc_sysf_invalid_trig_namespace = 335545009; + public final static int isc_unexpected_null = 335545010; + public final static int isc_type_notcompat_blob = 335545011; + public final static int isc_invalid_date_val = 335545012; + public final static int isc_invalid_time_val = 335545013; + public final static int isc_invalid_timestamp_val = 335545014; + public final static int isc_invalid_index_val = 335545015; + public final static int isc_formatted_exception = 335545016; + public final static int isc_async_active = 335545017; + public final static int isc_private_function = 335545018; + public final static int isc_private_procedure = 335545019; + public final static int isc_request_outdated = 335545020; + public final static int isc_bad_events_handle = 335545021; + public final static int isc_cannot_copy_stmt = 335545022; + public final static int isc_invalid_boolean_usage = 335545023; + public final static int isc_sysf_argscant_both_be_zero = 335545024; + public final static int isc_spb_no_id = 335545025; + public final static int isc_ee_blr_mismatch_null = 335545026; + public final static int isc_ee_blr_mismatch_length = 335545027; + public final static int isc_ss_out_of_bounds = 335545028; + public final static int isc_missing_data_structures = 335545029; + public final static int isc_protect_sys_tab = 335545030; + public final static int isc_libtommath_generic = 335545031; + public final static int isc_wroblrver2 = 335545032; + public final static int isc_trunc_limits = 335545033; + public final static int isc_info_access = 335545034; + public final static int isc_svc_no_stdin = 335545035; + public final static int isc_svc_start_failed = 335545036; + public final static int isc_svc_no_switches = 335545037; + public final static int isc_svc_bad_size = 335545038; + public final static int isc_no_crypt_plugin = 335545039; + public final static int isc_cp_name_too_long = 335545040; + public final static int isc_cp_process_active = 335545041; + public final static int isc_cp_already_crypted = 335545042; + public final static int isc_decrypt_error = 335545043; + public final static int isc_no_providers = 335545044; + public final static int isc_null_spb = 335545045; + public final static int isc_max_args_exceeded = 335545046; public final static int isc_gfix_db_name = 335740929; public final static int isc_gfix_invalid_sw = 335740930; public final static int isc_gfix_incmp_sw = 335740932; @@ -1291,7 +1507,7 @@ public final static int isc_gfix_recon_fail = 335741018; public final static int isc_gfix_trn_unknown = 335741036; public final static int isc_gfix_mode_req = 335741038; - public final static int isc_gfix_opt_SQL_dialect = 335741039; + public final static int isc_gfix_pzval_req = 335741042; public final static int isc_dsql_dbkey_from_non_table = 336003074; public final static int isc_dsql_transitional_numeric = 336003075; public final static int isc_dsql_dialect_warning_expr = 336003076; @@ -1302,6 +1518,42 @@ public final static int isc_dsql_warn_precision_ambiguous = 336003082; public final static int isc_dsql_warn_precision_ambiguous1 = 336003083; public final static int isc_dsql_warn_precision_ambiguous2 = 336003084; + public final static int isc_dsql_ambiguous_field_name = 336003085; + public final static int isc_dsql_udf_return_pos_err = 336003086; + public final static int isc_dsql_invalid_label = 336003087; + public final static int isc_dsql_datatypes_not_comparable = 336003088; + public final static int isc_dsql_cursor_invalid = 336003089; + public final static int isc_dsql_cursor_redefined = 336003090; + public final static int isc_dsql_cursor_not_found = 336003091; + public final static int isc_dsql_cursor_exists = 336003092; + public final static int isc_dsql_cursor_rel_ambiguous = 336003093; + public final static int isc_dsql_cursor_rel_not_found = 336003094; + public final static int isc_dsql_cursor_not_open = 336003095; + public final static int isc_dsql_type_not_supp_ext_tab = 336003096; + public final static int isc_dsql_feature_not_supported_ods = 336003097; + public final static int isc_primary_key_required = 336003098; + public final static int isc_upd_ins_doesnt_match_pk = 336003099; + public final static int isc_upd_ins_doesnt_match_matching = 336003100; + public final static int isc_upd_ins_with_complex_view = 336003101; + public final static int isc_dsql_incompatible_trigger_type = 336003102; + public final static int isc_dsql_db_trigger_type_cant_change = 336003103; + public final static int isc_dsql_record_version_table = 336003104; + public final static int isc_dyn_filter_not_found = 336068645; + public final static int isc_dyn_func_not_found = 336068649; + public final static int isc_dyn_index_not_found = 336068656; + public final static int isc_dyn_view_not_found = 336068662; + public final static int isc_dyn_domain_not_found = 336068697; + public final static int isc_dyn_cant_modify_auto_trig = 336068717; + public final static int isc_dyn_dup_table = 336068740; + public final static int isc_dyn_proc_not_found = 336068748; + public final static int isc_dyn_exception_not_found = 336068752; + public final static int isc_dyn_proc_param_not_found = 336068754; + public final static int isc_dyn_trig_not_found = 336068755; + public final static int isc_dyn_charset_not_found = 336068759; + public final static int isc_dyn_collation_not_found = 336068760; + public final static int isc_dyn_role_not_found = 336068763; + public final static int isc_dyn_name_longer = 336068767; + public final static int isc_dyn_column_does_not_exist = 336068784; public final static int isc_dyn_role_does_not_exist = 336068796; public final static int isc_dyn_no_grant_admin_opt = 336068797; public final static int isc_dyn_user_not_role_member = 336068798; @@ -1318,6 +1570,45 @@ public final static int isc_dyn_char_fld_too_small = 336068816; public final static int isc_dyn_invalid_dtype_conversion = 336068817; public final static int isc_dyn_dtype_conv_invalid = 336068818; + public final static int isc_dyn_zero_len_id = 336068820; + public final static int isc_dyn_gen_not_found = 336068822; + public final static int isc_max_coll_per_charset = 336068829; + public final static int isc_invalid_coll_attr = 336068830; + public final static int isc_dyn_wrong_gtt_scope = 336068840; + public final static int isc_dyn_coll_used_table = 336068843; + public final static int isc_dyn_coll_used_domain = 336068844; + public final static int isc_dyn_cannot_del_syscoll = 336068845; + public final static int isc_dyn_cannot_del_def_coll = 336068846; + public final static int isc_dyn_table_not_found = 336068849; + public final static int isc_dyn_coll_used_procedure = 336068851; + public final static int isc_dyn_scale_too_big = 336068852; + public final static int isc_dyn_precision_too_small = 336068853; + public final static int isc_dyn_miss_priv_warning = 336068855; + public final static int isc_dyn_ods_not_supp_feature = 336068856; + public final static int isc_dyn_cannot_addrem_computed = 336068857; + public final static int isc_dyn_no_empty_pw = 336068858; + public final static int isc_dyn_dup_index = 336068859; + public final static int isc_dyn_package_not_found = 336068864; + public final static int isc_dyn_schema_not_found = 336068865; + public final static int isc_dyn_cannot_mod_sysproc = 336068866; + public final static int isc_dyn_cannot_mod_systrig = 336068867; + public final static int isc_dyn_cannot_mod_sysfunc = 336068868; + public final static int isc_dyn_invalid_ddl_proc = 336068869; + public final static int isc_dyn_invalid_ddl_trig = 336068870; + public final static int isc_dyn_funcnotdef_package = 336068871; + public final static int isc_dyn_procnotdef_package = 336068872; + public final static int isc_dyn_funcsignat_package = 336068873; + public final static int isc_dyn_procsignat_package = 336068874; + public final static int isc_dyn_defvaldecl_package = 336068875; + public final static int isc_dyn_package_body_exists = 336068877; + public final static int isc_dyn_invalid_ddl_func = 336068878; + public final static int isc_dyn_newfc_oldsyntax = 336068879; + public final static int isc_dyn_func_param_not_found = 336068886; + public final static int isc_dyn_routine_param_not_found = 336068887; + public final static int isc_dyn_routine_param_ambiguous = 336068888; + public final static int isc_dyn_coll_used_function = 336068889; + public final static int isc_dyn_domain_used_function = 336068890; + public final static int isc_dyn_alter_user_no_clause = 336068891; public final static int isc_gbak_unknown_switch = 336330753; public final static int isc_gbak_page_size_missing = 336330754; public final static int isc_gbak_page_size_toobig = 336330755; @@ -1400,8 +1691,138 @@ public final static int isc_gbak_svc_name_missing = 336331025; public final static int isc_gbak_not_ownr = 336331026; public final static int isc_gbak_mode_req = 336331031; + public final static int isc_gbak_just_data = 336331033; + public final static int isc_gbak_data_only = 336331034; + public final static int isc_gbak_missing_interval = 336331078; + public final static int isc_gbak_wrong_interval = 336331079; + public final static int isc_gbak_verify_verbint = 336331081; + public final static int isc_gbak_option_only_restore = 336331082; + public final static int isc_gbak_option_only_backup = 336331083; + public final static int isc_gbak_option_conflict = 336331084; + public final static int isc_gbak_param_conflict = 336331085; + public final static int isc_gbak_option_repeated = 336331086; + public final static int isc_gbak_max_dbkey_recursion = 336331091; + public final static int isc_gbak_max_dbkey_length = 336331092; + public final static int isc_gbak_invalid_metadata = 336331093; + public final static int isc_gbak_invalid_data = 336331094; + public final static int isc_gbak_inv_bkup_ver2 = 336331096; + public final static int isc_gbak_db_format_too_old2 = 336331100; + public final static int isc_dsql_too_old_ods = 336397205; public final static int isc_dsql_table_not_found = 336397206; public final static int isc_dsql_view_not_found = 336397207; + public final static int isc_dsql_line_col_error = 336397208; + public final static int isc_dsql_unknown_pos = 336397209; + public final static int isc_dsql_no_dup_name = 336397210; + public final static int isc_dsql_too_many_values = 336397211; + public final static int isc_dsql_no_array_computed = 336397212; + public final static int isc_dsql_implicit_domain_name = 336397213; + public final static int isc_dsql_only_can_subscript_array = 336397214; + public final static int isc_dsql_max_sort_items = 336397215; + public final static int isc_dsql_max_group_items = 336397216; + public final static int isc_dsql_conflicting_sort_field = 336397217; + public final static int isc_dsql_derived_table_more_columns = 336397218; + public final static int isc_dsql_derived_table_less_columns = 336397219; + public final static int isc_dsql_derived_field_unnamed = 336397220; + public final static int isc_dsql_derived_field_dup_name = 336397221; + public final static int isc_dsql_derived_alias_select = 336397222; + public final static int isc_dsql_derived_alias_field = 336397223; + public final static int isc_dsql_auto_field_bad_pos = 336397224; + public final static int isc_dsql_cte_wrong_reference = 336397225; + public final static int isc_dsql_cte_cycle = 336397226; + public final static int isc_dsql_cte_outer_join = 336397227; + public final static int isc_dsql_cte_mult_references = 336397228; + public final static int isc_dsql_cte_not_a_union = 336397229; + public final static int isc_dsql_cte_nonrecurs_after_recurs = 336397230; + public final static int isc_dsql_cte_wrong_clause = 336397231; + public final static int isc_dsql_cte_union_all = 336397232; + public final static int isc_dsql_cte_miss_nonrecursive = 336397233; + public final static int isc_dsql_cte_nested_with = 336397234; + public final static int isc_dsql_col_more_than_once_using = 336397235; + public final static int isc_dsql_unsupp_feature_dialect = 336397236; + public final static int isc_dsql_cte_not_used = 336397237; + public final static int isc_dsql_col_more_than_once_view = 336397238; + public final static int isc_dsql_unsupported_in_auto_trans = 336397239; + public final static int isc_dsql_eval_unknode = 336397240; + public final static int isc_dsql_agg_wrongarg = 336397241; + public final static int isc_dsql_agg2_wrongarg = 336397242; + public final static int isc_dsql_nodateortime_pm_string = 336397243; + public final static int isc_dsql_invalid_datetime_subtract = 336397244; + public final static int isc_dsql_invalid_dateortime_add = 336397245; + public final static int isc_dsql_invalid_type_minus_date = 336397246; + public final static int isc_dsql_nostring_addsub_dial3 = 336397247; + public final static int isc_dsql_invalid_type_addsub_dial3 = 336397248; + public final static int isc_dsql_invalid_type_multip_dial1 = 336397249; + public final static int isc_dsql_nostring_multip_dial3 = 336397250; + public final static int isc_dsql_invalid_type_multip_dial3 = 336397251; + public final static int isc_dsql_mustuse_numeric_div_dial1 = 336397252; + public final static int isc_dsql_nostring_div_dial3 = 336397253; + public final static int isc_dsql_invalid_type_div_dial3 = 336397254; + public final static int isc_dsql_nostring_neg_dial3 = 336397255; + public final static int isc_dsql_invalid_type_neg = 336397256; + public final static int isc_dsql_max_distinct_items = 336397257; + public final static int isc_dsql_alter_charset_failed = 336397258; + public final static int isc_dsql_comment_on_failed = 336397259; + public final static int isc_dsql_create_func_failed = 336397260; + public final static int isc_dsql_alter_func_failed = 336397261; + public final static int isc_dsql_create_alter_func_failed = 336397262; + public final static int isc_dsql_drop_func_failed = 336397263; + public final static int isc_dsql_recreate_func_failed = 336397264; + public final static int isc_dsql_create_proc_failed = 336397265; + public final static int isc_dsql_alter_proc_failed = 336397266; + public final static int isc_dsql_create_alter_proc_failed = 336397267; + public final static int isc_dsql_drop_proc_failed = 336397268; + public final static int isc_dsql_recreate_proc_failed = 336397269; + public final static int isc_dsql_create_trigger_failed = 336397270; + public final static int isc_dsql_alter_trigger_failed = 336397271; + public final static int isc_dsql_create_alter_trigger_failed = 336397272; + public final static int isc_dsql_drop_trigger_failed = 336397273; + public final static int isc_dsql_recreate_trigger_failed = 336397274; + public final static int isc_dsql_create_collation_failed = 336397275; + public final static int isc_dsql_drop_collation_failed = 336397276; + public final static int isc_dsql_create_domain_failed = 336397277; + public final static int isc_dsql_alter_domain_failed = 336397278; + public final static int isc_dsql_drop_domain_failed = 336397279; + public final static int isc_dsql_create_except_failed = 336397280; + public final static int isc_dsql_alter_except_failed = 336397281; + public final static int isc_dsql_create_alter_except_failed = 336397282; + public final static int isc_dsql_recreate_except_failed = 336397283; + public final static int isc_dsql_drop_except_failed = 336397284; + public final static int isc_dsql_create_sequence_failed = 336397285; + public final static int isc_dsql_create_table_failed = 336397286; + public final static int isc_dsql_alter_table_failed = 336397287; + public final static int isc_dsql_drop_table_failed = 336397288; + public final static int isc_dsql_recreate_table_failed = 336397289; + public final static int isc_dsql_create_pack_failed = 336397290; + public final static int isc_dsql_alter_pack_failed = 336397291; + public final static int isc_dsql_create_alter_pack_failed = 336397292; + public final static int isc_dsql_drop_pack_failed = 336397293; + public final static int isc_dsql_recreate_pack_failed = 336397294; + public final static int isc_dsql_create_pack_body_failed = 336397295; + public final static int isc_dsql_drop_pack_body_failed = 336397296; + public final static int isc_dsql_recreate_pack_body_failed = 336397297; + public final static int isc_dsql_create_view_failed = 336397298; + public final static int isc_dsql_alter_view_failed = 336397299; + public final static int isc_dsql_create_alter_view_failed = 336397300; + public final static int isc_dsql_recreate_view_failed = 336397301; + public final static int isc_dsql_drop_view_failed = 336397302; + public final static int isc_dsql_drop_sequence_failed = 336397303; + public final static int isc_dsql_recreate_sequence_failed = 336397304; + public final static int isc_dsql_drop_index_failed = 336397305; + public final static int isc_dsql_drop_filter_failed = 336397306; + public final static int isc_dsql_drop_shadow_failed = 336397307; + public final static int isc_dsql_drop_role_failed = 336397308; + public final static int isc_dsql_drop_user_failed = 336397309; + public final static int isc_dsql_create_role_failed = 336397310; + public final static int isc_dsql_alter_role_failed = 336397311; + public final static int isc_dsql_alter_index_failed = 336397312; + public final static int isc_dsql_alter_database_failed = 336397313; + public final static int isc_dsql_create_shadow_failed = 336397314; + public final static int isc_dsql_create_filter_failed = 336397315; + public final static int isc_dsql_create_index_failed = 336397316; + public final static int isc_dsql_create_user_failed = 336397317; + public final static int isc_dsql_alter_user_failed = 336397318; + public final static int isc_dsql_grant_failed = 336397319; + public final static int isc_dsql_revoke_failed = 336397320; public final static int isc_gsec_cant_open_db = 336723983; public final static int isc_gsec_switches_error = 336723984; public final static int isc_gsec_no_op_spec = 336723985; @@ -1434,26 +1855,6 @@ public final static int isc_gsec_db_admin_specified = 336724047; public final static int isc_gsec_db_admin_pw_specified = 336724048; public final static int isc_gsec_sql_role_specified = 336724049; - public final static int isc_license_no_file = 336789504; - public final static int isc_license_op_specified = 336789523; - public final static int isc_license_op_missing = 336789524; - public final static int isc_license_inv_switch = 336789525; - public final static int isc_license_inv_switch_combo = 336789526; - public final static int isc_license_inv_op_combo = 336789527; - public final static int isc_license_amb_switch = 336789528; - public final static int isc_license_inv_parameter = 336789529; - public final static int isc_license_param_specified = 336789530; - public final static int isc_license_param_req = 336789531; - public final static int isc_license_syntx_error = 336789532; - public final static int isc_license_dup_id = 336789534; - public final static int isc_license_inv_id_key = 336789535; - public final static int isc_license_err_remove = 336789536; - public final static int isc_license_err_update = 336789537; - public final static int isc_license_err_convert = 336789538; - public final static int isc_license_err_unk = 336789539; - public final static int isc_license_svc_err_add = 336789540; - public final static int isc_license_svc_err_remove = 336789541; - public final static int isc_license_eval_exists = 336789563; public final static int isc_gstat_unknown_switch = 336920577; public final static int isc_gstat_retry = 336920578; public final static int isc_gstat_wrong_ods = 336920579; @@ -1461,7 +1862,69 @@ public final static int isc_gstat_open_err = 336920605; public final static int isc_gstat_read_err = 336920606; public final static int isc_gstat_sysmemex = 336920607; - public final static int isc_err_max = 689; + public final static int isc_fbsvcmgr_bad_am = 336986113; + public final static int isc_fbsvcmgr_bad_wm = 336986114; + public final static int isc_fbsvcmgr_bad_rs = 336986115; + public final static int isc_fbsvcmgr_info_err = 336986116; + public final static int isc_fbsvcmgr_query_err = 336986117; + public final static int isc_fbsvcmgr_switch_unknown = 336986118; + public final static int isc_fbsvcmgr_bad_sm = 336986159; + public final static int isc_fbsvcmgr_fp_open = 336986160; + public final static int isc_fbsvcmgr_fp_read = 336986161; + public final static int isc_fbsvcmgr_fp_empty = 336986162; + public final static int isc_fbsvcmgr_bad_arg = 336986164; + public final static int isc_utl_trusted_switch = 337051649; + public final static int isc_nbackup_missing_param = 337117213; + public final static int isc_nbackup_allowed_switches = 337117214; + public final static int isc_nbackup_unknown_param = 337117215; + public final static int isc_nbackup_unknown_switch = 337117216; + public final static int isc_nbackup_nofetchpw_svc = 337117217; + public final static int isc_nbackup_pwfile_error = 337117218; + public final static int isc_nbackup_size_with_lock = 337117219; + public final static int isc_nbackup_no_switch = 337117220; + public final static int isc_nbackup_err_read = 337117223; + public final static int isc_nbackup_err_write = 337117224; + public final static int isc_nbackup_err_seek = 337117225; + public final static int isc_nbackup_err_opendb = 337117226; + public final static int isc_nbackup_err_fadvice = 337117227; + public final static int isc_nbackup_err_createdb = 337117228; + public final static int isc_nbackup_err_openbk = 337117229; + public final static int isc_nbackup_err_createbk = 337117230; + public final static int isc_nbackup_err_eofdb = 337117231; + public final static int isc_nbackup_fixup_wrongstate = 337117232; + public final static int isc_nbackup_err_db = 337117233; + public final static int isc_nbackup_userpw_toolong = 337117234; + public final static int isc_nbackup_lostrec_db = 337117235; + public final static int isc_nbackup_lostguid_db = 337117236; + public final static int isc_nbackup_err_eofhdrdb = 337117237; + public final static int isc_nbackup_db_notlock = 337117238; + public final static int isc_nbackup_lostguid_bk = 337117239; + public final static int isc_nbackup_page_changed = 337117240; + public final static int isc_nbackup_dbsize_inconsistent = 337117241; + public final static int isc_nbackup_failed_lzbk = 337117242; + public final static int isc_nbackup_err_eofhdrbk = 337117243; + public final static int isc_nbackup_invalid_incbk = 337117244; + public final static int isc_nbackup_unsupvers_incbk = 337117245; + public final static int isc_nbackup_invlevel_incbk = 337117246; + public final static int isc_nbackup_wrong_orderbk = 337117247; + public final static int isc_nbackup_err_eofbk = 337117248; + public final static int isc_nbackup_err_copy = 337117249; + public final static int isc_nbackup_err_eofhdr_restdb = 337117250; + public final static int isc_nbackup_lostguid_l0bk = 337117251; + public final static int isc_nbackup_switchd_parameter = 337117255; + public final static int isc_nbackup_user_stop = 337117257; + public final static int isc_trace_conflict_acts = 337182750; + public final static int isc_trace_act_notfound = 337182751; + public final static int isc_trace_switch_once = 337182752; + public final static int isc_trace_param_val_miss = 337182753; + public final static int isc_trace_param_invalid = 337182754; + public final static int isc_trace_switch_unknown = 337182755; + public final static int isc_trace_switch_svc_only = 337182756; + public final static int isc_trace_switch_user_only = 337182757; + public final static int isc_trace_switch_param_miss = 337182758; + public final static int isc_trace_param_act_notcompat = 337182759; + public final static int isc_trace_mandatory_switch_miss = 337182760; + public final static int isc_err_max = 1170; /*******************/ /* SQL definitions */ Modified: client-java/trunk/src/messages/org/firebirdsql/util/MessageDump.java =================================================================== --- client-java/trunk/src/messages/org/firebirdsql/util/MessageDump.java 2012-11-17 03:40:35 UTC (rev 57357) +++ client-java/trunk/src/messages/org/firebirdsql/util/MessageDump.java 2012-11-17 10:42:26 UTC (rev 57358) @@ -1,3 +1,23 @@ +/* + * $Id$ + * + * Firebird Open Source J2EE Connector - JDBC Driver + * + * Distributable under LGPL license. + * You may obtain a copy of the License at http://www.gnu.org/copyleft/lgpl.html + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * LGPL License for more details. + * + * This file was created by members of the firebird development team. + * All individual contributions remain the Copyright (C) of those + * individuals. Contributors to this file are either listed here or + * can be obtained from a CVS history command. + * + * All rights reserved. + */ package org.firebirdsql.util; import java.io.*; @@ -4,22 +24,17 @@ import java.sql.*; import java.util.*; -import org.firebirdsql.jdbc.FBDriver; -import org.firebirdsql.jdbc.FirebirdConnection; - /** - * + * Utility class for generating the property files containing the errorcodes and error messages. */ public class MessageDump { private static final int ISC_CODE = 0x14000000; - private static FirebirdConnection getConnection(String database) - throws Exception { - Class.forName(FBDriver.class.getName()); + private static Connection getConnection(String database) throws Exception { + Class.forName("org.firebirdsql.jdbc.FBDriver"); String url = "jdbc:firebirdsql:" + database; - return (FirebirdConnection) DriverManager.getConnection(url, "SYSDBA", - "masterkey"); + return DriverManager.getConnection(url, "SYSDBA", "masterkey"); } private static int getErrorCode(int code, int number) { @@ -48,11 +63,11 @@ sb.append("%ld"); } else sb.append('%').append(chars[i]); - } else - if (chars[i] == '@') { + } else if (chars[i] == '@') { i++; try { + // Currently assumes parameter-number not to exceed 9. int msgNum = Integer.parseInt("" + chars[i]); sb.append('{').append(Integer.toString(msgNum - 1)).append('}'); } catch(NumberFormatException ex) { @@ -65,9 +80,8 @@ return sb.toString(); } - private static Properties extractProperties(FirebirdConnection connection) - throws Exception { - Properties result = new Properties(); + private static Map<Integer, String> extractErrorMessages(Connection connection) throws Exception { + Map<Integer, String> result = new TreeMap<Integer, String>(); Statement stmt = connection.createStatement(); try { @@ -79,20 +93,18 @@ int number = rs.getInt(2); String message = rs.getString(3); - result.setProperty( - Integer.toString(getErrorCode(code, number)), + result.put( + Integer.valueOf(getErrorCode(code, number)), extractMessage(message)); } - } finally { stmt.close(); } - return result; } - private static Properties extractSQLStates(FirebirdConnection connection) throws SQLException { - Properties result = new Properties(); + private static Map<Integer, String> extractSQLStates(Connection connection) throws SQLException { + Map<Integer, String> result = new TreeMap<Integer, String>(); Statement stmt = connection.createStatement(); try { @@ -104,11 +116,10 @@ int number = rs.getInt(2); String sqlState = rs.getString(3); - result.setProperty( - Integer.toString(getErrorCode(code, number)), + result.put( + Integer.valueOf(getErrorCode(code, number)), extractMessage(sqlState)); } - } finally { stmt.close(); } @@ -117,44 +128,49 @@ } public static void main(String[] args) throws Exception { + if (args.length == 0) { + args = new String[] { "localhost:d:/database/fb_messages.fdb" }; + } - if (args.length == 0) - args = new String[] { "localhost:d:/database/fb_messages.fdb"}; - - FirebirdConnection connection = getConnection(args[0]); + Connection connection = getConnection(args[0]); try { - Properties props = extractProperties(connection); - TreeMap sortedMap = new TreeMap(props); - - store(sortedMap, new FileOutputStream("./error.properties"), ""); + System.out.println("Retrieving error messages"); + final Map<Integer, String> errorMessages = extractErrorMessages(connection); + final FileOutputStream errorStream = new FileOutputStream("./error.properties"); + try { + store(errorMessages, errorStream, null); + } finally { + errorStream.close(); + } - props = extractSQLStates(connection); - TreeMap sqlStates = new TreeMap(props); - - store(sqlStates, new FileOutputStream("./sqlstates.properties"), ""); + System.out.println("Retrieving SQL State values"); + final Map<Integer, String> sqlStates = extractSQLStates(connection); + final FileOutputStream sqlstateStream = new FileOutputStream("./sqlstates.properties"); + try { + store(sqlStates, sqlstateStream, null); + } finally { + sqlstateStream.close(); + } } finally { connection.close(); } } - public static void store(Map map, OutputStream out, String header) + public static void store(Map<Integer, String> map, OutputStream out, String header) throws IOException { BufferedWriter awriter; awriter = new BufferedWriter(new OutputStreamWriter(out, "8859_1")); if (header != null) writeln(awriter, "#" + header); writeln(awriter, "#" + new java.util.Date().toString()); - synchronized (map) { - for (Iterator iter = map.entrySet().iterator(); iter.hasNext();) { - Map.Entry entry = (Map.Entry) iter.next(); - String key = saveConvert((String)entry.getKey(), true); + for (Map.Entry<Integer, String> entry : map.entrySet()) { + String key = saveConvert(Integer.toString(entry.getKey()), true); - /* - * No need to escape embedded and trailing spaces for value, - * hence pass false to flag. - */ - String val = saveConvert((String)entry.getValue(), false); - writeln(awriter, key + "=" + val); - } + /* + * No need to escape embedded and trailing spaces for value, + * hence pass false to flag. + */ + String val = saveConvert(entry.getValue(), false); + writeln(awriter, key + "=" + val); } awriter.flush(); } Modified: client-java/trunk/src/resources/isc_error_msg.properties =================================================================== --- client-java/trunk/src/resources/isc_error_msg.properties 2012-11-17 03:40:35 UTC (rev 57357) +++ client-java/trunk/src/resources/isc_error_msg.properties 2012-11-17 10:42:26 UTC (rev 57358) @@ -1,5 +1,4 @@ -# -#Tue Oct 19 20:41:05 CEST 2010 +#Sat Nov 17 11:26:48 CET 2012 335544320= 335544321=arithmetic exception, numeric overflow, or string truncation 335544322=invalid database key @@ -231,10 +230,10 @@ 335544548=Attempt to define a second PRIMARY KEY for the same table 335544549=cannot modify or erase a system trigger 335544550=only the owner of a table may reassign ownership -335544551=could not find table/procedure/package for GRANT +335544551=could not find object for GRANT 335544552=could not find column for GRANT 335544553=user does not have GRANT privileges for operation -335544554=table/procedure has non-SQL security class defined +335544554=object has non-SQL security class defined 335544555=column has non-SQL security class defined 335544556=Write-ahead Log without shared cache configuration not allowed 335544557=database shutdown unsuccessful @@ -516,7 +515,7 @@ 335544833=Physical backup is not allowed while Write-Ahead Log is in use 335544834=Cursor is not open 335544835=Target shutdown mode is invalid for database "{0}" -335544836=Concatenation overflow. Resulting string cannot exceed 32K in length. +335544836=Concatenation overflow. Resulting string cannot exceed 32765 bytes in length. 335544837=Invalid offset parameter {0} to SUBSTRING. Only positive integers are allowed. 335544838=Foreign key reference target does not exist 335544839=Foreign key references are present for the record @@ -669,8 +668,8 @@ 335544986=Explicit transaction control is not allowed 335544987=Use of TRUSTED switches in spb_command_line is prohibited 335544988=PACKAGE {0} -335544989=Cannot make field {0} NOT NULL because there are NULLs present -335544990=Feature {0} is deprecated +335544989=Cannot make field {0} of table {1} NOT NULL because there are NULLs present +335544990=Feature {0} is not supported anymore 335544991=VIEW {0} 335544992=Can not access lock files directory {0} 335544993=Fetch option {0} is invalid for a non-scrollable cursor @@ -685,7 +684,7 @@ 335545002=Attachment is in use 335545003=Transaction is in use 335545004=Plugin {0} not found -335545005=Cannot load plugin {0} +335545005=Module {0} exists, but can not be loaded 335545006=Entrypoint of plugin {0} does not exist 335545007=Invalid value {0} for parameter index at PluginImpl\:\:getConfigInfo\: out of bounds 335545008=Plugin {0} does not create {1} instances @@ -695,11 +694,38 @@ 335545012=Invalid date 335545013=Invalid time 335545014=Invalid timestamp -335545015=Invalid index {0} +335545015=Invalid index {0} in function {1} 335545016={0} 335545017=Asynchronous call is already running for this attachment 335545018=Function {0} is private to package {1} 335545019=Procedure {0} is private to package {1} +335545020=Request can't access new records in relation {0} and should be recompiled +335545021=invalid events id (handle) +335545022=Cannot copy statement {0} +335545023=Invalid usage of boolean expression +335545024=Arguments for {0} cannot both be zero +335545025=missing service ID in spb +335545026=External BLR message mismatch\: invalid null descriptor at field {0} +335545027=External BLR message mismatch\: length \= {0}, expected {1} +335545028=Subscript {0} out of bounds [{1}, {2}] +335545029=Install incomplete, please read chapter "Initializing security database" in Quick Start Guide +335545030={0} operation is not allowed for system table {1} +335545031=Libtommath error code {0} in function {1} +335545032=unsupported BLR version (expected between {0} and {1}, encountered {2}) +335545033=expected length {0}, actual {1} +335545034=Wrong info requested in isc_svc_query() for anonymous service +335545035=No isc_info_svc_stdin in user request, but service thread requested stdin data +335545036=Start request for anonymous service is impossible +335545037=All services except for getting server log require switches +335545038=Size of stdin data is more than was requested from client +335545039=Crypt plugin {0} failed to load +335545040=Length of crypt plugin name should not exceed {0} bytes +335545041=Crypt failed - already crypting database +335545042=Crypt failed - database is already in requested state +335545043=Missing crypt plugin, but page appears encrypted +335545044=No providers loaded +335545045=NULL data with non-zero SPB length +335545046=Maximum ({0}) number of arguments exceeded for function {1} 335609856=expected type 335609857=bad block type 335609858=bad block size @@ -1213,7 +1239,7 @@ 335610373=\ -b(uffers) set page buffers <n> 335610374=\ -f(etch_password) fetch password from file 335610375=\ -i(nit_script) startup script <name> -335610376=\ -n(o_banner) do not show the welcome message +335610376=\ -n(obanner) do not show the welcome message 335610377=\ -p(assword) user's password 335610378=\ -tra(ce) show internal parser's tokens 335610379=\ -tru(sted_auth) use trusted authentication @@ -1224,6 +1250,7 @@ 335610384=Start qli without [command] to enter interactive mode 335610385=qli\: ignoring unknown switch {0} 335610386=Warning\: cannot issue DDL statements against database "{0}" +335610387=\ -nod(btriggers) do not run database triggers 335740929=data base file name ({0}) already given 335740930=invalid switch {0} 335740931=gfix version {0} @@ -1374,6 +1401,7 @@ 336003101=UPDATE OR INSERT without MATCHING could not be used with views based on more than one table 336003102=Incompatible trigger type 336003103=Database trigger type can't be changed +336003104=To be used with RDB$RECORD_VERSION, {0} must be a table or a view of single table 336068609=ODS version not supported by DYN 336068610=unsupported DYN verb 336068611=STORE RDB$FIELD_DIMENSIONS failed @@ -1637,12 +1665,19 @@ 336068877=Package body {0} already exists 336068878=Invalid DDL statement for function {0} 336068879=Cannot alter new style function {0} with ALTER EXTERNAL FUNCTION. Use ALTER FUNCTION instead. -336068880=Cannot delete system generator +336068880=Cannot delete system generator {0} 336068881=Identity column {0} of table {1} must be of exact number type with zero scale 336068882=Identity column {0} of table {1} cannot be changed to NULLable 336068883=Identity column {0} of table {1} cannot have default value 336068884=Domain {0} must be of exact number type with zero scale because it's used in an identity column 336068885=Generation of generator name failed +336068886=Parameter {0} in function {1} not found +336068887=Parameter {0} of routine {1} not found +336068888=Parameter {0} of routine {1} is ambiguous (found in both procedures and functions). Use a specifier keyword. +336068889=Collation {0} is used in function {1} (parameter name {2}) and cannot be dropped +336068890=Domain {0} is used in function {1} (parameter nam... [truncated message content] |