add_child

add_child

The add_child message provides information about a metadata item to be added to the database. An add_child message implies that the user is adding a leaf, folder or container to a given folder or container.

Add a Node to the Tree

To add a node to the tree, the sequence of events is as follows:

  1. The client requests to add a leaf or folder to a given (editable) parent node.

  2. The Ontology server performs the following steps:

    1. Parses the node information to obtain the key / table_cd

    2. Queries the TABLE_ACCESS table for the table name associated with the TABLE_CD

    3. Inserts the new leaf, folder or container into the Ontology metadata table

 

  1. The client populates the selected parent node with the new node.


add_child Request Message

An add_child message requires the user to specify the node to be added. No additional attribute settings are necessary.
Example:
<message_body>
<ns6:add_child>
<level>1</level>
<key>\\i2b2\Custom Ontology\Test folder{color:#0000ff}</key>
<name>Test folder</name>
<synonym_cd>N</synonym_cd>
<visualattributes>FAE</visualattributes>
<totalnum>0</totalnum>
<basecode />
<facttablecolumn>concept_cd</facttablecolumn>
<tablename>concept_dimension</tablename>
<columnname>concept_path</columnname>
<columndatatype>T</columndatatype>
<operator>LIKE</operator>
<dimcode>\Custom Ontology\Test folder{color:#0000ff}</dimcode>
<comment />
<tooltip>\ Custom Ontology \ Test folder</tooltip>
<sourcesystem_cd />
<valuetype_cd />
</ns6:add_child>
</message_body>

add_child Response Message

A status type of DONE or ERROR is specified in the response header. No specialized <message_body> is returned to the client.

<ac:structured-macro ac:macro-id="34d68a09-7950-42e9-9003-466c688593dd" ac:name="children" ac:schema-version="2">
<ac:parameter ac:name="all">true</ac:parameter>
</ac:structured-macro>