question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Require a FILTER on DELETE and UPDATE?

See original GitHub issue

There was some discussion earlier about requiring FILTER on DELETE and UPDATE statements, to help prevent mishaps. FILTER true could be used when operating on everything is actually desired.

(Relevant: https://www.youtube.com/watch?v=i_cVJgIz_Cs)

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:2
  • Comments:14 (14 by maintainers)

github_iconTop GitHub Comments

1reaction
elpranscommented, Sep 3, 2020

I think we should only do this if X in DELETE X is a universal set.

That is, the following should be legal:

WITH ToDelete := (SELECT Foo FILTER ...)
DELETE ToDelete

or

function delete_foo(foo: Foo) -> Foo using (DELETE foo)
0reactions
elpranscommented, Mar 1, 2021

See https://github.com/edgedb/edgedb/pull/1773#issuecomment-722615788 for the planned approach to handling this.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Filter function (action Hooks) for update and delete ...
Please provide me Filter function (action Hooks) for updating and delete appointment back-end. (1) I want to filter functions after updating appointments ...
Read more >
Reapply a filter and sort, or clear a filter - Microsoft Support
To reapply a filter or sort, on the Home tab, in the Editing group, click Sort & Filter, and then click Reapply.
Read more >
Filter does not update list when I delete chars - Stack Overflow
I believe your problem is that you are essentially removing objects from your original list when you start entering characters.
Read more >
SQL WHERE Clause to Filter Rows for SELECT, UPDATE and ...
In this article we take a look at the SQL WHERE clause and how this can be used to filter rows for selecting,...
Read more >
Excel Filter: How to add, use and remove - Ablebits
Learn how to filter data in Excel in different ways: create filter ... or delete data in filtered cells, Excel AutoFilter does not...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found