Invalid query "select id from minpravda where rid="