收藏
回答

为什么orderBy查询不到1月10日之后的数据?


const cloud = require('wx-server-sdk')


cloud.init()

const db = cloud.database()



exports.main = async (event, context) => {

  try {

    return await db.collection('post')

    .orderBy('created_date', 'desc')

      .get()


  } catch (e{

    console.error(e)

  }


}

这个函数之前一直是正常运作的,created_date的格式为 yyyy/mm/dd

回答关注问题邀请回答
收藏

1 个回答

  • 茫
    2022-01-14

    created_date是什么类型的数据?

    2022-01-14
    有用
    回复 1
    • 阿鹏
      阿鹏
      2022-01-14
      string
      2022-01-14
      回复
登录 后发表内容