NestedIntervalUtils - moveNode(GlideRecord node, Number position)

Moves a node to the specified child position [child_position] under the parent.

For example, passing 3 as the position parameter moves the node to the third position in the list of children.

Table 1. Parameters
Name Type Description
node GlideRecord Node whose position is to be modified
position Number New child position [child_position] for the node under its parent
Table 2. Returns
Type Description
Number Status:
  • 1 = success
  • 2 = duplicate (relationship already exists)
  • 3 = recursive
  • 4 = invalid data
  • -1 = database error