fix bug on where()