Export to excel using php

Hai to all i have an excelsheet which is having irrelavant data and having nearly 50 columns and 70 thousand rows .

I need the get only 10 columns with 70 thousand rows .

I need some help to get the output. It was an csv file having data like the below attached file
Please check the below attached file and help me .

Thank you

You don’t specify why you want to use PHP for this job. I’d personally import the data into Excel as external data and then remove the columns that I don’t want.

It is a heavy file but it didn’t take too long to do so in my computer