I have recently been collecting data for my company to create a MySQL database. In doing this using PHP it can be used to view, add, edit and delete using a webpage interface.
I have currently created a prototype that allows me to import this data by converting a .XLS or XLSX sheet into a .CSV format that is then imported through PHPMyAdmin. Only recently I have found a snag with using this method. In my spreadsheet I have a few columns that represent barcodes, these barcodes vary in size, some going over 15 digits long. Excel has a limit to what it will represent and unfortunately displays the following:
This can obviously be changed by formatting the excel column to number, text etc.. however when saved as a CSV format it becomes impossible to change as every time you close the document it reverts back to it's original state.
When viewing the CSV file in Notepad++, the barcode will show fine although when I import the file into PHPMyAdmin, the barcode will show in the same way as the CSV.
So my question splits into two parts:
- What is the best format to import my spreadsheet on?
- How do I resolve this annoying format.