Mongodump invalid JSON input

195 Views Asked by At

I tried running this command in a Linux machine:

mongodump --host "abcd" -p=27 -u "y" -p "xx" --out /c -d "t" --gzip -c "t" --query { "Cli" : "c", "Mar" : "A" ,"F":{"$gte":ISODate("2022-01-01")}}

Unfortunately, the call fails with this error:

 Failed: error parsing query as Extended JSON: invalid JSON input. Position: XX. Character: $

I tried changing the ISODATE to ISODate("2022-01-01T00:00:00.000Z") but with no luck.

The mongodb version is 5.0.14 and tools version is 6.1.100.

0

There are 0 best solutions below