AnsweredAssumed Answered

Insert a new record into a multi-valued lookup field via gel script

Question asked by mnavarrocsx on Apr 24, 2015
Latest reply on Apr 28, 2015 by mnavarrocsx

I'm having trouble trying to insert a new project id using the <gel:set> statement

 

The file structure of the xog output file looks like this, and I parsed this output below.

 

<NikuDataBus xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../xsd/nikuxog_customObjectInstance.xsd">

  <Header action="write" externalSource="NIKU" objectType="customObjectInstance" version="13.3.0.286"/>

  <customObjectInstances objectCode="prj_inst_rights">

  <instance instanceCode="00000063" objectCode="prj_inst_rights">

  <CustomInformation>

  <ColumnValue name="prj">

  <Value>5141770</Value>

  <Value>5225745</Value>

  <Value>5226744</Value>

  <Value>5272757</Value>

  </ColumnValue>

  <ColumnValue name="assign">false</ColumnValue>

  <ColumnValue name="res">S5379</ColumnValue>

  <ColumnValue name="partition_code">NIKU.ROOT</ColumnValue>

  <ColumnValue name="name">00000063</ColumnValue>

  <ColumnValue name="code">00000063</ColumnValue>

  <ColumnValue name="page_layout">odf.prj_inst_rightsFrame</ColumnValue>

  <ColumnValue name="odf_period_start"/>

  <ColumnValue name="odf_period_end"/>

  </CustomInformation>

  <OBSAssocs complete="false"/>

  </instance>

  </customObjectInstances>

 

 

I parse the new value I would like to enter:

 

<gel:parse var="insert_right">

                  <Value>${prj_id}</Value>

</gel:parse>

 

Here is my insert statement:

 

<gel:set insert="true" select="$update_record/NikuDataBus/customObjectInstances/instance/CustomInformation/ColumnValue[@name='prj']/Value"var="insert_right"/>

 

Any help or comments about what I'm doing wrong? Please let me know! Thanks!

Outcomes