Mirth Community

Mirth Community (http://www.mirthcorp.com/community/forums/index.php)
-   Support (http://www.mirthcorp.com/community/forums/forumdisplay.php?f=6)
-   -   Getting the D_MC2 Message Id in Channel Destingation (http://www.mirthcorp.com/community/forums/showthread.php?t=216619)

ea25 10-31-2016 06:26 AM

Getting the D_MC2 Message Id in Channel Destingation
 
Our system currently archives messages and the File Pattern to build the filename includes the Message ID. This Message ID corresponds to the Message ID which is held in the D_MC2 table and the corresponding code is ${message.messageId}

Is it possible to get the same Message ID (residing in the D_MC2 table) so that it can be used in the JavaScript editor in the Destination script of the Channel. I do have a Message ID mapping listed under the Destination Mappings. However this translates to connectorMessage.getMessageId() which doesn't return the same value I'm after.

Thanks in advanced for your help.

narupley 10-31-2016 07:43 AM

That appears to work fine for me.

ea25 10-31-2016 08:16 AM

Thanks narupley for getting back to me.

I take it that for you ${message.messageId} in the Archiving section and connectorMessage.getMessageId() in the Channel Destination section are both returning the Message ID from D_MC2 table.

For me, the connectorMessage.getMessageId() is returning a message id which its value is way smaller than the maximum id in D_MC2. Not sure how you got yours to work.


All times are GMT -8. The time now is 09:20 AM.

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