fix bug in stored queries related to fieldname case sensitivity
fix stuff i broke in record selector