→ 🚀What's New? Join Us for the Fall Product Launch! Register Now !
‎11-21-2017 09:30 AM
Select Top 1000000 htblticket.ticketid,
'#' + Cast(htblticket.ticketid As nvarchar) As Ticket,
htblticket.subject As Betreff,
htblusers.name As Benutzer,
htblticketstates.statename As Status,
htblusers1.name As Agent,
htblticket.date As Erstellt,
htblticket.updated As Bearbeitet,
'../helpdesk/icons/' + htbltickettypes.icon As icon
From htblticket
Inner Join htblpriorities On htblpriorities.priority = htblticket.priority
Inner Join htblticketstates On htblticketstates.ticketstateid =
htblticket.ticketstateid
Inner Join htblusers On htblusers.userid = htblticket.fromuserid
Left Join htblagents On htblagents.agentid = htblticket.agentid
Left Join htblusers htblusers1 On htblusers1.userid = htblagents.userid
Inner Join htbltickettypes On htblticket.tickettypeid =
htbltickettypes.tickettypeid
Inner Join htblsource On htblticket.sourceid = htblsource.sourceid
Inner Join htblusers htblusers2 On htblticket.userid_lastnote =
htblusers2.userid
Where htblticketstates.statename <> 'Closed' And htblticket.spam <> 'True'
Order By htblticket.ticketid
‎12-01-2017 08:08 AM
‎11-21-2017 02:24 PM
Select Top 1000000 htblticket.ticketid,
'#' + Cast(htblticket.ticketid As nvarchar) As Ticket,
htblticket.date As CreationDate,
htblticket.updated As LastUpdated,
htbltickettypes.typename As Type,
htblticketstates.statename As State,
htblpriorities.name As Priority,
htblsource.name As Source,
htblusers.name As [User],
htblusers1.name As AssignedAgent,
htblusers2.name As UserLastNote,
htblusers3.name As SubscribedAgent,
'../helpdesk/icons/' + htbltickettypes.icon As icon,
htblticket.subject As Subject
From htblticket
Inner Join htblpriorities On htblpriorities.priority = htblticket.priority
Inner Join htblticketstates On htblticketstates.ticketstateid =
htblticket.ticketstateid
Inner Join htblusers On htblusers.userid = htblticket.fromuserid
Left Join htblagents On htblagents.agentid = htblticket.agentid
Left Join htblusers htblusers1 On htblusers1.userid = htblagents.userid
Inner Join htbltickettypes On htblticket.tickettypeid =
htbltickettypes.tickettypeid
Inner Join htblsource On htblticket.sourceid = htblsource.sourceid
Inner Join htblusers htblusers2 On htblticket.userid_lastnote =
htblusers2.userid
Inner Join htblticketsubscribers On htblticket.ticketid =
htblticketsubscribers.ticketid
Inner Join htblagents htblagents1 On htblagents1.agentid =
htblticketsubscribers.agentid
Inner Join htblusers htblusers3 On htblusers3.userid = htblagents1.userid
Where (htblticketstates.statename <> 'Closed' And htblusers1.name =
'Agent ' And htblticket.spam <> 'True')Or
(htblticketstates.statename <> 'Closed' And htblusers3.name = 'Agent '
And htblticket.spam <> 'True')
Order By htblticket.ticketid
‎11-21-2017 01:26 PM
Select Top 1000000 htblticket.ticketid,
'#' + Cast(htblticket.ticketid As nvarchar) As Ticket,
htblticket.date As CreationDate,
htblticket.updated As LastUpdated,
htbltickettypes.typename As Type,
htblticketstates.statename As State,
htblpriorities.name As Priority,
htblsource.name As Source,
htblusers.name As [User],
htblusers1.name As AssignedAgent,
htblusers2.name As UserLastNote,
htblusers3.name As SubscribedAgent,
'../helpdesk/icons/' + htbltickettypes.icon As icon,
htblticket.subject As Subject
From htblticket
Inner Join htblpriorities On htblpriorities.priority = htblticket.priority
Inner Join htblticketstates On htblticketstates.ticketstateid =
htblticket.ticketstateid
Inner Join htblusers On htblusers.userid = htblticket.fromuserid
Left Join htblagents On htblagents.agentid = htblticket.agentid
Left Join htblusers htblusers1 On htblusers1.userid = htblagents.userid
Inner Join htbltickettypes On htblticket.tickettypeid =
htbltickettypes.tickettypeid
Inner Join htblsource On htblticket.sourceid = htblsource.sourceid
Inner Join htblusers htblusers2 On htblticket.userid_lastnote =
htblusers2.userid
Inner Join htblticketsubscribers On htblticket.ticketid =
htblticketsubscribers.ticketid
Inner Join htblagents htblagents1 On htblagents1.agentid =
htblticketsubscribers.agentid
Inner Join htblusers htblusers3 On htblusers3.userid = htblagents1.userid
Where htblticketstates.statename <> 'Closed' And htblusers3.name = 'Agent ' And
htblticket.spam <> 'True'
Order By htblticket.ticketid
Experience Lansweeper with your own data. Sign up now for a 14-day free trial.
Try Now