Message from discussion
mongoimport 2.2 busted
Received: by 10.42.130.200 with SMTP id w8mr3021653ics.15.1346364440055;
Thu, 30 Aug 2012 15:07:20 -0700 (PDT)
X-BeenThere: mongodb-user@googlegroups.com
Received: by 10.50.104.169 with SMTP id gf9ls1643805igb.0.gmail; Thu, 30 Aug
2012 15:06:59 -0700 (PDT)
Received: by 10.50.159.137 with SMTP id xc9mr7130igb.3.1346364419409;
Thu, 30 Aug 2012 15:06:59 -0700 (PDT)
Received: by 10.50.159.137 with SMTP id xc9mr7128igb.3.1346364419395;
Thu, 30 Aug 2012 15:06:59 -0700 (PDT)
Return-Path: <freeman....@gmail.com>
Received: from mail-ob0-f172.google.com (mail-ob0-f172.google.com [209.85.214.172])
by gmr-mx.google.com with ESMTPS id mb9si628838igc.1.2012.08.30.15.06.59
(version=TLSv1/SSLv3 cipher=OTHER);
Thu, 30 Aug 2012 15:06:59 -0700 (PDT)
Received-SPF: pass (google.com: domain of freeman....@gmail.com designates 209.85.214.172 as permitted sender) client-ip=209.85.214.172;
Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of freeman....@gmail.com designates 209.85.214.172 as permitted sender) smtp.mail=freeman....@gmail.com; dkim=pass header...@gmail.com
Received: by mail-ob0-f172.google.com with SMTP id wc20so5581286obb.17
for <mongodb-user@googlegroups.com>; Thu, 30 Aug 2012 15:06:59 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
d=gmail.com; s=20120113;
h=mime-version:in-reply-to:references:from:date:message-id:subject:to
:content-type;
bh=PcSmM3D/sLTninWDA1gX2zKbEjILuOfGlpyo/AMl6Kg=;
b=Wtxd8sZNMTP3ie9UsePjie+mVFNhS4jJNrld6zYRbT08JLxlsnbV3EcrUZd79MYZbR
u50wSGx7bq6ZSbSRdARuMIs0+HQsZp8sbe4NcbPLlx+slAGQbBrZtP+yIg3zvQxLui/U
fl+ubaNzOH/yLinvBsN7vsqV4wgiNm4kL8rmTXVIGkBJ7nHDovL+aUVRMozQIwKvKHVo
EJmTVbNcFCRs+Q/+gAzjZR+6CzZhLDyMNujYqu2WMqwzjmH27jaKCHZWVGoM+kDf84lm
IfNzFA3HfZY6NpCJxXoh9PTAn9bWnnavezYMGQpBvbwLxowFz7YZyUJ8CEEhKg+wrTR1
+kaA==
Received: by 10.60.3.35 with SMTP id 3mr6231303oez.139.1346364419191; Thu, 30
Aug 2012 15:06:59 -0700 (PDT)
MIME-Version: 1.0
Received: by 10.76.139.138 with HTTP; Thu, 30 Aug 2012 15:06:39 -0700 (PDT)
In-Reply-To: <6030b1dc-9527-421f-a183-3152a4bb2071@googlegroups.com>
References: <afa89446-64ae-4225-9ba2-6c525382faf8@googlegroups.com> <6030b1dc-9527-421f-a183-3152a4bb2071@googlegroups.com>
From: Wes Freeman <freeman....@gmail.com>
Date: Thu, 30 Aug 2012 18:06:39 -0400
Message-ID: <CAAOkgHPCuD2FfaptSh0GfSs8WzC8jb14B65b_0mBLKpsm4A...@mail.gmail.com>
Subject: Re: [mongodb-user] Re: mongoimport 2.2 busted
To: mongodb-user@googlegroups.com
Content-Type: multipart/alternative; boundary=e89a8fb1ff0af1b2f504c882e4d2
--e89a8fb1ff0af1b2f504c882e4d2
Content-Type: text/plain; charset=UTF-8
This will happen if your JSON objects in the import are spanning multiple
lines. If you can easily massage your data to be all on one line, that's
probably the best way to resolve this:
http://www.mongodb.org/display/DOCS/Import+Export+Tools#ImportExportTools-Example%3AImportfileformat
Wes
On Thu, Aug 30, 2012 at 5:57 PM, Tad Marshall <t...@10gen.com> wrote:
> The lines with ??? are what a (new!) Windows stack trace looks like when
> you don't have a PDB file (and we didn't include one for mongoimport.exe).
> We will try to make that more useful in the future ...
>
> Your test fails for me the same way in Windows 2.2.0, Windows 2.0.7 and
> Linux 2.0.6, so it's not new and it's not Windows-specific. I don't have
> personal experience using mongoimport, so I'll play with it and see if the
> file format is wrong or our code isn't working right. I'll let you know
> what I learn ...
>
>
> On Thursday, August 30, 2012 4:40:52 PM UTC-4, Geneo wrote:
>>
>> New user to mongo and wanted to run queries against the json files we use
>> on our project. I attempted to use the mongoimport tool and cannot
>> successfully import any json file even a simple 3 parameter file.
>>
>> {
>> "AGING": 1,
>> "AIRPLANE_MIGRATION": 0,
>> "ANIMAL_RESERVOIR": 0
>> }
>>
>> I'm on 64 bit windows 7.
>>
>> The first error I see is
>>
>> Thu Aug 30 13:29:25 Assertion: 10340:Failure parsing JSON string near:
>> Thu Aug 30 13:29:25 mongoimport.exe ???
>> Thu Aug 30 13:29:25 mongoimport.exe ???
>> Thu Aug 30 13:29:25 mongoimport.exe ???
>> Thu Aug 30 13:29:25 mongoimport.exe ???
>> Thu Aug 30 13:29:25 mongoimport.exe ???
>> Thu Aug 30 13:29:25 mongoimport.exe ???
>> Thu Aug 30 13:29:25 mongoimport.exe ???
>> Thu Aug 30 13:29:25 mongoimport.exe ???
>> Thu Aug 30 13:29:25 kernel32.dll BaseThreadInitThunk+0xd
>> Thu Aug 30 13:29:25 exception:BSON representation of supplied JSON is too
>> large: Failure parsing JSON string near:
>>
>> This error then repeats for each parameter indicating a parser JSON
>> string near: "parameter name"
>>
>> Using the following cmd line syntax
>> d:\mongodb\bin\mongoimport.exe -d test -c testDTK
>> d:\mongodb\jsons\glossary.json
>>
>>
>> --
> You received this message because you are subscribed to the Google
> Groups "mongodb-user" group.
> To post to this group, send email to mongodb-user@googlegroups.com
> To unsubscribe from this group, send email to
> mongodb-user+unsubscribe@googlegroups.com
> See also the IRC channel -- freenode.net#mongodb
>
--e89a8fb1ff0af1b2f504c882e4d2
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
This will happen if your JSON objects in the import are spanning multiple l=
ines. If you can easily massage your data to be all on one line, that's=
probably the best way to resolve this:<div><a href=3D"http://www.mongodb.o=
rg/display/DOCS/Import+Export+Tools#ImportExportTools-Example%3AImportfilef=
ormat">http://www.mongodb.org/display/DOCS/Import+Export+Tools#ImportExport=
Tools-Example%3AImportfileformat</a><br>
<div><br></div><div>Wes<br><br><div class=3D"gmail_quote">On Thu, Aug 30, 2=
012 at 5:57 PM, Tad Marshall <span dir=3D"ltr"><<a href=3D"mailto:tad@10=
gen.com" target=3D"_blank">t...@10gen.com</a>></span> wrote:<br><blockquo=
te class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc so=
lid;padding-left:1ex">
The lines with ??? are what a (new!) Windows stack trace looks like when yo=
u don't have a PDB file (and we didn't include one for mongoimport.=
exe). =C2=A0We will try to make that more useful in the future ...<div><br>
</div>
<div>Your test fails for me the same way in Windows 2.2.0, Windows 2.0.7 an=
d Linux 2.0.6, so it's not new and it's not Windows-specific. =C2=
=A0I don't have personal experience using mongoimport, so I'll play=
with it and see if the file format is wrong or our code isn't working =
right. =C2=A0I'll let you know what I learn ...<div>
<div class=3D"h5"><br><br>On Thursday, August 30, 2012 4:40:52 PM UTC-4, Ge=
neo wrote:<blockquote class=3D"gmail_quote" style=3D"margin:0;margin-left:0=
.8ex;border-left:1px #ccc solid;padding-left:1ex">New user to mongo and wan=
ted to run queries against the json files we use on our project. I attempte=
d to use the mongoimport tool and cannot successfully import any json file =
even a simple 3 parameter file.<div>
<br></div><div><div>{</div><div>=C2=A0 =C2=A0 =C2=A0 =C2=A0 "AGING&quo=
t;: 1,=C2=A0</div><div>=C2=A0 =C2=A0 =C2=A0 =C2=A0 "AIRPLANE_MIGRATION=
": 0,=C2=A0</div><div>=C2=A0 =C2=A0 =C2=A0 =C2=A0 "ANIMAL_RESERVO=
IR": 0</div><div>=C2=A0}</div></div><div><br></div><div>I'm on 64 =
bit windows 7.</div>
<div><br></div><div>The first error I see is=C2=A0</div><div><br></div><div=
><div>Thu Aug 30 13:29:25 Assertion: 10340:Failure parsing JSON string near=
:</div><div>Thu Aug 30 13:29:25 mongoimport.exe =C2=A0 =C2=A0???</div><div>=
Thu Aug 30 13:29:25 mongoimport.exe =C2=A0 =C2=A0???</div>
<div>Thu Aug 30 13:29:25 mongoimport.exe =C2=A0 =C2=A0???</div><div>Thu Aug=
30 13:29:25 mongoimport.exe =C2=A0 =C2=A0???</div><div>Thu Aug 30 13:29:25=
mongoimport.exe =C2=A0 =C2=A0???</div><div>Thu Aug 30 13:29:25 mongoimport=
.exe =C2=A0 =C2=A0???</div><div>Thu Aug 30 13:29:25 mongoimport.exe =C2=A0 =
=C2=A0???</div>
<div>Thu Aug 30 13:29:25 mongoimport.exe =C2=A0 =C2=A0???</div><div>Thu Aug=
30 13:29:25 kernel32.dll =C2=A0 =C2=A0 =C2=A0 BaseThreadInitThunk+0xd</div=
><div>Thu Aug 30 13:29:25 exception:BSON representation of supplied JSON is=
too large: Failure parsing JSON string near:</div>
</div><div><br></div><div>This error then repeats for each parameter indica=
ting a parser JSON string near: "parameter name"</div><div><br></=
div><div>Using the following cmd line syntax</div><div>d:\mongodb\bin\mongo=
import.exe -d test -c testDTK d:\mongodb\jsons\glossary.json<br>
</div><div><br></div><div><br></div></blockquote></div></div></div><div cla=
ss=3D"HOEnZb"><div class=3D"h5">
<p></p>
-- <br>
You received this message because you are subscribed to the Google<br>
Groups "mongodb-user" group.<br>
To post to this group, send email to <a href=3D"mailto:mongodb-user@googleg=
roups.com" target=3D"_blank">mongodb-user@googlegroups.com</a><br>
To unsubscribe from this group, send email to<br>
<a href=3D"mailto:mongodb-user%2Bunsubscribe@googlegroups.com" target=3D"_b=
lank">mongodb-user+unsubscribe@googlegroups.com</a><br>
See also the IRC channel -- <a href=3D"http://freenode.net#mongodb" target=
=3D"_blank">freenode.net#mongodb</a><br>
</div></div></blockquote></div><br></div></div>
--e89a8fb1ff0af1b2f504c882e4d2--