DB table definition and builder