This repository has been archived on 2025-09-14. You can view files and clone it, but cannot push or open issues or pull requests.
Files
galaxy-deployment-updata-re…/TSG-21.03/Clickhouse/add_column.sql

191 lines
15 KiB
MySQL
Raw Normal View History

ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_call_id String after app_extra_info;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_call_id String after app_extra_info;
2021-02-24 12:33:18 +08:00
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_call_id String after app_extra_info;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_call_id String after app_extra_info;
2021-02-24 12:33:18 +08:00
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from String after sip_call_id;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from String after sip_call_id;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from String after sip_call_id;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from String after sip_call_id;
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to String after sip_from;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to String after sip_from;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to String after sip_from;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to String after sip_from;
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_user_agent String after sip_to;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_user_agent String after sip_to;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_user_agent String after sip_to;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_user_agent String after sip_to;
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_server String after sip_user_agent;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_server String after sip_user_agent;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_server String after sip_user_agent;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_server String after sip_user_agent;
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_connect_ip String after sip_server;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_connect_ip String after sip_server;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_connect_ip String after sip_server;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_connect_ip String after sip_server;
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_media_port Int64 after sip_from_sdp_connect_ip;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_media_port Int64 after sip_from_sdp_connect_ip;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_media_port Int64 after sip_from_sdp_connect_ip;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_media_port Int64 after sip_from_sdp_connect_ip;
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_media_type String after sip_from_sdp_media_port;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_media_type String after sip_from_sdp_media_port;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_media_type String after sip_from_sdp_media_port;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_media_type String after sip_from_sdp_media_port;
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_content String after sip_from_sdp_media_type;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_content String after sip_from_sdp_media_type;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_content String after sip_from_sdp_media_type;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_from_sdp_content String after sip_from_sdp_media_type;
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_connect_ip String after sip_from_sdp_content;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_connect_ip String after sip_from_sdp_content;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_connect_ip String after sip_from_sdp_content;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_connect_ip String after sip_from_sdp_content;
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_media_port Int64 after sip_to_sdp_connect_ip;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_media_port Int64 after sip_to_sdp_connect_ip;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_media_port Int64 after sip_to_sdp_connect_ip;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_media_port Int64 after sip_to_sdp_connect_ip;
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_media_type String after sip_to_sdp_media_port;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_media_type String after sip_to_sdp_media_port;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_media_type String after sip_to_sdp_media_port;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_media_type String after sip_to_sdp_media_port;
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_content String after sip_to_sdp_media_type;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_content String after sip_to_sdp_media_type;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_content String after sip_to_sdp_media_type;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_to_sdp_content String after sip_to_sdp_media_type;
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_duration Int64 after sip_to_sdp_content;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_duration Int64 after sip_to_sdp_content;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_duration Int64 after sip_to_sdp_content;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_duration Int64 after sip_to_sdp_content;
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_bye String after sip_duration;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_bye String after sip_duration;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_bye String after sip_duration;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS sip_bye String after sip_duration;
2021-02-24 14:01:31 +08:00
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_payload_type_c2s Nullable(Int64) after sip_bye;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_payload_type_c2s Nullable(Int64) after sip_bye;
2021-02-24 12:33:18 +08:00
2021-02-24 14:01:31 +08:00
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_payload_type_c2s Nullable(Int64) after sip_bye;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_payload_type_c2s Nullable(Int64) after sip_bye;
2021-02-24 12:33:18 +08:00
2021-02-24 14:01:31 +08:00
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_payload_type_s2c Nullable(Int64) after rtp_payload_type_c2s;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_payload_type_s2c Nullable(Int64) after rtp_payload_type_c2s;
2021-02-24 12:33:18 +08:00
2021-02-24 14:01:31 +08:00
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_payload_type_s2c Nullable(Int64) after rtp_payload_type_c2s;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_payload_type_s2c Nullable(Int64) after rtp_payload_type_c2s;
2021-02-24 12:33:18 +08:00
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_pcap_dir_c2s String after rtp_payload_type_s2c;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_pcap_dir_c2s String after rtp_payload_type_s2c;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_pcap_dir_c2s String after rtp_payload_type_s2c;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_pcap_dir_c2s String after rtp_payload_type_s2c;
ALTER TABLE connection_record_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_pcap_dir_s2c String after rtp_pcap_dir_c2s;
ALTER TABLE connection_record_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_pcap_dir_s2c String after rtp_pcap_dir_c2s;
ALTER TABLE security_event_log_local ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_pcap_dir_s2c String after rtp_pcap_dir_c2s;
ALTER TABLE security_event_log ON CLUSTER ck_cluster ADD COLUMN IF NOT EXISTS rtp_pcap_dir_s2c String after rtp_pcap_dir_c2s;
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_call_id String after app_extra_info;
2021-02-24 12:33:18 +08:00
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_call_id String after app_extra_info;
2021-02-24 12:33:18 +08:00
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_from String after sip_call_id;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_from String after sip_call_id;
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_to String after sip_from;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_to String after sip_from;
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_user_agent String after sip_to;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_user_agent String after sip_to;
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_server String after sip_user_agent;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_server String after sip_user_agent;
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_from_sdp_connect_ip String after sip_server;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_from_sdp_connect_ip String after sip_server;
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_from_sdp_media_port Int64 after sip_from_sdp_connect_ip;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_from_sdp_media_port Int64 after sip_from_sdp_connect_ip;
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_from_sdp_media_type String after sip_from_sdp_media_port;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_from_sdp_media_type String after sip_from_sdp_media_port;
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_from_sdp_content String after sip_from_sdp_media_type;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_from_sdp_content String after sip_from_sdp_media_type;
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_to_sdp_connect_ip String after sip_from_sdp_content;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_to_sdp_connect_ip String after sip_from_sdp_content;
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_to_sdp_media_port Int64 after sip_to_sdp_connect_ip;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_to_sdp_media_port Int64 after sip_to_sdp_connect_ip;
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_to_sdp_media_type String after sip_to_sdp_media_port;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_to_sdp_media_type String after sip_to_sdp_media_port;
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_to_sdp_content String after sip_to_sdp_media_type;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_to_sdp_content String after sip_to_sdp_media_type;
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_duration Int64 after sip_to_sdp_content;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_duration Int64 after sip_to_sdp_content;
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_bye String after sip_duration;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS sip_bye String after sip_duration;
2021-02-24 14:01:31 +08:00
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS rtp_payload_type_c2s Nullable(Int64) after sip_bye;
2021-02-24 12:33:18 +08:00
2021-02-24 14:01:31 +08:00
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS rtp_payload_type_c2s Nullable(Int64) after sip_bye;
2021-02-24 12:33:18 +08:00
2021-02-24 14:01:31 +08:00
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS rtp_payload_type_s2c Nullable(Int64) after rtp_payload_type_c2s;
2021-02-24 12:33:18 +08:00
2021-02-24 14:01:31 +08:00
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS rtp_payload_type_s2c Nullable(Int64) after rtp_payload_type_c2s;
2021-02-24 12:33:18 +08:00
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS rtp_pcap_dir_c2s String after rtp_payload_type_s2c;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS rtp_pcap_dir_c2s String after rtp_payload_type_s2c;
ALTER TABLE connection_record_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS rtp_pcap_dir_s2c String after rtp_pcap_dir_c2s;
ALTER TABLE security_event_log ON CLUSTER ck_query ADD COLUMN IF NOT EXISTS rtp_pcap_dir_s2c String after rtp_pcap_dir_c2s;