Skip to content

Put message not writing same message to MQ side , it writing ......&))  #177

@jptech8

Description

@jptech8

Below peice of code not same string to MQside instead its writing some gibberish headers character at MQ side , it set MQMDas well

function putMessage(hObj) {

55

56 var msg = 'MSH|^~\&|SENDING_APP|SENDING_FACILITY|RECEIVING_APP|RECEIVING_FACILITY|20220229120000||ADT^A08|123456789|P|2.3||||'

57

58 var mqmd = new mq.MQMD(); // Defaults are fine.

59 var pmo = new mq.MQPMO();

60var mqmd = new mq.MQMD();

mqmd.Format = 'MQSTR'

62 pmo.Options = MQC.MQPMO_NO_SYNCPOINT |

63 MQC.MQPMO_NEW_MSG_ID |

64 MQC.MQPMO_NEW_CORREL_ID;

65

66 mq.Put(hObj,mqmd,pmo,msg,function(err) {

67 if (err) {

68 console.log(formatErr(err));

69 } else {

70 console.log("MsgId: " + toHexString(mqmd.MsgId));

71 console.log("MQPUT successful");

72 }

73 });

74}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions