I am working on upload functionality of a website. The upload functionality takes an Excel or CSV file and upload it to MySQL database. I have a problem with blank cells. Since I am using PHPExcel library, it changes the blank cells to 0 in database. I want to handle the blank cell values in database and store null instead of 0.
$excelObj = $this->get('phpexcel')->createPHPExcelObject($path_file);
$sheet = $excelObj->getActiveSheet()->toArray(null,true,true,true);