How to fetch details of nested relationships using AML query?

I have a requirement like

Main Phase can have relationship with Activities and Phases, also Phases can have child phases

eg:

i want to get the id of all  activity (itemtype2) if i provide id  of main phase is provided ? A phase can have no activity also.

  • Hi Hyder,

    You can check out the first section of this blog post on special aml actions for an example how to perform a recursive AML query which should help you get all of the Activities that you're looking for. 

    Chris


    Christopher Gillis

    Aras Labs Software Engineer

  • I tried something similar like this. But did not provide any result .(I am using 12Sp3)

    <AML>
    <Item type="prj_Phase" action="GetItemRepeatConfig" select ="id" >
     <id>Test_id</id>
        <Relationships>
        <Item type="prj_Phase Activity" action="get" select="related_id" >
             <related_id>
             <Item type="prj_Activity" action="get" select="state,name" ></Item>
              </related_id>
        </Item>
        <Item type="prj_Phase Child_Phase" action="get" select="related_id" >
         <related_id>
                <Item type="prj_Phase" repeatProp="related_id" repeatTimes="0" action="get" select="id" >
                    <Relationships></Relationships>
                 </Item>
           </related_id>
         </Item>
       </Relationships>
    </Item>
    </AML>