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 » WebSphere Message Broker (ACE) Support » BLOB into Character

Post new topic  Reply to topic
 BLOB into Character « View previous topic :: View next topic » 
Author Message
msiegert
PostPosted: Tue Jun 03, 2003 1:25 am    Post subject: BLOB into Character Reply with quote

Apprentice

Joined: 05 Aug 2001
Posts: 29

Hi there!

I'm using the CAST function to transform the value of one data type into another data type, in my case first it is Character into BLOB and afterwards the BLOB field should come up as a normal Character field again.

SET FieldA= CAST(InputRoot.XML.FieldA AS BLOB CCSID 1208 ENCODING 546); -> works fine

SET FieldA= CAST(FieldA AS CHARACTER CCSID 819 ENCODING 546);
-> lets FieldA look like the same as the BLOB field
How do I get a readable content of the field again.

Thanks for help!
Marc
Back to top
View user's profile Send private message
drajib
PostPosted: Tue Jun 03, 2003 4:59 am    Post subject: Reply with quote

Apprentice

Joined: 25 Mar 2003
Posts: 42
Location: India

I don't think that you can readily cast a blob into a readable content. An RCD node has to be used with message domain set as MRM.

Pls. let me know if you have any other solution

Best regards
Back to top
View user's profile Send private message
msiegert
PostPosted: Tue Jun 03, 2003 6:00 am    Post subject: Reply with quote

Apprentice

Joined: 05 Aug 2001
Posts: 29

it worked after setting

SET FieldA= CAST(InputRoot.XML.FieldA AS BLOB CCSID 1208 ENCODING 546);

and using the OVERLAY function

WHILE POSITION('e282ac' IN FieldA) > 0 DO
SET FieldA = OVERLAY(FieldA PLACING '266575726f3b' FROM POSITION('e282ac' IN FieldA) FOR 6);
END WHILE;

you should declare FieldA as a BLOB again, because OVERLAY works with CHAR only:

DECLARE help BLOB;
SET help = FieldA;
SET FieldA = CAST(help AS CHARACTER CCSID 819 ENCODING 546);
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 » WebSphere Message Broker (ACE) Support » BLOB into Character
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.