cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
jlennon101
Engaged Sweeper
Hi,

I have a report to show the tickets closed in the last 30 days, i now need to show the agent assigned to the ticket within this report i believe the info i need is in htblticketssummary however every time I add this to the report my report goes from 3000+ results to no results does anyone know what is needed for this report to work?


Code for the last 30 days report:

Select Top 1000000 htblticket.ticketid,
htblticket.subject,
htblticket.priority,
htblticket.date,
htblticket.updated,
htblticketstates.statename,
htblusers.name,
htblticket.assetid
From htblticket
Inner Join htblticketstates On htblticketstates.ticketstateid =
htblticket.ticketstateid
Inner Join htblusers On htblusers.userid = htblticket.fromuserid,
htbltickettypes
Where htblticket.updated > GetDate() - 30 And htblticketstates.statename =
'Closed'
1 REPLY 1
Niko0
Engaged Sweeper III
Select Top 1000000 htblticket.ticketid,
htblticket.subject,
htblusers1.name As Agent,
htblusers.name As Requester,
htblticket.priority,
htblticket.date,
htblticket.updated,
htblticketstates.statename,
htblticket.assetid
From htblticket
Inner Join htblnotes On htblticket.ticketid = htblnotes.ticketid
Inner Join htblusers On htblusers.userid = htblticket.fromuserid
Inner Join htblticketstates On htblticketstates.ticketstateid =
htblticket.ticketstateid
Inner Join htblagents On htblagents.agentid = htblticket.agentid
Inner Join htblusers htblusers1 On htblusers1.userid = htblagents.userid And
htblusers.userid = htblnotes.userid
Where htblticket.updated > GetDate() - 30 And htblticketstates.statename =
'Closed'