mihuoli
V2EX  ›  Node.js

sequelize 如何返回插入自增 id ?

  •  
  •   mihuoli · May 3, 2017 · 6839 views
    This topic created in 3306 days ago, the information mentioned may be changed or developed.

    http://sequelize.readthedocs.io/en/latest/ 找遍了文档 也没解释 英语水平有限 还在努力寻找中

    3 replies    2017-05-03 15:21:37 +08:00
    blessyou
        1
    blessyou  
       May 3, 2017 via iPhone
    他本来就会有个自增 ID,
    blessyou
        2
    blessyou  
       May 3, 2017 via iPhone
    你直接写一个数据就知道了。
    mihuoli
        3
    mihuoli  
    OP
       May 3, 2017
    @blessyou 感谢  我尝试写了下的确会会返回 一个对象 刚刚插入行
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2491 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 29ms · UTC 00:51 · PVG 08:51 · LAX 17:51 · JFK 20:51
    ♥ Do have faith in what you're doing.