mongoexport truncates string data

Sett 446 ganger
Hopp til første uleste melding

saurabh srivastava

ulest,
2. mars 2012, 23:58:2502.03.2012
til mongod...@googlegroups.com
Exporting a collection using mongoexport truncates the string field and append "..." to it. Is there a way to disable this feature in the export?

Bill Hayward

ulest,
5. mars 2012, 06:41:5605.03.2012
til mongodb-user
Does this seem to be for fields that contain a certain length, or
above, or is it evident in all cases?

On Mar 2, 11:58 pm, saurabh srivastava <ssrivastava.m...@gmail.com>
wrote:

saurabh srivastava

ulest,
5. mars 2012, 23:47:4805.03.2012
til mongod...@googlegroups.com
I realized that this is a known issue. http://www.mongodb.org/display/DOCS/mongoexport first comment on the page talks of this. I wrote my custom exporter which does not truncate. But it would appear that the truncation happens for longer string fields.

saurabh

Josh Price

ulest,
8. juli 2012, 08:50:5608.07.2012
til mongod...@googlegroups.com
I've made a patch which fixes this issue and created a github pull request (https://github.com/mongodb/mongo/pull/260).

Personally I'd love to see this in the 2.0.7 release. Is there anything else I can do to make this happen?

Thanks in advance,
Josh

On Thursday, June 28, 2012 12:26:39 AM UTC+10, Josh Price wrote:
I'm experiencing the same problem. Strings are being truncated at around 153 characters.


From my understanding of the code, the toString() function defaults to not "full", so the full parameter should be set to true as follows:

    return csvEscape(object.toString(false, true), true);

Could someone please confirm this is the case?

Thanks,
Josh
Svar alle
Svar til forfatter
Videresend
0 nye meldinger