site_node::rename (public)

 site_node::rename -node_id node_id -name name

Defined in packages/acs-tcl/tcl/site-nodes-procs.tcl

Rename the site node.

Switches:
-node_id (required)
-name (required)

Testcases:
site_node_update_cache
Source code:
    # We need to update the cache for all the child nodes as well
    set node_url [get_url -node_id $node_id]
    set child_node_ids [get_children -all -node_id $node_id -element node_id]
    set node_object_id [dict get [site_node::get -node_id $node_id] object_id]

    db_dml rename_node {}
    db_dml update_object_title {}

    update_cache -sync_children -node_id $node_id -url $node_url -object_id $node_object_id
Generic XQL file:
<fullquery name="site_node::rename.rename_node">
    <querytext>
            update site_nodes
            set    name = :name
            where  node_id = :node_id
        </querytext>
</fullquery>

<fullquery name="site_node::rename.update_object_title">
    <querytext>
            update acs_objects
            set    title = :name
            where  object_id = :node_id
        </querytext>
</fullquery>
packages/acs-tcl/tcl/site-nodes-procs.xql

PostgreSQL XQL file:
packages/acs-tcl/tcl/site-nodes-procs-postgresql.xql

Oracle XQL file:
packages/acs-tcl/tcl/site-nodes-procs-oracle.xql

[ hide source ] | [ make this the default ]
Show another procedure: