Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Field OBX-5 in V21 is defined as ST and not defined as type Varies #45

Closed
0x4AMiller opened this issue Dec 31, 2015 · 1 comment · Fixed by #136
Closed

Field OBX-5 in V21 is defined as ST and not defined as type Varies #45

0x4AMiller opened this issue Dec 31, 2015 · 1 comment · Fixed by #136
Assignees
Labels
bug The result of a coding Error
Milestone

Comments

@0x4AMiller
Copy link

Which is causing invalid cast exception on line # 184 in NHapi.Base.Model.Varies

in fixOBX5 method...
foreach (IType repetition in segment.GetField(5))
{
Varies v = (Varies) repetition; <--- Invalid cast exception
...
}

@milkshakeuk milkshakeuk added the bug The result of a coding Error label Jan 29, 2021
@milkshakeuk milkshakeuk added this to To Do in NHapi Kanban via automation Jan 29, 2021
@milkshakeuk milkshakeuk self-assigned this Jan 29, 2021
@milkshakeuk milkshakeuk added this to the v3.0.0.0 milestone Jan 29, 2021
@milkshakeuk
Copy link
Member

@0x4AMiller Hi thanks for this, I also discovered this whilst writing unit tests for another issue #133 so will fix this in the same PR

NHapi Kanban automation moved this from To Do to Development Done Jan 30, 2021
milkshakeuk added a commit that referenced this issue Jan 30, 2021
The datatype for OBX-5 is specified in OBX-2, the first commit fixes an issue when the specified datatype from OBX-2 could not be constructed for OBX-5 because the required constructors were missing.
fixes #62, fixes #85, fixes #133

XAD, XON, XTN datatypes for hl7 v2.7.1 up to 2.8.1 have incorrect recursive datatypes leading to StackOverflowException.
The second commit fixes this by correcting those datatypes.
fixes #86, fixes #109

The OBX-5 datatype for hl7 v2.1 is incorrectly set to ST when it should be Varies. The last commit fixes this.
fixes #45
@milkshakeuk milkshakeuk moved this from Development Done to In Pre-Release in NHapi Kanban Jan 30, 2021
@milkshakeuk milkshakeuk moved this from In Pre-Release to Released in NHapi Kanban Jun 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug The result of a coding Error
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

2 participants