0 - 2 of 2 tags for 2620

Hello
I keep getting the above error message after the query below has been running for a minute or so.

I looked at this part...

left join (select CCT_External_ID, CCT_Agent_ID from GDW_VIEWS. CCT_AGENT where CCT_External_ID between '0' and '999999') Rep_Trans_IDs on Rep_Emp_IDs.emp_id=Rep_Trans_IDs.CCT_External_ID

 

Hello

I'm trying to run the following query and keep getting the above error message after the query has been running for a minute or so.

I've tried running it one where clause at a time, have removed the case when and fiddled around with it to try and identify where it is going wrong.

If anyone could help me I'd really appreciate it.

SELECT
T1.Call_Date
,(t1.Trading_Code||((t1.Account_Number/10)(FORMAT '9999999')))
,T1.Call_Type
,T1.BU_Desc
,SUM(CASE WHEN T4.Department_Group_Code IN ('M','W') THEN 'Fashion'
WHEN T4.Department_Group_Code IN ('F') THEN 'Footwear'