site_node_apm_integration::get_child_package_id (public)

 site_node_apm_integration::get_child_package_id \
    [ -package_id package_id ] -package_key package_key

Defined in packages/acs-tcl/tcl/site-node-apm-integration-procs.tcl

Get the package_id of package_key that is mounted directly under package_id. This may become either a private interface or be deprecated in the future. In most cases, site_node::get_children is what you want. One difference is, this API is not cached, so it will always return the actual status from the database.

Switches:
-package_id
(optional)
-package_key
(required)
Returns:
empty string if not found.
See Also:

Partial Call Graph (max 5 caller/called nodes):
%3 test_attachments_enabled attachments_enabled (test calendar) site_node_apm_integration::get_child_package_id site_node_apm_integration::get_child_package_id test_attachments_enabled->site_node_apm_integration::get_child_package_id ad_conn ad_conn (public) site_node_apm_integration::get_child_package_id->ad_conn db_string db_string (public) site_node_apm_integration::get_child_package_id->db_string site_node_apm_integration::child_package_exists_p site_node_apm_integration::child_package_exists_p (public) site_node_apm_integration::child_package_exists_p->site_node_apm_integration::get_child_package_id

Testcases:
attachments_enabled
Source code:
        if {$package_id eq ""} {
            if {[ns_conn isconnected]} {
                set package_id [ad_conn package_id]
            } else {
                error "Not in a connection and no package_id provided"
            }
        }

        return [db_string select_child_package_id {} -default ""]
XQL Not present:
PostgreSQL, Oracle
Generic XQL file:
<fullquery name="site_node_apm_integration::get_child_package_id.select_child_package_id">
    <querytext>
            select sn1.object_id
            from site_nodes sn1,
                 apm_packages
            where sn1.parent_id = (select sn2.node_id
                                   from site_nodes sn2
                                   where sn2.object_id = :package_id)
            and sn1.object_id = apm_packages.package_id
            and apm_packages.package_key = :package_key
        </querytext>
</fullquery>
packages/acs-tcl/tcl/site-node-apm-integration-procs.xql

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