db_list_of_lists (public)
db_list_of_lists [ -dbn dbn ] [ -cache_key cache_key ] \ [ -cache_pool cache_pool ] [ -with_headers ] [ -subst subst ] \ [ -columns_var columns_var ] statement_name sql [ -bind bind ]
Defined in packages/acs-tcl/tcl/01-database-procs.tcl
- Switches:
- -dbn (optional)
- The database name to use. If empty_string, uses the default database.
- -cache_key (optional)
- Cache the result using given value as the key. Default is to not cache.
- -cache_pool (optional, defaults to
"db_cache_pool"
)- Override the default db_cache_pool
- -with_headers (optional, boolean)
- when specified, first line of returned list of lists will always be the list of column names as reported by the database. Useful when you want to dynamically assign variables to values returned in the list of lists.
- -subst (optional, defaults to
"all"
)- Perform Tcl substitution in xql-files. Possible values: all, none, vars, commands
- -columns_var (optional)
- -bind (optional)
- bind variables, passed either as an ns_set id, or via bind value list
- Parameters:
- statement_name (required)
- name of the SQL query.
- sql (required)
- SQL query to be executed.
- Returns:
- a Tcl list, each element of which is a list of all column values in a row of the result of the SQL querysql. If sql doesn't return any rows, returns an empty list, unless with_headers flag was specified and in this case the only element in the list will be the list of headers. It checks if the element is I18N and replaces it, thereby reducing the need to do this with every single package
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- auth_authority_api, parameter__check_procs, db__caching, db__list_variants