ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » General Discussion » CICS DFDL Parsing Issue \u0000\u0000\u0000\f\u0000\f

Post new topic  Reply to topic
 CICS DFDL Parsing Issue \u0000\u0000\u0000\f\u0000\f « View previous topic :: View next topic » 
Author Message
muthu121521
PostPosted: Wed Apr 03, 2019 11:11 am    Post subject: CICS DFDL Parsing Issue \u0000\u0000\u0000\f\u0000\f Reply with quote

Apprentice

Joined: 31 Aug 2015
Posts: 36

Hi All,
I am parsing the CICS Cobol copybook response and assign that to a variable.

for some fields I am getting the below values
'\u0000\u0000\u0000\f\u0000\f'

but when in debug mode for that field , i am not able to see any special character or '\u0000\u0000\u0000\f\u0000\f' post the cics call invocation.
Can any one let me know how to get rid of that response characters '\u0000\u0000\u0000\f\u0000\f' .
I have tried to cast it as character with ccsid 1208 546 encoding, same issue persists
Back to top
View user's profile Send private message
Vitor
PostPosted: Wed Apr 03, 2019 11:22 am    Post subject: Re: CICS DFDL Parsing Issue \u0000\u0000\u0000\f\u0000\f Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

muthu121521 wrote:
for some fields I am getting the below values
'\u0000\u0000\u0000\f\u0000\f'


It's very common for MF CICS application to use X'00' in variables that are not set; literally nulling them out.

muthu121521 wrote:
but when in debug mode for that field , i am not able to see any special character or '\u0000\u0000\u0000\f\u0000\f' post the cics call invocation.


a) the debugger is notoriously bad with parsing and data issues, because it has to parse the data to show it in the debugger.

b) what were you expecting to see? That's not a displayable character.

muthu121521 wrote:
Can any one let me know how to get rid of that response characters '\u0000\u0000\u0000\f\u0000\f' .


Why do you want to get rid of them, rather than processing them as the nulls they are? While the DFDL wizard that converts copybooks won't do that, it's perfectly possible to edit it such that they're handled.

muthu121521 wrote:
I have tried to cast it as character with ccsid 1208 546 encoding, same issue persists


Of course it does. The x'00' value is NULL in every character set I'm familiar with and never printable.

How did you come up with 1208? If anything, one of the EBCDIC sets would have made more sense (and still not helped). I'm just curious.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
Vitor
PostPosted: Wed Apr 03, 2019 11:26 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

To prove I'm not making this up (as if I would!), see here.

LOW-VALUES is the COBOL constant that represents 1-n X'00' characters. You see the same principle at work with the MQC constants or the BrokerName variable in IIB.

Hope this clarifies. MF people; we're just a set of wacky
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
muthu121521
PostPosted: Wed Apr 03, 2019 11:47 am    Post subject: Reply with quote

Apprentice

Joined: 31 Aug 2015
Posts: 36

I have a requirement to sent that as json reply with out transforming it , so in the json reply i am getting it as '\u0000\u0000\u0000\f\u0000\f' how do i remove that ?
Back to top
View user's profile Send private message
Vitor
PostPosted: Wed Apr 03, 2019 11:54 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

muthu121521 wrote:
I have a requirement


From whom? Why?

muthu121521 wrote:
to sent that as json reply with out transforming it

...

how do i remove that ?


Which is it? Don't transform it or remove the null values? It can't be both.

If you just want to send it, send it. If you want to remove them, adjust the DFDL model as I describe above to recognize these as nulls.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
muthu121521
PostPosted: Wed Apr 03, 2019 12:13 pm    Post subject: Reply with quote

Apprentice

Joined: 31 Aug 2015
Posts: 36

I have reimported my cobolcopybooks by selecting the options for strings to recognize the null values ,even then i am getting the below characters for another field with carriage feed attached to it.
'\u0000\u0000\u0000\f\u0000\f'
Back to top
View user's profile Send private message
Vitor
PostPosted: Thu Apr 04, 2019 4:53 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

muthu121521 wrote:
I have reimported my cobolcopybooks by selecting the options for strings to recognize the null values ,even then i am getting the below characters for another field with carriage feed attached to it.
'\u0000\u0000\u0000\f\u0000\f'


Vitor wrote:
While the DFDL wizard that converts copybooks won't do that,it's perfectly possible to edit it such that they're handled.


Remember that the original MF data won't have carriage feed characters in it (because that concept doesn't exist in z/OS).

You talk about "the CICS call invocation"; so to be clear you're using the CICS node in IIB to call the CTG? Are you using containers or COMMAREA? Is there any intermediate conversion going on?
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
muthu121521
PostPosted: Thu Apr 04, 2019 5:25 am    Post subject: Reply with quote

Apprentice

Joined: 31 Aug 2015
Posts: 36

Vitor wrote:
muthu121521 wrote:
I have reimported my cobolcopybooks by selecting the options for strings to recognize the null values ,even then i am getting the below characters for another field with carriage feed attached to it.
'\u0000\u0000\u0000\f\u0000\f'


Vitor wrote:
While the DFDL wizard that converts copybooks won't do that,it's perfectly possible to edit it such that they're handled.


You talk about "the CICS call invocation"; so to be clear you're using the CICS node in IIB to call the CTG? Are you using containers or COMMAREA? Is there any intermediate conversion going on?


I am using Channel Containers to call the CICS Service and parsing it using the containers.
All other fields which was sending only \u0000\u0000 was defaulted to null when i set the low values set to null by changing the dfdl parse options for the copybook containers.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » General Discussion » CICS DFDL Parsing Issue \u0000\u0000\u0000\f\u0000\f
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.