Announcement

Collapse

Mirth Connect 3.12.0 Released!

Mirth Connect 3.12.0 is now available as an appliance update and on our GitHub page. This release includes database performance improvements, improves visual HL7 representation, message pruning, keystore handling, PDF generation, community contributions, and fixes several security vulnerabilities. This release also contains many improvements to commercial extensions. See the release notes for the list of fixes and updates.

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

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

how to get multiple result in database query

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

  • how to get multiple result in database query

    I placed a database query that return multiple lignes (patients list for example)

    In database reader panel (source), i wrote the following


    var dbConn = DatabaseConnectionFactory.createDatabaseConnection ('oracle.jdbc.OracleDriver','jdbcracle:thin:@192.168.1.13:1521:XE','myuser','mypasw ');
    var result = dbConn.executeCachedQuery("select patientid, firstname, lastname, sex, unit, status from patients");
    var name
    // YOUR CODE GOES HERE
    dbConn.close();
    // You may access this result with $('column_name')
    return result;

    and in Destination panel I wrote
    Connector type: File Writer ...
    Template : ${message.rawData}

    When I looking in destination file, only the first record appear
    When I add result.next() sentence in source Javascript, I got the next record ...

    Somebody now how I can get all the result directly in my output file

    Thanks for your help
Working...
X