日期过滤使用nodejs

时间:2018-01-19 06:11:51

标签: node.js sequelize.js

我想要来自mysql Db的过滤日期数据

我的续集查询,如

...........
var filterKey = "DATE_ADDED"
var filterValue = "2016-12-27 00:00:00" 
    return myDb.myTable.findAndCountAll({
                                    attributes: ['ID', 'NAME', 'FIRSTNAME'],
                                    where: {

                                      [filterKey]: {
                                        like: '%' +  filterValue + '%'
                                      }
                                    },
                                    order: [
                                      [sortField, orderField],
                                      ['NAME'],
                                      ['ID']
                                    ],
                                    offset: currentPage,
                                    limit: numPerPage
                                  })
                                  .then((getCountandCustomer) => {
    .....................
    .....................

    })

在显示此错误 enter image description here

的命令提示中

0 个答案:

没有答案