database environment variable support added