Invalid query: Unknown column 's.status' in 'where clause'