Good afternoon
I have around 5 tables I want to create one overall query from, but I am coming up against an issue when creating my first join
I use the code below to pull agent names etc... from a source table which is ok, but I will need to add the 2nd query below
I will need to do around 5 more queries like "Query2" but no matter what I try I cannot work out which join is best as I want the data to be to the right of the "initial Query" and how I would work out the multiple WHERE clauses and table naming. I have had a look and I have tried several ways of doing this but I usually get an error either with the JOIN or syntax issue
code works on The following to calculate a field on its own
thanks in advance
Gavin
I have around 5 tables I want to create one overall query from, but I am coming up against an issue when creating my first join
I use the code below to pull agent names etc... from a source table which is ok, but I will need to add the 2nd query below
I will need to do around 5 more queries like "Query2" but no matter what I try I cannot work out which join is best as I want the data to be to the right of the "initial Query" and how I would work out the multiple WHERE clauses and table naming. I have had a look and I have tried several ways of doing this but I usually get an error either with the JOIN or syntax issue
Code:
Initial Query
select [AgentID], [Name], [SDate], [Lead] AS [Department Lead], [Team Leader]
from Table1
Where CISCOID is not null and [CX_Lead] = 'Nxxxme' and [Title] = 'Standard'
code works on The following to calculate a field on its own
Code:
Query2
SELECT [Cdate] as [Call Date], count([AgentID]) as [IB]
FROM Table2
WHERE (((Table2.[Lead])='Name') AND ((Table2.[Flag])='Handled'))
GROUP BY Table2.[CDate], Table2.[agent], Table2.[Manager];
thanks in advance
Gavin