call table_for with class instead of records