Issue:
Below applet search spec is not working. On UI all Approved records are also showing.
[Primary Owner Id] = LoginId() AND [Status] <> LookupValue("EVENT_STATUS", "Approved")
Analysis:
For Logs found that Siebel is not picking the correct Status column of S_EVT_ACT table.
Actual column is S_EVT_ACT.EVT_STAT_CD for status field.
Siebel is picking wrong column from wrong table: S_ACT_EMP.ACT_EVT_STAT_CD
Query part from logs:
T1.EMP_ID = :2 AND T33.ROW_ID = T1.ACTIVITY_ID AND
T1.EMP_ID = T21.ROW_ID AND
T33.TARGET_PER_ID = T29.ROW_ID (+) AND
T33.TARGET_PER_ID = T7.PAR_ROW_ID (+) AND
T33.PR_PRDINT_ID = T27.ROW_ID (+) AND
T27.PRDINT_ID = T23.ROW_ID (+) AND
T33.TARGET_OU_ADDR_ID = T19.ROW_ID (+) AND
((T33.OWNER_PER_ID = :3 AND T1.ACT_EVT_STAT_CD NOT IN ( :4 )) AND
(T33.X_ENTITY_TYPE = 'Research') AND
(T33.CREATED >= TO_DATE(:6,'MM/DD/YYYY HH24:MI:SS')))
ORDER BY
T33.CREATED DESC
Work around:
Create a calculated field in Business Component as below:
Name: Status LIC
Value: LookupName ("EVENT_STATUS", [Status])
Now change the Applet search spec to below:
[Primary Owner Id] = LoginId() AND [Status LIC] <> "Approved"
Compile and test.
Comments
Post a Comment