L
L
lynnikvadim2016-04-04 15:34:30
excel
lynnikvadim, 2016-04-04 15:34:30

How to do sorting in Laravel Excel?

There is an array (

$Name=array(0=>"Иванов", 1=>"Тепров", 2=>"Сидоров")
)
I wrote like this:
$results=Excel::selectSheetsByIndex(0)->load($request->file('files'))->whereIn("name", $Name)->get();

I am getting an error:
ErrorException in LaravelExcelReader.php line 971: Undefined offset: 1

How can I write sorting so that from the excel file I get only those rows that are indicated in the array?
->whereIn("name", $Name)- did not help.
Thank you.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question