在线观看不卡亚洲电影_亚洲妓女99综合网_91青青青亚洲娱乐在线观看_日韩无码高清综合久久

鍍金池/ 問答/數(shù)據(jù)庫/ mongodump 導(dǎo)出條件錯誤

mongodump 導(dǎo)出條件錯誤

mongodump or mongoexport use --query,but have not filtered the result, it exports all data.
my condition is like this:

{"modifiedOn" : ISODate("2018-06-06T00:00:12.539+0000")}

and i change it is to 1528244529
but when i use this:

mongodump -h 192.168.169.63:27017 -d product_operation_sold -c ebay_payment --query '{"modifiedOn":{$gt: Date(1528244529)}}' -o /root

what was am I doing my wrong?

回答
編輯回答
怣人

Try using $date instead of Date/ISODate when using with bash tools:

mongodump -h 192.168.169.63:27017 -d product_operation_sold -c ebay_payment --query '{"modifiedOn":{$gt: {$date: "2018-06-06T00:00:12.539Z"}}}' -o /root

This also applies to following tools:

  • mongodump
  • mongorestore
  • mongoimport
  • mongoexport
2018年6月3日 03:13