Uploaded image for project: 'PHP Driver: Extension'
  1. PHP Driver: Extension
  2. PHPC-623

Numeric keys limited to unsigned 32-bit integer

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 1.1.4
    • Affects Version/s: 1.1.3
    • Component/s: None
    • None

      https://github.com/mongodb/mongo-php-driver/issues/256

      Example script:

      <?php
      $data = [
          '9781449410247' => 'a',
          'X9781449410247' => 'b',
          9781449410248 => 'c',
      ];
      $bson = MongoDB\BSON\fromPHP($data);
      $json = MongoDB\BSON\toJSON($bson);
      
      echo $json;
      ?>
      

      This outputs:

      { "1808877255" : "a", "X9781449410247" : "b", "1808877256" : "c" }
      

            Assignee:
            jmikola@mongodb.com Jeremy Mikola
            Reporter:
            derick Derick Rethans
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: