1MONGOEXPORT(1)                  Mongo Database                  MONGOEXPORT(1)
2
3
4

NAME

6       mongoexport - the Mongo export tool
7

SYNOPSIS

9       mongoexport [OPTIONS]
10

DESCRIPTION

12       mongoexport  is a tool to export a MongoDB collection to either JSON or
13       CSV. The query can be filtered or a list of fields  to  output  can  be
14       given.
15
16       If the output is CSV, the fields must be specified in order.
17

EXAMPLES

19       mongoexport -d test -c test1 --csv -f name,num
20              export documents from test.test1 in CSV format
21

OPTIONS

23       --help show usage information
24
25       -h, --host HOST
26              server to connect to (default HOST=localhost)
27
28       -d, --db DATABASE
29              database to use
30
31       -c, --c COLLECTION
32              collection to use
33
34       -q, --query QUERY
35              query filter
36
37       -f, --fields FIELDS
38              comma-separated list of field names
39
40       --csv  export to CSV instead of JSON
41
42       -o, --out FILE
43              output file, if not specified, stdout is used
44
45       --dbpath PATH
46              directly  access mongod data files in this path, instead of con‐
47              necting to a mongod instance
48
50       Copyright 2007-2009 10gen
51

SEE ALSO

53       For more information, please refer to the MongoDB  wiki,  available  at
54       http://www.mongodb.org.
55

AUTHOR

57       Kristina Chodorow
58
59
60
6110gen                              June 2009                    MONGOEXPORT(1)
Impressum