db_type (public)

 db_type

Defined in packages/acs-tcl/tcl/01-database-procs.tcl

Returns:
the RDBMS type (i.e. oracle, postgresql) this OpenACS installation is using. The nsv ad_database_type is set up during the bootstrap process.

Testcases:
db_bind_var_substitution, nullchar, sql_date
Source code:
    #
    # Currently this should always be either "oracle" or "postgresql":
    # --atp@piskorski.com, 2003/03/16 22:01 EST
    #
    # First check, if the database type exists in the namespaced
    # variable. This should be always the case. If this fail, fall
    # back to the old-style nsv (which can be costly in tight db loops)
    #
    if {[info exists ::acs::database_type]} {
        set result $::acs::database_type
    } else {
        set result [nsv_get ad_database_type .]
        ns_log Warning "db_type '$result' had to be obtained from the nsv 'ad_database_type'"
        set ::acs::database_type $result
    }
    return $result
XQL Not present:
Generic, PostgreSQL, Oracle
[ hide source ] | [ make this the default ]
Show another procedure: