I want to use a yii2
query in which I want to check a not equal to condition.
I tried like this but it didn\'t give the desired results. How do I do it?
Maybe this one help...:)
$query->andFilterWhere([ 'or',
['<=', 'affidavit_cont', 0],
['=', 'affidavit_cont1', 0],
['>', 'affidavit_cont2', 0],
['!=', 'affidavit_cont3', $this->affidavit3],
['in', 'attempt_count', $this->attempted],
]);
$query->andFilterWhere(['like', 'job_invoice.paid_status', '',]);
$query->andFilterWhere(['in', 'status_id', $this->status_id]);
$query->andFilterWhere(['between', 'last_attempt',
strtotime(Utility::convertDate2Db($this->from_date)),
strtotime(Utility::convertDate2Db($this->to_date))
]);