Hi Ismet,

Here is a thread from last year where this issue was discussed, with a few
possible resolutions.

http://blog.gmane.org/gmane.comp.medical.hl7/month=20101001

Cheers,
James

2011/3/17 Çelebi, Ismet <[email protected]>

>  Dear helpfull developers,
>
>
>
> I am using HAPI 1.0.1 to validate ORU_R1 messages.
>
> I have the following exception for the filed OBX-5
>
>
>
> *ca.uhn.hl7v2.model.DataTypeException*: Failed validation rule for value
> "negativ": Matches the regular expression (\+|\-)?\d*\.?\d*
>
>       at ca.uhn.hl7v2.model.AbstractPrimitive.setValue(*
> AbstractPrimitive.java:85*)
>
>       at ca.uhn.hl7v2.util.DeepCopy.copy(*DeepCopy.java:28*)
>
>       at ca.uhn.hl7v2.model.Varies.setData(*Varies.java:104*)
>
>       at ca.uhn.hl7v2.model.Varies.fixOBX5(*Varies.java:171*)
>
>       at ca.uhn.hl7v2.parser.PipeParser.parse(*PipeParser.java:379*)
>
>       at ca.uhn.hl7v2.parser.PipeParser.parse(*PipeParser.java:943*)
>
>       at ca.uhn.hl7v2.parser.PipeParser.doParse(*PipeParser.java:243*)
>
>       at ca.uhn.hl7v2.parser.GenericParser.doParse(*GenericParser.java:241
> *)
>
>       at ca.uhn.hl7v2.parser.Parser.parse(*Parser.java:167*)
>
>       at de.joho.portal.socket.HL7Server.handleConnection(*
> HL7Server.java:63*)
>
>       at de.joho.portal.socket.HL7Server.main(*HL7Server.java:144*)
>
>
>
> The exception comes not only for “negativ” but also for other values used
> in our system, such as “>60”, “>20”, “neg” etc.
>
>
>
> Definition in the file Varies.class is: “Varies is a Type used as a
> placeholder for another Type in cases where the appropriate Type is not
> known until run-time (e.g. OBX-5).”
>
>
>
> The only thing I did was trying to parse the whole message:
>
>
>
> String hl7message = new String(buffer, 0, count);
>
> Message hapiMsg = p.parse(hl7message);
>
>
>
> As far as I understand I should be able to use Varies also as string, so it
> should work.
>
>
>
> Best regards,
>
> Ismet
>
>
>
>
> ------------------------------------------------------------------------------
> Colocation vs. Managed Hosting
> A question and answer guide to determining the best fit
> for your organization - today and in the future.
> http://p.sf.net/sfu/internap-sfd2d
> _______________________________________________
> Hl7api-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/hl7api-devel
>
>
------------------------------------------------------------------------------
Colocation vs. Managed Hosting
A question and answer guide to determining the best fit
for your organization - today and in the future.
http://p.sf.net/sfu/internap-sfd2d
_______________________________________________
Hl7api-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/hl7api-devel

Reply via email to