[Previous] [Next] [Contents]

EasySQL is developed to be highly configurable at run time. There is global configuration file with site wide common defaults and paths and per database descriptions.

Main and common for all EasySQL based programs on a host is `easysql.conf' configuration file. When an EasySQL based application first refer to any EasySQL method it searches for this file first in `/usr/local/etc' and then in `/etc' directories. Configuration file may not present at all -- default values are used in that case.

Global configuration file consists from text lines; empty lines and lines beginning with `#' are ignored. Actual lines are formed from directive name and value separated by spaces and/or tabulations. Only leading and trailing spaces are removed from values, no any other processing is done.

Here is an alphabetical list of directives which you may use in `easysql.conf' file:


A directory in which database's descriptions are located (default value is formed by appending `databases' postfix to base directory name -- usually `/usr/local/easysql/databases'). It's hard to imagine situation where this should be redefined.


A directory in which dynamically loaded drivers are located (default is `drivers' subdirectory in EasySQL home).


Root directory of all EasySQL tree (default value is `/usr/local/easysql').


A name of log file, to which all error messages, warnings and debug information are stored. If the name is not started from slash it's related to EasySQL home directory. If the name is `stderr' (case insensitive) then messages are logged to standard error stream (this is default behavior). And if it is `none' then no logging is done. It may be configured on per application basis at run time -- see easysql_set_log_file() API call description.


A level at which logging information is chopped -- bit mapped value between 0 and 65535; may be specified as decimal or hexadecimal value (prefixed by 0x). This parameter only sets the default value which may be overridden by API call at run time. See easysql_set_log_level() API call description for more information.


Should every line of debug output be flushed to disk (`yes') or no (`no'), the default is no. Try to switch to `yes' if your program locks up and you see nothing in log.


This may have `no', `false', `deny' values if an ability to search for databases in user's `~/.easysql' directories should be disabled; or `yes', 'true' or `allow' otherwise. This defines `site policy' and there is no way to change this from API for now -- but it is a discussable topic. Even if user configs are enabled EasySQL first looks for database in system directory and only then in user's one.

[Previous] [Next] [Contents]