buildSelect added nullable

Chis Schalk inspired WHERE clause in simpleSelect