connect settings to db