Announcement

Collapse
No announcement yet.

Undefined in OBX Segment

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Undefined in OBX Segment

    I finally got my OUTbound to create multiple OBX segments.

    Lets say that my result set will return 5 rows of OBX data.
    If my HL7 message templet does not have 5 rows of OBX in it it will give me the Cannot set property OBX.1 of undefined to 6.

    So I have to go into my templet and add another OBX row and it works.

    I am not going to know how many rows are going to be generated.

    Is there a way around this or is this a bug?


  • #2
    Re: Undefined in OBX Segment

    Perhaps this could help you:

    http://www.faqts.com/knowledge_base/...35888/fid/1762

    Comment


    • #3
      Re: Undefined in OBX Segment

      This will give you an OBX element to work with:

      Code:
      var obx = tmp['ORU_R01.RESPONSE']['ORU_R01.ORDER_OBSERVATION']['ORU_R01.OBSERVATION'][0]
      Now for each OBX.5 you read from the db, you would do:

      Code:
      tmp['ORU_R01.RESPONSE']['ORU_R01.ORDER_OBSERVATION']['ORU_R01.OBSERVATION'][OBRi] = obx;
      This would come before actually setting the db values. This sets the specific OBRi field to the previous OBX element (essentially creating a new OBX element).
      Chris Lang

      Comment


      • #4
        Re: Undefined in OBX Segment

        Chris,

        Thanks for that info it helped a lot.
        And that did solve the error.

        What I need now is multiple OBR's with Multiple OBX's.
        OBR|1|
        OBX|1|
        OBX|2|
        OBR|2|
        OBX|1|
        OBX|2|

        I have tried different variations of what you posted but can not seem to get it.

        Comment


        • #5
          Re: Undefined in OBX Segment

          Do the same thing as my previous message - store the OBR value in a var and then store the OBX value in a var. Iterate through the data. Sorry, my description probably isn't too helpful!
          Chris Lang

          Comment


          • #6
            Re: Undefined in OBX Segment

            Chris....

            I must be the biggest idiot because I am not able to get it to produce multiple OBR's with multiple OBX's.

            Do you have some sort of example that might help?


            Comment

            Working...
            X