Author |
Message
|
special_agent_Queue |
Posted: Thu Apr 05, 2007 10:52 am Post subject: ebcdic to ascii conversion or occurs depending on issue |
|
|
 Centurion
Joined: 27 Jul 2006 Posts: 102
|
My message flow takes in a flat CWF file created from COBOL. In this message, there is a field called COMMAND_CNT which is defined in the message set definition file as follows:
Physical Type: External Decimal (which the info center says is equivalent to a PIC 9 usage)
Length Count: 2
Length Unit: bytes.
The message, in its EDBCDIC form, has the hex value of 'F0F1' for this field. This converts to a hex value of '3031' when the message is converted to ASCII.
However, when the message goes through the flow, an error is thrown: ImbRecoverableException caught from worker->parseNext.. CWF Parsing error. CPI Converter Input Data Invalid (decimal).
Here's a little bit more detail:
Quote: |
(0x01000000):ParserException = (
(0x03000000):File = 'F:\build\S600_P\src\cpi\pwf\cwf\cwfworker.cpp'
(0x03000000):Line = 300
(0x03000000):Function = 'CWFWorker::parseNext'
(0x03000000):Type = ''
(0x03000000):Name = ''
(0x03000000):Label = ''
(0x03000000):Catalog = 'BIPv600'
(0x03000000):Severity = 3
(0x03000000):Number = 5171
(0x03000000):Text = 'CWF Parsing error'
(0x01000000):Insert = (
(0x03000000):Type = 2
(0x03000000):Text = '0'
)
(0x01000000):Insert = (
(0x03000000):Type = 5
(0x03000000):Text = 'CWFWorker::parseNext'
)
(0x01000000):Insert = (
(0x03000000):Type = 5
(0x03000000):Text = 'MsgCmd'
)
(0x01000000):Insert = (
(0x03000000):Type = 5
(0x03000000):Text = '397^COMMAND_CNT'
)
(0x01000000):Insert = (
(0x03000000):Type = 5
(0x03000000):Text = '/MsgCmd/369^MSG'
)
(0x01000000):Insert = (
(0x03000000):Type = 2
(0x03000000):Text = '319'
)
(0x01000000):ConversionException = (
(0x03000000):File = 'F:\build\S600_P\src\cpi\bsutils\datacnv.cpp'
(0x03000000):Line = 5349
(0x03000000):Function = 'DataCnv::validateDecimal'
(0x03000000):Type = ''
(0x03000000):Name = ''
(0x03000000):Label = ''
(0x03000000):Catalog = 'BIPv600'
(0x03000000):Severity = 3
(0x03000000):Number = 5505
(0x03000000):Text = 'CPI Converter Input Data Invalid'
(0x01000000):Insert = (
(0x03000000):Type = 5
(0x03000000):Text = 'decimal'
)
(0x01000000):Insert = (
(0x03000000):Type = 5
(0x03000000):Text = ' '
) |
I'm not sure why this happens, as the 3031 hex value should be the correct one?
I'm using v6.
Thanks for your help. |
|
Back to top |
|
 |
dsriksha |
Posted: Thu Apr 05, 2007 11:23 am Post subject: Re: ebcdic to ascii conversion or occurs depending on issue |
|
|
 Voyager
Joined: 27 Feb 2005 Posts: 95
|
I dont think its ASCII or EBCDIC issue. The problem may be with the data mis match. Observe the data type value that u reading for the COMMAND_CNT field. Make sure you are processing integer values for this filed . Also Look into your system error logs(application log, syslog)  |
|
Back to top |
|
 |
special_agent_Queue |
Posted: Fri Apr 06, 2007 4:45 am Post subject: |
|
|
 Centurion
Joined: 27 Jul 2006 Posts: 102
|
Thanks for your reply. I did not think it was a conversion issue.
I believe I am using integers: the hex 'F0F1' (EBCDIC) = hex '3031' (ASCII) = 01.
Can anyone offer some more advice? |
|
Back to top |
|
 |
wbi_telecom |
Posted: Fri Apr 06, 2007 6:24 am Post subject: |
|
|
 Disciple
Joined: 15 Feb 2006 Posts: 188 Location: Harrisburg, PA
|
The exception you have given indicates that the value you are mapping to the field expecting the Decimal is a non decimal. I tend to agree that its not a problem of ascii to ebcidic. Its a problem of your mapping. |
|
Back to top |
|
 |
special_agent_Queue |
Posted: Fri Apr 06, 2007 7:22 am Post subject: |
|
|
 Centurion
Joined: 27 Jul 2006 Posts: 102
|
Thanks. I get that it is a problem with my mapping.
Unfortunately, I've spent a couple of days looking into this, but I cannot figure out why. Can anyone help?
If you need more info, let me know.
Thanks again. |
|
Back to top |
|
 |
wbi_telecom |
Posted: Fri Apr 06, 2007 8:41 am Post subject: |
|
|
 Disciple
Joined: 15 Feb 2006 Posts: 188 Location: Harrisburg, PA
|
I assume you are getting this exception at the output node. Can you please share a trace containing ${Root} just before you put the message on the output queue? |
|
Back to top |
|
 |
special_agent_Queue |
Posted: Mon Apr 09, 2007 5:11 am Post subject: |
|
|
 Centurion
Joined: 27 Jul 2006 Posts: 102
|
Here's the thing - The traces don't get that far. The first one is what I get just trying to run it through (just after the input node). The 2nd one is what I get when I run it through with the debugger on (after a RCD node).
Quote: |
********** **TRACE AFTER INPUT NODE @ 2007-04-05 08:31:12.990733 ***ROOT*** (
(0x01000000):Properties = (
(0x03000000):MessageSet = 'DM4C3VG002001'
(0x03000000):MessageType = 'MsgCmd'
(0x03000000):MessageFormat = 'CWF1'
(0x03000000):Encoding = 785
(0x03000000):CodedCharSetId = 500
(0x03000000):Transactional = TRUE
(0x03000000):Persistence = FALSE
(0x03000000):CreationTime = GMTTIMESTAMP '2007-04-05 12:31:12.250'
(0x03000000):ExpirationTime = -1
(0x03000000):Priority = 0
(0x03000000):ReplyIdentifier = X'414d5120485542462020202020202020f6c5fc4520035e01'
(0x03000000):ReplyProtocol = 'MQ'
(0x03000000):Topic = NULL
(0x03000000):ContentType = ''
)
(0x01000000):MQMD = (
(0x03000000):SourceQueue = 'HUB_ADDR_MAINT_RPLY_QL'
(0x03000000):Transactional = TRUE
(0x03000000):Encoding = 785
(0x03000000):CodedCharSetId = 500
(0x03000000):Format = 'MQHRF2 '
(0x03000000):Version = 2
(0x03000000):Report = 0
(0x03000000):MsgType = 2
(0x03000000):Expiry = -1
(0x03000000):Feedback = 0
(0x03000000):Priority = 0
(0x03000000):Persistence = 0
(0x03000000):MsgId = X'c3e2d840d4d8c2c64040404040404040c066d07c79588600'
(0x03000000):CorrelId = X'414d5120485542462020202020202020f6c5fc4520035e01'
(0x03000000):BackoutCount = 0
(0x03000000):ReplyToQ = ' '
(0x03000000):ReplyToQMgr = 'MQBF '
(0x03000000):UserIdentifier = 'cicsuser '
(0x03000000):AccountingToken = X'150cc1d4d5c5e3f0f14be3c3e2c366d07bfdc31d000100000000000000000000'
(0x03000000):ApplIdentityData = ' '
(0x03000000):PutApplType = 1
(0x03000000):PutApplName = 'TCSC MQAM '
(0x03000000):PutDate = DATE '2007-04-05'
(0x03000000):PutTime = GMTTIME '12:31:12.250'
(0x03000000):ApplOriginData = ' '
(0x03000000):GroupId = X'000000000000000000000000000000000000000000000000'
(0x03000000):MsgSeqNumber = 1
(0x03000000):Offset = 0
(0x03000000):MsgFlags = 0
(0x03000000):OriginalLength = -1
)
(0x01000000):MQRFH2 = (
(0x03000000):Version = 2
(0x03000000):Format = 'MQSTR '
(0x03000000):Encoding = 785
(0x03000000):CodedCharSetId = 500
(0x03000000):Flags = 0
(0x03000000):NameValueCCSID = 1208
(0x01000000):usr = (
(0x01000000):ReplyToQmgr = (
(0x02000000): = 'HUBF '
)
(0x01000000):ReplyToQ = (
(0x02000000): = ' '
)
)
(0x01000000):mcd = (
(0x01000000):Msd = (
(0x02000000): = 'mrm'
)
(0x01000000):Set = (
(0x02000000): = 'DM4C3VG002001'
)
(0x01000000):Type = (
(0x02000000): = 'MsgCmd'
)
(0x01000000):Fmt = (
(0x02000000): = 'CWF1'
)
)
)
(0x01000021):MRM = ( |
Quote: |
********** **TRACE AFTER RCD NODE @ 2007-04-04 15:58:19.711084 ***ROOT*** (
(0x01000000):Properties = (
(0x03000000):MessageSet = 'DM4C3VG002001'
(0x03000000):MessageType = 'MsgCmdResponse'
(0x03000000):MessageFormat = 'CWF1'
(0x03000000):Encoding = 785
(0x03000000):CodedCharSetId = 500
(0x03000000):Transactional = TRUE
(0x03000000):Persistence = FALSE
(0x03000000):CreationTime = GMTTIMESTAMP '2007-04-04 19:57:54.340'
(0x03000000):ExpirationTime = -1
(0x03000000):Priority = 5
(0x03000000):ReplyIdentifier = X'414d5120485542462020202020202020f6c5fc4520033c02'
(0x03000000):ReplyProtocol = 'MQ'
(0x03000000):Topic = NULL
(0x03000000):ContentType = ''
)
(0x01000000):MQMD = (
(0x03000000):SourceQueue = 'HUB_ADDR_MAINT_RPLY_QL'
(0x03000000):Transactional = TRUE
(0x03000000):Encoding = 785
(0x03000000):CodedCharSetId = 500
(0x03000000):Format = 'MQHRF2 '
(0x03000000):Version = 2
(0x03000000):Report = 0
(0x03000000):MsgType = 2
(0x03000000):Expiry = -1
(0x03000000):Feedback = 0
(0x03000000):Priority = 5
(0x03000000):Persistence = 0
(0x03000000):MsgId = X'c3e2d840d4d8c2c64040404040404040c065f2777ab17e82'
(0x03000000):CorrelId = X'414d5120485542462020202020202020f6c5fc4520033c02'
(0x03000000):BackoutCount = 0
(0x03000000):ReplyToQ = ' '
(0x03000000):ReplyToQMgr = 'MQBF '
(0x03000000):UserIdentifier = 'cicsuser '
(0x03000000):AccountingToken = X'150cc1d4d5c5e3f0f14be3c3e2c365f277779539000100000000000000000000'
(0x03000000):ApplIdentityData = ' '
(0x03000000):PutApplType = 1
(0x03000000):PutApplName = 'TCSC MQAM '
(0x03000000):PutDate = DATE '2007-04-04'
(0x03000000):PutTime = GMTTIME '19:57:54.340'
(0x03000000):ApplOriginData = ' '
(0x03000000):GroupId = X'000000000000000000000000000000000000000000000000'
(0x03000000):MsgSeqNumber = 1
(0x03000000):Offset = 0
(0x03000000):MsgFlags = 0
(0x03000000):OriginalLength = -1
)
(0x01000000):MQRFH2 = (
(0x03000000):Version = 2
(0x03000000):Format = 'MQSTR '
(0x03000000):Encoding = 785
(0x03000000):CodedCharSetId = 500
(0x03000000):Flags = 0
(0x03000000):NameValueCCSID = 1208
(0x01000000):usr = (
(0x01000000):ReplyToQmgr = (
(0x02000000): = 'HUBF '
)
(0x01000000):ReplyToQ = (
(0x02000000): = ' '
)
)
(0x01000000):mcd = (
(0x01000000):Msd = (
(0x02000000): = 'mrm'
)
(0x01000000):Set = (
(0x02000000): = 'DM4C3VG002001'
)
(0x01000000):Type = (
(0x02000000): = 'MsgCmdResponse'
)
(0x01000000):Fmt = (
(0x02000000): = 'CWF1'
)
)
)
(0x0100001B):MRM = (
(0x01000013):ROUTER_RESPONSE_MSG_HDR = (
(0x0300000B):ERROR_INFO_CNT = 0
(0x0300000B):MESSAGE_INFO_CNT = 1
)
(0x01000013):MSG = (
(0x0300000B):MSG_ID = '1174578008875'
(0x0300000B):SESSION_ID = 'someSession'
(0x0300000B):AUTHENTICATION_ID = ''
(0x0300000B):CREATED_TS = '2007-04-04-15.57.54.334722'
(0x0300000B):EXPIRED_TS = ' '
(0x0300000B):SOURCE_ID = 'CMA'
(0x0300000B):DESTINATION_ID = 'EDB'
(0x0300000B):TXN_SCOPE = ''
(0x01000013):ERROR_INFO = (
(0x0300000B):ERROR_INFO_TYPE = ''
(0x0300000B):ERROR_INFO_CODE = ''
(0x0300000B):ERROR_INFO_TEXT = ''
)
(0x0300000B):COMMAND_CNT = 1
(0x01000013):CMD = (
(0x0300000B):CMD_ID = 'ID00001'
(0x0300000B):CMD_ACTION = 'add'
(0x0300000B):CMD_TYPE = 'response'
(0x0300000B):SUBJECT = 'address'
(0x0300000B):CMD_NAME = 'AddAddressResponse'
UNRESOLVED CHOICE = X'40404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404040404096924040404040404040'
(0x01000013):ERROR_INFO = (
(0x0300000B):ERROR_INFO_TYPE = ''
(0x0300000B):ERROR_INFO_CODE = ''
(0x0300000B):ERROR_INFO_TEXT = ''
)
(0x01000013):CMD_BODY = (
(0x0100001B):AddAddressResponse = (
(0x01000013):ADDRESS_IMPL = (
(0x0300000B):UUID = ''
(0x0300000B):KEY = ''
(0x0300000B):EFFECTIVE_DT = ''
(0x0300000B):PROCESS_TS = ''
(0x0300000B):CONSISTENCY_MARKER = ''
(0x0300000B):MODIFIED_BY = ''
)
)
)
)
)
)
) |
*Note* The 'Unresolved choice' is due to a redefined element that hasn't been accessed yet, so it's not sure which to use.
Thanks for all your help.
Has anyone come across something like this before? |
|
Back to top |
|
 |
fjb_saper |
Posted: Mon Apr 09, 2007 5:58 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
Again a Decimal is not an Integer and vice versa.
You need to resolve this conflict first and if need be use a cast.
Enjoy  _________________ MQ & Broker admin |
|
Back to top |
|
 |
special_agent_Queue |
Posted: Thu Apr 12, 2007 4:46 am Post subject: |
|
|
 Centurion
Joined: 27 Jul 2006 Posts: 102
|
I was able to solve this by using an RCD to change the message into a blob, and adding a compute node where it does a CREATE.. PARSE to create the MRM message.
I think this error was deceiving. It did not really have anything to do with the value being sent over for the field, but more to do with the fact that the parser could not decide which message set to use. (I noticed that no error was thrown when I used a RCD node to override the RFH2 header AND used the debugger, but with that same RCD node and without the debugger - it threw the same error.)
Can anyone think of an easier way to do this? I'm pretty sure there is one - it's just not striking me at the moment.
Thanks for your help. |
|
Back to top |
|
 |
|