/*******Main Section**************************************************************************/
\set ON_ERROR_STOP on
\set AUTOCOMMIT on
\timing on
delete from p10_sa.S98_livechat
;
insert into p10_sa.S98_livechat
(	 conference_id  
	, create_date  
	, start_date  
	, start_url  
	, referrer  
	, chat_dura  
	, queue_dura  
	, visitor_id  
	, visit_nick  
	, visitor_ip  
	, visitor_email  
	, operator_id  
	, group_id  
	, group_name  
	, rate  
	, last_rate_comment  
	, operator_1_nick  
	, operator_2_nick  
	, operator_3_nick  
	, operator_4_nick  
	, etl_tx_dt   )
  select 
	 conference_id  
	, create_date  
	, start_date  
	, start_url  
	, referrer  
	, chat_dura  
	, queue_dura  
	, visitor_id  
	, visit_nick  
	, visitor_ip  
	, visitor_email  
	, operator_id  
	, group_id  
	, group_name  
	, rate  
	, last_rate_comment  
	, operator_1_nick  
	, operator_2_nick  
	, operator_3_nick  
	, operator_4_nick  
	, etl_tx_dt  
  from p00_tal.S98_livechat
  ;
  delete from p12_sfull.S98_livechat
;
;
insert into p12_sfull.S98_livechat
(	 conference_id  
	, create_date  
	, start_date  
	, start_url  
	, referrer  
	, chat_dura  
	, queue_dura  
	, visitor_id  
	, visit_nick  
	, visitor_ip  
	, visitor_email  
	, operator_id  
	, group_id  
	, group_name  
	, rate  
	, last_rate_comment  
	, operator_1_nick  
	, operator_2_nick  
	, operator_3_nick  
	, operator_4_nick  
	, etl_tx_dt   )
  select 
	 conference_id  
	, create_date  
	, start_date  
	, start_url  
	, referrer  
	, chat_dura  
	, queue_dura  
	, visitor_id  
	, visit_nick  
	, visitor_ip  
	, visitor_email  
	, operator_id  
	, group_id  
	, group_name  
	, rate  
	, last_rate_comment  
	, operator_1_nick  
	, operator_2_nick  
	, operator_3_nick  
	, operator_4_nick  
	, etl_tx_dt  
  from p10_sa.S98_livechat
;
\q