xo::db::sql::notification_request proc new (public)

 xo::db::sql::notification_request[i] new [ -dbn dbn ] \
    -request_id request_id  [ -object_type object_type ] \
    -type_id type_id  -user_id user_id  -object_id object_id  \
    -interval_id interval_id  -delivery_method_id delivery_method_id  \
    -format format  [ -dynamic_p dynamic_p ] \
    -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)
-request_id (required)
-object_type (optional, defaults to "notification_request")
-type_id (required)
-user_id (required)
-object_id (required)
-interval_id (required)
-delivery_method_id (required)
-format (required)
-dynamic_p (optional, defaults to "f")
-creation_date (required)
-creation_user (required)
-creation_ip (required)
-context_id (required)
-childof (optional)

Testcases:
No testcase defined.
Source code:
#function_args: {REQUEST_ID {}} {OBJECT_TYPE notification_request} {TYPE_ID {}} {USER_ID {}} {OBJECT_ID {}} {INTERVAL_ID {}} {DELIVERY_METHOD_ID {}} {FORMAT {}} {DYNAMIC_P f} {CREATION_DATE {}} {CREATION_USER {}} {CREATION_IP {}} {CONTEXT_ID {}}
foreach var [list REQUEST_ID OBJECT_TYPE TYPE_ID USER_ID OBJECT_ID INTERVAL_ID DELIVERY_METHOD_ID FORMAT DYNAMIC_P 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 notification_request__new($_REQUEST_ID$_OBJECT_TYPE$_TYPE_ID$_USER_ID$_OBJECT_ID$_INTERVAL_ID$_DELIVERY_METHOD_ID$_FORMAT$_DYNAMIC_P$_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
[ hide source ] | [ make this the default ]
Show another procedure: