Skip to content

Commit 39d6a79

Browse files
[EdgeDB] Create PartnershipProducingMedium schema (#3072)
Co-authored-by: Carson Full <[email protected]>
1 parent 24dce24 commit 39d6a79

File tree

2 files changed

+23
-0
lines changed

2 files changed

+23
-0
lines changed

dbschema/migrations/00053.edgeql

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
CREATE MIGRATION m1vp4elagp7wzixttjl3s6pk2q5ml2p4zq35vvdc3nouewe3qvcm3q
2+
ONTO m1rqfvf4ah2ev4ncoxa6l7x5u6h6tssd6r7cbneshimgxzbtdzdppq
3+
{
4+
CREATE TYPE Product::PartnershipProducingMedium EXTENDING Engagement::Child {
5+
CREATE REQUIRED LINK partnership: default::Partnership {
6+
ON TARGET DELETE DELETE SOURCE;
7+
SET readonly := true;
8+
};
9+
CREATE REQUIRED PROPERTY medium: Product::Medium;
10+
CREATE CONSTRAINT std::exclusive ON ((.engagement, .partnership, .medium));
11+
};
12+
};
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
module Product {
2+
type PartnershipProducingMedium extending Engagement::Child {
3+
required partnership: default::Partnership {
4+
readonly := true;
5+
on target delete delete source;
6+
};
7+
required medium: Medium;
8+
9+
constraint exclusive on ((.engagement, .partnership, .medium))
10+
}
11+
}

0 commit comments

Comments
 (0)