Grid Columns in B1 Dashboard
Hi there,
Hope someone can help with this.
I have the following code to show open service calls;
SELECT DISTINCT T0.[DocNum] AS 'ServiceCallNumber',
T0.callID,
T0.[custmrName],
T1.[Name],
T0.[StartDate],
T0.[U_ZONE],
T2.[Name],
(SELECT TOP 1 CASE WHEN A.ClgID IS NOT NULL THEN 'Y' ELSE '' END FROM OSCL B INNER JOIN SCL5 A ON B.callID = A.SrvcCallID AND B.callID = T0.callID) AS 'Activity'
FROM OSCL T0
INNER JOIN OSCT T1 ON T0.callType = T1.callTypeID
INNER JOIN OSCS T2 ON T0.status = T2.statusID
WHERE T2.[Name] NOT IN ('Closed','Pending') AND
T0.[assignee] NOT IN (7,19)
ORDER BY T0.[StartDate] ASC
This code is used for a grid on the dashboard, the problem is though that if a customer has more than one service call its only showing one call based on that type (or none at all if its summing the callid)
How can I show each unique record instead of having to choose from count, count distinct, sum, min, max etc as i dont need any of these but it seems you have to select one?
For example, if customer X has a few service calls with ID's 8120, 1230, 13456. Instead of showing a row for each call it is giving me 1 row that has a callID that is the sum of all these (and doesnt exist).
Any help is appreciated.
Nick
-
This has been fixed, realised I had to change it to a dimension (duh)
Please sign in to leave a comment.
Comments
1 comment