这是indexloc提供的服务,不要输入任何密码
Skip to content

{} evaluating to true is confusing #704

@shahidhk

Description

@shahidhk

{} evaluating to true especially with where is confusing. We had cases which a frontend bug caused one variable to be undefined and the query was sent with where: {} instead of where: {key:value} and the entire table got cleared (acepsc).

#701 is also due to where: {} matching all the rows.

We need a special construct to match all the cases (that evaluates to true). An empty {} should mean nothing so that we can avoid accidental wiping out of the entire table using where: {}. This is bound to happen with frontend languages like JS and we should be a little forgiving there as it is our primary target.

Metadata

Metadata

Assignees

No one assigned

    Labels

    c/serverRelated to server

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions