Closed Soufraz closed 7 years ago
When I added data by add_column function, I cant search it. On the other hand, I know that inner join works for some cases. In this case, join is very slow to run.
Case:
$receivables = Receivables::join('payments', 'receivables.id_payment', '=', 'payments.id') ->select(['receivables.id', 'receivables.number', 'payments.sale_cod', 'receivables.total']); return Datatables::of($receivables) ->remove_column('id') ->add_column('client', '{{ HelperRS::getClientNameBySaleCod($sale_cod) }}', 4) ->make();
When I added data by add_column function, I cant search it. On the other hand, I know that inner join works for some cases. In this case, join is very slow to run.
Case: