Skip to content

egg-mysql的筛选条件如何or #1035

Closed
@xjchenhao

Description

@xjchenhao

开发团队你们好,

我想问下egg-mysql

const results = yield app.mysql.select('posts',{
  where: { status: 'draft',name: 'abc' },
  orders: [['created_at','desc'], ['id','desc']],
  limit: 10,
  offset: 0
});

这样的语句,where里的条件是AND的关系,如何筛选OR的关系呢?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions