-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: fix bug in data model that assumed that the market_unit_mrid was…
… unique. This is not the case for loads, since they are in a load group and the load group is associated with a schedule resource
- Loading branch information
1 parent
93df033
commit 6f94a55
Showing
6 changed files
with
41 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
14 changes: 14 additions & 0 deletions
14
src/cimsparql/sparql/test_configuration_modifications/add_market_code_for_load_groups.sparql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
prefix cim:<${cim}> | ||
prefix SN:<${SN}> | ||
|
||
# Assign all loads that does not have a load group to the newly created load group | ||
insert { | ||
graph <http://cimsparql/xml-adpator/EQ-modifications> { | ||
?load cim:NonConformLoadGroup.LoadGroup ?created_group | ||
} | ||
} | ||
where { | ||
?load a cim:EnergyConsumer . | ||
?created_group cim:IdentifiedObject.name "created-group" . | ||
filter not exists{?load cim:NonConformLoadGroup.LoadGroup ?group} | ||
} |
12 changes: 12 additions & 0 deletions
12
src/cimsparql/sparql/test_configuration_modifications/add_non_conform_load_group.sparql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
prefix cim:<${cim}> | ||
prefix SN:<${SN}> | ||
|
||
# Create a load group | ||
insert data { | ||
graph <http://cimsparql/xml-adpator/EQ-modifications> { | ||
_:b0 a cim:NonConformLoadGroup; | ||
cim:IdentifiedObject.name "created-group"; | ||
SN:NonConformLoadGroup.ScheduleResource _:b1 . | ||
_:b1 SN:ScheduleResource.marketCode "created-resource-mcode" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters