推荐工具
RoboMongo
推荐书目
50 Tips and Tricks for MongoDB Developers
Related Blogs
Snail in a Turtleneck
Achilless
V2EX  ›  MongoDB

pymongo 操作 mongo 的聚合查询,返回为空列表

  •  
  •   Achilless · Dec 9, 2019 · 12523 views
    This topic created in 2345 days ago, the information mentioned may be changed or developed.

    同样的命令在 shell 里执行是没有问题的 image.png image.png 是不是 pipline 写的有问题呢

    6 replies    2019-12-09 14:55:05 +08:00
    LuckyBoyGirl
        1
    LuckyBoyGirl  
       Dec 9, 2019
    妹子你好 我冲着头像来着
    j0hnj
        2
    j0hnj  
       Dec 9, 2019 via iPhone
    数据库密码是不是应该打个码
    Achilless
        3
    Achilless  
    OP
       Dec 9, 2019
    @j0hnj 随机生成的
    neoblackcap
        4
    neoblackcap  
       Dec 9, 2019
    假如数据是一样的数据库,一个脚本行,一个脚本不行,请先自己用对比工具对比你自己写的代码。
    whusnoopy
        5
    whusnoopy  
       Dec 9, 2019
    pymongo 里时间这么写可以用么,先测试看简单的 find 看有没有结果?我们业务里都是用的 python 自己的 datetime
    Achilless
        6
    Achilless  
    OP
       Dec 9, 2019
    @whusnoopy 果然是这样,改成 datetime 类型可以了,老哥给力
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   1079 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 110ms · UTC 22:55 · PVG 06:55 · LAX 15:55 · JFK 18:55
    ♥ Do have faith in what you're doing.