Uploaded image for project: 'MongoDB ETL Tools'
  1. MongoDB ETL Tools
  2. TOOLS-786

mongoimport fails depending on the position of Date key-values

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor - P4
    • Resolution: Fixed
    • Affects Version/s: 3.0.3
    • Fix Version/s: 3.0.4
    • Component/s: mongoimport
    • Labels:
    • Environment:
      Default mongod instance

      Description

      If the document contains a Date object and the last field is a non-Date object, mongoimport will fail.

      Attempting to import

      {"DATE": Date("1987-03-06T00:00:00.000Z"), "NUM": 560000}

      results in:

      mongoimport --db test --collection <<collection>> --file <<file>>

      2015-06-12T10:14:20.287-0700 connected to: 127.0.0.1:27017
      2015-06-12T10:14:20.288-0700 Failed: error getting extended BSON for document #0: conversion of JSON type '560000' unsupported
      2015-06-12T10:14:20.288-0700 imported 0 documents

        Attachments

          Activity

            People

            • Assignee:
              adinoyi.omuya Adinoyi Omuya
              Reporter:
              kevinl Kevin Liew
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: