xo::db::sql::acs_mail_body proc new (public)
xo::db::sql::acs_mail_body new [ -dbn dbn ] [ -body_id body_id ] \ [ -body_reply_to body_reply_to ] [ -body_from body_from ] \ [ -body_date body_date ] [ -header_message_id header_message_id ] \ [ -header_reply_to header_reply_to ] \ [ -header_subject header_subject ] [ -header_from header_from ] \ [ -header_to header_to ] [ -content_item_id content_item_id ] \ [ -object_type object_type ] [ -creation_date creation_date ] \ [ -creation_user creation_user ] [ -creation_ip creation_ip ] \ [ -context_id context_id ] [ -childof childof ]
Defined in /var/www/openacs.org/packages/xotcl-core/tcl/05-db-procs.tcl
Automatically generated method
- Switches:
- -dbn (optional)
- -body_id (optional)
- -body_reply_to (optional)
- -body_from (optional)
- -body_date (optional)
- -header_message_id (optional)
- -header_reply_to (optional)
- -header_subject (optional)
- -header_from (optional)
- -header_to (optional)
- -content_item_id (optional)
- -object_type (optional, defaults to
"acs_mail_body"
)- -creation_date (optional, defaults to
"now()"
)- -creation_user (optional)
- -creation_ip (optional)
- -context_id (optional)
- -childof (optional)
- Testcases:
- No testcase defined.
Source code: #function_args: {BODY_ID null} {BODY_REPLY_TO null} {BODY_FROM null} {BODY_DATE null} {HEADER_MESSAGE_ID null} {HEADER_REPLY_TO null} {HEADER_SUBJECT null} {HEADER_FROM null} {HEADER_TO null} {CONTENT_ITEM_ID null} {OBJECT_TYPE acs_mail_body} {CREATION_DATE now()} {CREATION_USER null} {CREATION_IP null} {CONTEXT_ID null} foreach var [list BODY_ID BODY_REPLY_TO BODY_FROM BODY_DATE HEADER_MESSAGE_ID HEADER_REPLY_TO HEADER_SUBJECT HEADER_FROM HEADER_TO CONTENT_ITEM_ID OBJECT_TYPE CREATION_DATE CREATION_USER CREATION_IP CONTEXT_ID] { set varname [string tolower $var] if {[info exists $varname]} { set $var [set $varname] set _$var :$var } else { set _$var null } } set sql " select acs_mail_body__new($_BODY_ID, $_BODY_REPLY_TO, $_BODY_FROM, $_BODY_DATE, $_HEADER_MESSAGE_ID, $_HEADER_REPLY_TO, $_HEADER_SUBJECT, $_HEADER_FROM, $_HEADER_TO, $_CONTENT_ITEM_ID, $_OBJECT_TYPE, $_CREATION_DATE, $_CREATION_USER, $_CREATION_IP, $_CONTEXT_ID) " db_with_handle -dbn $dbn db { #ns_log notice "--sql=$sql" return [ ns_set value [ns_pg_bind 0or1row $db $sql] 0 ] }XQL Not present: Generic, PostgreSQL, Oracle