Announcement

Collapse

NextGen (Mirth) Connect 3.11.0 Released!

NextGen (Mirth) Connect 3.11.0 is now available as an appliance update and on our GitHub page. This release contains improvements to licensing and the NCPDP data type. It also includes various security fixes, general bug fixes, and improvements to commercial extensions. See the release notes for the complete list of fixes and improvements.

Download | See What's New | Upgrade Guide | Release Notes

For discussion on this release, see this thread.
See more
See less

Mirth 1.3 - Problem checking for null

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

  • chrisl
    replied
    Re: Mirth 1.3 - Problem checking for null

    This is not a bug, it is due to the improved parsing in Hapi 0.5.

    Leave a comment:


  • nshaik
    started a topic Mirth 1.3 - Problem checking for null

    Mirth 1.3 - Problem checking for null

    =================
    Environment:

    Mirth 1.3, JRE 1.5 Update 9, Windows Server 2000 SP4 w/ current updates, SQL Server 2000 SP3

    Channel: File Reader to database

    ==================

    Problem: With Mirth 1.1 if there's no data for the segment, check for null worked fine.

    For e.g., If there's no data for Attending Doctor (Scheduling messages S12, S13, etc.) Check for != null would evaluate to false

    But with Mirth 1.3 this check evaluates to true and happens inconsistently.


    // Schedule events S12, S13...

    var pivSegment;

    pivSegment = msg['SIU_S12.PATIENT']['PV1'];

    ========== With Mirth v1.1 this check worked fine if there was no data for the attending doctor

    // Attending doctor
    if (pivSegment['PV1.7'] != null) {
    ...

    }

    ========== With Mirth 1.3, had to make an additional check, string length > 0, for it to work right always

    // Attending doctor
    if (pivSegment['PV1.7'] != null) {

    // Check if the attending doctor's last name string length is > 0
    var checkLastName = pivSegment['PV1.7']['XCN.2'].toString();
    if (checkLastName.length > 0) {
    ...
    }
    }
Working...
X