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.

Cannot DROP CONSTRAINT

See original GitHub issue
  • EdgeDB Version: EdgeDB version “2” Docker image
  • OS Version: Arch Linux

Steps to Reproduce:

  1. DROP a CONSTRAINT

I couldn’t put together a schema that reproduces the bug, but here’s what I expected to reproduce it:

module default {
	type Entity {
		required property bucket -> str;
		required property available -> bool;
		required property assigned := .available and .bucket != 'UNPROCESSED';

		# To be removed
		constraint expression on (
			(.available and .assigned) or not (.assigned)
		);
	}
}

And here’s the error that’s thrown when applying the migration:

image

Issue Analytics

  • State:open
  • Created a year ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
elpranscommented, Sep 13, 2022

You can pipe into edgedb:

edgedb> CREATE DATABASE testdb;
$ cat file.edgeql | edgedb -d testdb
0reactions
MicroDroidcommented, Sep 13, 2022

@elprans How do I run an .edgeql file without having to paste massive stuff in EdgeDB CLI?

Is there any way I can pipe a file into EdgeDB?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot drop constraint - sql - Stack Overflow
Not having luck when dropping a constraint...I am logged in as 'sa' which should have enough permissions to execute it but I still...
Read more >
Postgres - can't drop constraint because objects depend on it ...
The correct solution is to drop the foreign key along with the unique constraint and create it again, so that it points to...
Read more >
DROP CONSTRAINT | CockroachDB Docs
The DROP CONSTRAINT statement performs a schema change. For more information about how online schema changes work in CockroachDB, see Online Schema Changes....
Read more >
DROP CONSTRAINT Clause - IBM
The DROP TABLE statement implicitly drops all constraints on the specified table when it destroys that table. Retrieving constraint names. The DROP CONSTRAINT...
Read more >
How to drop a constraint in SQL Server: Explained with ...
Just run the DROP CONSTRAINT statement in an ALTER TABLE statement · Primary Key constraint on the BookID column · Unique constraint on...
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