DB schema and conversion