#14542 Summary: Assign unique case ids when importing multiple cases - #14634
Merged
Conversation
magnesj
force-pushed
the
duplicate-summary-case-id-14542
branch
from
August 27, 2026 13:52
8780b81 to
5b1861e
Compare
Summary cases are created and given a case id before they are added to the project. The id search only sees cases already in the project, so every case in a batch import was given the same id. The Data Sources tree stores the owning case id in each summary address, and all lookups resolve to the first case with that id. Selecting the same vector from several cases therefore produced a single curve, and dropping a vector from one of the other cases hit the duplicate check and did nothing.
magnesj
force-pushed
the
duplicate-summary-case-id-14542
branch
from
August 27, 2026 13:52
5b1861e to
621ad08
Compare
jonjenssen
approved these changes
Aug 27, 2026
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #14542
Summary cases are created and given a case id before they are added to the project.
RimProject::assignCaseIdToSummaryCase()derives the next id fromallSummaryCases(), which does not yet contain any of the cases being created, so every case in a batch import was given the same id.The Data Sources tree stores the owning case id in each
RimSummaryAddress, and all lookups go throughRiaSummaryTools::summaryCaseById(), which returns the first match. With duplicate ids:New Summary Plotcreated one curveThe locale is unrelated. The trigger is importing more than one summary case in a single import operation; importing them one at a time gave unique ids and worked.
RimProject::assignCaseIdsToSummaryCases()resolves the next free id once and hands out consecutive ids for the whole set, andRimSummaryCaseMainCollection::createSummaryCasesFromFileInfos()assigns after the creation loop. The single-case import paths (Reveal, StimPlan, derived, observed) add each case to the collection in the same loop iteration and are unchanged.