web stats
Mirth Test Appliance error V3.8 - Mirth Community

Go Back   Mirth Community > Mirth Connect > Support

Reply
 
Thread Tools Display Modes
  #1  
Old 10-23-2019, 03:09 PM
fchang888 fchang888 is offline
Mirth Newb
 
Join Date: Mar 2015
Posts: 24
fchang888 is on a distinguished road
Default Mirth Test Appliance error V3.8

Mirth Appliance V3.8.0 in TEST
Mirth Connect V3.1.1.7461 in PROD



I have a query into the SQL Server DB on one of the channels but I am getting an error on the query.

The same query in PROD works fine but the TEST one is giving an error.

I did a manual query on the SQL Server query window and it is returning a value.

This is the error I am getting :

FT1-7 = 40101057 in this case

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

320: var chargeCode;

321: var incomingCode;

322: for each (ft1 in msg.FT1) {

323: incomingCode = ft1['FT1.7']['FT1.7.1'].toString();

324: logger.info("incomingCode = "+incomingCode);

325: chargeCode = $g('srxToPar')[incomingCode];

326: logger.info("chargeCode = "+chargeCode);

327:

328: ft1['FT1.7']['FT1.7.1'] = typeof chargeCode == 'undefined' ? incomingCode : chargeCode;

329: }

LINE NUMBER: 325

DETAILS: TypeError: Cannot read property "40101057" from null



This is in our Global Script.



var dbConn = function_GetDbConnectionInterfaces;

result = dbConn.executeCachedQuery('SELECT Description, RTRIM(LTRIM(Code_CC)), RTRIM(LTRIM(Code_SCM)) FROM CDM_MAP');

var parToSrx = new Array();

var srxToPar = new Array();

while (result.next()) {

var desc = result.getString(1);

var parCode = result.getString(2);

var srxCode = result.getString(3);

parToSrx[parCode] = srxCode;

srxToPar[srxCode] = parCode;

}

$g('parToSrx',parToSrx);

$g('srxToPar',srxToPar);
Reply With Quote
  #2  
Old 10-24-2019, 04:56 AM
cory_cole cory_cole is offline
Mirth Guru
 
Join Date: Mar 2012
Posts: 1,360
cory_cole is on a distinguished road
Default

Check your Code_SCM in the database. Somewhere there at least one that is null.
Reply With Quote
Reply

Tags
dbconn, global script, sql error, sql query

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -8. The time now is 12:21 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2020, vBulletin Solutions, Inc.
Mirth Corporation