Use database schemas (fixes #229)