acs_mail_lite::section_id_of (private)
acs_mail_lite::section_id_of section_ref
Defined in packages/acs-mail-lite/tcl/email-inbound-procs.tcl
Returns section_id representing a section_ref. Section_ref has format of counting numbers separated by dot. Section_id is an integer. First used here by ns_imap body and adopted for general email part refs.
- Parameters:
- section_ref (required)
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- acs_mail_lite_inbound_procs_check
Source code: set section_id "" if { [regexp -- {^[0-9\.]*$} $section_ref ] } { if { $section_ref eq "" } { set section_id -1 } else { set ckey aml_section_ref_ append ckey $section_ref set exists_p [db_0or1row -cache_key $ckey acs_mail_lite_ie_section_ref_map_r1 { select section_id from acs_mail_lite_ie_section_ref_map where section_ref=:section_ref } ] if { !$exists_p } { db_flush_cache -cache_key_pattern $ckey set section_id [db_nextval acs_mail_lite_in_id_seq] db_dml acs_mail_lite_ie_section_ref_map_c1 { insert into acs_mail_lite_ie_section_ref_map (section_ref,section_id) values (:section_ref,:section_id) } } } } return $section_idXQL Not present: PostgreSQL, Oracle Generic XQL file: packages/acs-mail-lite/tcl/email-inbound-procs.xql