added db name as an options parameter