Attribute-based table mapping and simple database access