Hi,
What is wrong with this statement?
SELECT Campaign.BillingState, Count(Campaign.BillingState)
FROM Campaign INNER JOIN Mcalcode ON
Campaign.CallResultCode = Mcalcode.CallResultCode
GROUP BY Campaign.BillingState, Mcalcode.Redialable, DateDiff(d,DateTimeofCall,getDate()) > 24
HAVING Mcalcode.Redialable=1
I get an error:
Server: Msg 170, Level 15, State 1, Line 4
Line 4: Incorrect syntax near '>'.
Without the ">" condition the Query works but not the type of output I need. It does not do the Aggregate thing.
Thanks
Mike
What is wrong with this statement?
SELECT Campaign.BillingState, Count(Campaign.BillingState)
FROM Campaign INNER JOIN Mcalcode ON
Campaign.CallResultCode = Mcalcode.CallResultCode
GROUP BY Campaign.BillingState, Mcalcode.Redialable, DateDiff(d,DateTimeofCall,getDate()) > 24
HAVING Mcalcode.Redialable=1
I get an error:
Server: Msg 170, Level 15, State 1, Line 4
Line 4: Incorrect syntax near '>'.
Without the ">" condition the Query works but not the type of output I need. It does not do the Aggregate thing.
Thanks
Mike