I got a problem that modify a query string to delete farm_id condition like this:
this.datasource.query(`...
WHERE fe.tenant_id = $1
AND fe.farm_id = $2 -- i was deleted this line
AND fe.action_date < $3`, [tenant_id, farm_id, to_date]);
and when run query got error
QueryFailedError: could not determine data type of parameter $3
i was research that error cause placeholders must be matched parameters length, can you guy tell me the other way to do this please, thank you.