I want to validate the project's fields using gel/xog such as Project's status,Project's financial status, Resource status and region.
Does anyone else have anything to suggest?
I tried to pulled up the query and i don't know. How to add the validations based on query filter.
Below codes are my understanding as of now.
select srm.ID,srm.First_Name,invp.IS_PROGRAM,invp.IS_TEMPLATE,inv.CODE,inv.IS_ACTIVE "PROJECT_ACTIVE",inv.STATUS "PROJECT STATUS",pac.STATUS "FINANCIAL_STATUS",odf.Z_RGN "REGION",odf.z_lead_comp "LEAD_COMPANY"fromSRM_RESOURCES srmJOIN PRTEAM prt ON srm.ID=prt.PRRESOURCEIDJOIN INV_PROJECTS invp ON invp.PRID=prt.PRIDJOIN INV_INVESTMENTS inv ON inv.ID=invp.PRIDJOIN PAC_MNT_PROJECTS pac ON pac.ID=inv.IDJOIN ODF_CA_PROJECT odf ON odf.ID=pac.IDWhere invp.IS_PROGRAM=0and invp.IS_TEMPLATE=0and inv.IS_ACTIVE=1and inv.STATUS=1and pac.STATUS='O'and odf.Z_RGN=4and odf.z_lead_comp in(38,39);
on the above i have added some filters on the query. I need to validate the above code based on that results and build the update query for displaying the status in Custom Table. (Forex.update odf_ca_z_if_history set z_process_flag=2 where code='PR0001')
If you are validating project related attributes information includes project financials then no need to include prteam table in your query
SRM_RESOURCES srmJOIN PRTEAM prt ON srm.ID=prt.PRRESOURCEID
Thanks for your informations!!!
I missed out 1 point in previous conversations,
I need to validate resource details as well. Like, whether the resource is active or not. hence i added the resource table in that Query.
Do I understand your question correctly: you your query retrieves the records that do not meet your validation criteria and
then you want to store the data for not matching records to a custom object.
If that is the question and your query is already retrieving the correct data then you need to write the query results into the custom object already existing with the required fields. The following thread could help you with the XOG part.