can you see the error guys ? my AND conditions is ignored! I'm getting so frustrated with those arrays..
 $transaction_query = $this->Transaction->find('all',
                [
                    'limit' => $countList,
                    'fields' => ['Transaction.client_id','Transaction.name','Transaction.created','Transaction.message_id','Transaction.credit'],
                    'conditions' => ['Transaction.id' => $client_id],
                    'AND' => ['Transaction.name !=' => 'Facturation']
                ]);
				
                        
Your conditions need to be
['Transaction.id' => $client_id, 'Transaction.name !=' => 'Facturation']. Multiple conditions of theconditionsarray are interpreted as 'AND' conditions.So your query would look like:-
You only need to index by
andif you have duplicate condition array keys; this is not the case in your example as you haveTransaction.idandTransaction.name !=. Regardless, theandindex would need to be an index inside theconditionsarray, not a sibling.