Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

compare data in rexx

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
usharaniA

New User


Joined: 22 Jan 2008
Posts: 85
Location: India

PostPosted: Wed Jul 22, 2009 4:11 pm    Post subject: compare data in rexx
Reply with quote

Hi,
I want to compare two datas ,
data1=5.00
data2=5.0
I have used the compare build in function, but the result was a mismatch,
is there any build in function to compare only the actual values or else any other mean to solve this
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Wed Jul 22, 2009 4:26 pm    Post subject:
Reply with quote

Have you tried ...........................

IF DATA1 = DATA2
Back to top
View user's profile Send private message
usharaniA

New User


Joined: 22 Jan 2008
Posts: 85
Location: India

PostPosted: Wed Jul 22, 2009 4:36 pm    Post subject:
Reply with quote

thanks a lot.
I hav tried it, its working
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6967
Location: porcelain throne

PostPosted: Wed Jul 22, 2009 4:43 pm    Post subject:
Reply with quote

why not try
IF data1 = data2
then
else
if data1 < data2
then
else
if data1 = data2
then
end
end
end

what was the mismatch? that you are talking about?
the compare built-in function returns a zero of the strings are identical
otherwise you get the offset of the first offending char.

in an IF Data1 = Data2 are considered equal.

in an IF Data1 == Data2 are considered not equal.

maybe you want 'strict comparision operator'.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Wed Jul 22, 2009 5:06 pm    Post subject:
Reply with quote

Or you could have used the pad character in the compare statement.


Quote:
maybe you want 'strict comparision operator'.

Or maybe the super deluxe dominatrix comparison operator icon_pray.gif
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
This topic is locked: you cannot edit posts or make replies. Need help on If condition continuatio... ashok_uddaraju CLIST & REXX 4 Fri May 19, 2017 8:55 am
No new posts member list compare jzhardy TSO/ISPF 6 Fri May 12, 2017 3:18 pm
No new posts Replace values in the input data Vikas Maharnawar DFSORT/ICETOOL 10 Thu May 11, 2017 2:18 pm
No new posts Group Data based on a key Arun Raj DFSORT/ICETOOL 7 Thu Apr 27, 2017 11:29 pm
No new posts unload data from table with lob columns farhad_evan DB2 0 Sat Apr 22, 2017 1:32 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us