AnsweredAssumed Answered

Action Item Portlet | Sub-Object of Project -SQL help?

Question asked by alex.sinclair on Dec 22, 2011
Latest reply on Dec 22, 2011 by Dave
Hi,

A colleague is in need of some Christmas SQL help - anyone got any suggestions?

"I've created a sub-object from a Project and I'm trying to add Project ID and Name to the Action Item Portlet query but not able to.

Please find attached query that I'm currently working from. Any help would be much appreciated.


SELECT
AI.ID AI_ID,
P.ID PROJ_ID,
P.UNIQUE_NAME UN_NAME,
P.NAME PROJ_NAME,
AI.SUBJECT ACTION_SUBJECT,
AI.DESCRIPTION Description,
***.STATUS_code STATUS,
***.ASSIGNEE_ID ***_ID,
U.ID USER_ID
FROM
niku.CAL_ACTION_ITEMS AI
INNER JOIN niku.CAL_ACTION_ITEM_ASSIGNEES *** on AI.ID = ***.CAL_ACTION_ITEM_ID AND ***.STATUS_CODE = 'CAL_OPEN'
INNER JOIN niku.CMN_SEC_USERS U on ***.ASSIGNEE_ID = U.ID
LEFT OUTER JOIN niku.INV_INVESTMENTS P on P.ID = AI.OBJECT_ID
LEFT OUTER JOIN niku.ODF_CA_VISA_ESTIMATING_TPS ODF on ODF.ODF_PARENT_ID = P.ID


"This is the SQL statement used to pull the project details. "

LEFT OUTER JOIN niku.SRM_PROJECTS P on P.ID = AI.OBJECT_ID
LEFT OUTER JOIN niku.ODF_CA_VISA_ESTIMATING_TPS ODF on ODF.ODF_PARENT_ID = P.ID'

Many thanks in advance and hope everyone has a lovely Christmas!

Al

Outcomes