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 » CHAR to INT...

Post new topic  Reply to topic
 CHAR to INT... « View previous topic :: View next topic » 
Author Message
filip
PostPosted: Wed Jul 02, 2003 8:05 am    Post subject: CHAR to INT... Reply with quote

Newbie

Joined: 02 Jul 2003
Posts: 1

How can I convert a char to an integer (CAREFUL: THE CHAR IS NOT '3' or '2', it's 'a' or 'b'...) ?

Thanks.
Back to top
View user's profile Send private message
kirani
PostPosted: Wed Jul 02, 2003 8:29 am    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

You can use CAST function to convert a char data type to an integer, but the broekr will throw an exception if the char datatype contains non-numeric chars.
_________________
Kiran


IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries

Back to top
View user's profile Send private message Visit poster's website
RichA
PostPosted: Thu Jul 03, 2003 6:59 am    Post subject: Reply with quote

Centurion

Joined: 14 Mar 2002
Posts: 102

Could you do it in some form of case statement?
outputvar = CASE inputvar WHEN 'a' THEN 1
WHEN 'b' THEN 2 etc.
or were you trying to convert an ascii char it to ascii value?
not sure about how to do that, short of writing a plugin or just using a really long case statement.
Back to top
View user's profile Send private message MSN Messenger
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » CHAR to INT...
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.