forum::get (public)

 forum::get -forum_id forum_id -array array

Defined in packages/forums/tcl/forums-procs.tcl

get the fields for a forum

Switches:
-forum_id
(required)
-array
(required)
Returns:

Partial Call Graph (max 5 caller/called nodes):
%3 test_forum_count_test forum_count_test (test forums) forum::get forum::get test_forum_count_test->forum::get test_web_forum_edit web_forum_edit (test forums) test_web_forum_edit->forum::get test_web_forum_view web_forum_view (test forums) test_web_forum_view->forum::get test_web_forums_message_and_reply web_forums_message_and_reply (test forums) test_web_forums_message_and_reply->forum::get db_0or1row db_0or1row (public) forum::get->db_0or1row callback::search::datasource::impl::forums_message callback::search::datasource::impl::forums_message (private) callback::search::datasource::impl::forums_message->forum::get forum::attachments_enabled_p forum::attachments_enabled_p (public) forum::attachments_enabled_p->forum::get forum::edit forum::edit (public) forum::edit->forum::get forum::new_questions_allowed_p forum::new_questions_allowed_p (public, deprecated) forum::new_questions_allowed_p->forum::get forum::security::can_post_forum_p forum::security::can_post_forum_p (public) forum::security::can_post_forum_p->forum::get

Testcases:
forum_count_test, web_forum_view, web_forum_edit, web_forums_message_and_reply
Source code:
    # Select the info into the upvar'ed Tcl Array
    upvar $array row

    set global_varname ::forum_${forum_id}

    if {[info exists $global_varname]} {
        array set row [array get $global_varname]
    } else {
        if {![db_0or1row select_forum {} -column_array row]} {
            error "Forum $forum_id not found" {} NOT_FOUND
        }
        array set $global_varname [array get row]
    }
Generic XQL file:
<fullquery name="forum::get.select_forum">
    <querytext>
            select forums_forums.*
            from forums_forums
            where forums_forums.forum_id = :forum_id
        </querytext>
</fullquery>
packages/forums/tcl/forums-procs.xql

PostgreSQL XQL file:
packages/forums/tcl/forums-procs-postgresql.xql

Oracle XQL file:
packages/forums/tcl/forums-procs-oracle.xql

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