Added database connectivity
Merge branch 'queries'