Upload xls document, where the value of one column is too long, read into the scientific counting method, detailed see content

Source: Internet
Author: User
1. Upload xls
2. One of the columns is called the waybill number, the value is 22 digits, the format is as follows
Order Number Waybill Number Logistics
1 1234567890987654321234 USPS
2 1234567890987654323224 USPS
... ...
PHP Processing code:
$xls _obj=new helper_excel ();
$xls _obj->readfile ($filename);
$sheet = $xls _obj->toheadermap ();
foreach ($sheet as $key = = $row) {...}
The waybill number you read becomes a scientific notation.
This column of the Excel document has been changed to text format

Would you please give me a thought?


Reply to discussion (solution)

Treat him as a string, and the int type is out of bounds.

I thought about it. There might be a problem with the underlying Excel processing class.
I'll see for myself.

Did you find a way out? I've had this problem, too.

  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.