Untitled
public python v1 · immutableThe query I want to be executed:sql="SELECT COUNT(table1.id) as nr FROM table1 WHERE table1.id <= %s AND table1.group = %s" % \ (current_row.id, current_row.group)Its context:mapper(MyObject, my_table, properties={ 'group' : my_table.c.gr, #obviously I don't get the part below 'nr' : column_property( select( [func.count(my_table.c.id)], [my_table.c.id <= current_row.id, my_table.c.gr = current_row.group] ).label('nr') )})