database schema with services