Set database configuration from uri