Re: ISPF Panel Issue with HEX Data

2007-06-12 Thread Thompson, Steve
-Original Message-
From: IBM Mainframe Discussion List [mailto:[EMAIL PROTECTED] On
Behalf Of Lizette Koehler
Sent: Tuesday, June 12, 2007 1:06 PM
To: IBM-MAIN@BAMA.UA.EDU
Subject: ISPF Panel Issue with HEX Data

Hi All,

We are z/OS V1.7.

I am trying to validate HEX data in an ISPF Panel.  I am working with
UCB strings.  So they are 4 digits long containing  - .

I have a test in my panel
  IF (&SR01 > &ER01) then produce a message indicating beginning range
is greater than ending range.  
  So if SR01 = 100F adn ER01 = 1000 I want the message produced.  Else
if SR01 = 1000 and ER01 = 100F it is okay.


I'm going to take a guess: your numbers may be getting extended so that
they are negative (a la LH into a register rather than ICM...) and so
your compares are tainted by that side effect (unwanted though it may
be).

Later,
Steve Thompson

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: ISPF Panel Issue with HEX Data

2007-06-12 Thread Chicklon, Tom


My data is SR01 = 3000and ER01 = 30DF

  If (&SR01 > &ER01) .MSG = DRM001   

I get the message saying SR01 is greater than 30DF and I cannot determine
why.  It is almost like it is ignoring the rules for Hexidecimal data.

SR01 Pool (S)  - ISPYX211  VALUE(3000)  
 ..CHG by SELECT   - ISPYX212   
ER01 Pool (S)  - ISPYX211  VALUE(30DF)  
 ..CHG by SELECT   - ISPYX212   




While in hex, x'3000' is definitely less than x'30DF' .

But when represented as a character string, c'3000' = x'F3F0F0F0' which is
greater than c'30DF' = x'F3F0C4C6'.

Tom Chicklon

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: ISPF Panel Issue with HEX Data

2007-06-12 Thread Itschak Mugzach
I would write a small Rexx panel exit to do a hex comparison... 

Itschak  

-Original Message-
From: IBM Mainframe Discussion List [mailto:[EMAIL PROTECTED] On Behalf
Of Lizette Koehler
Sent: Tuesday, June 12, 2007 8:06 PM
To: IBM-MAIN@BAMA.UA.EDU
Subject: ISPF Panel Issue with HEX Data

Hi All,

We are z/OS V1.7.

I am trying to validate HEX data in an ISPF Panel.  I am working with UCB
strings.  So they are 4 digits long containing  - .

I have a test in my panel
  IF (&SR01 > &ER01) then produce a message indicating beginning range is
greater than ending range.  
  So if SR01 = 100F adn ER01 = 1000 I want the message produced.  Else if
SR01 = 1000 and ER01 = 100F it is okay.



My data is SR01 = 3000and ER01 = 30DF

  If (&SR01 > &ER01) .MSG = DRM001   

I get the message saying SR01 is greater than 30DF and I cannot determine
why.  It is almost like it is ignoring the rules for Hexidecimal data.

SR01 Pool (S)  - ISPYX211  VALUE(3000)  
 ..CHG by SELECT   - ISPYX212   
ER01 Pool (S)  - ISPYX211  VALUE(30DF)  
 ..CHG by SELECT   - ISPYX212   


If this looks okay, I will open an ETR with IBM.  I know this was working
under z/OS V1.4.  But for some reason this same code is not working for z/OS
V1.7.

Lizette

--
For IBM-MAIN subscribe / signoff / archive access instructions, send email
to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO Search the
archives at http://bama.ua.edu/archives/ibm-main.html

No virus found in this incoming message.
Checked by AVG Free Edition. 
Version: 7.5.472 / Virus Database: 269.8.13/844 - Release Date: 11/06/2007
17:10
 

No virus found in this outgoing message.
Checked by AVG Free Edition. 
Version: 7.5.472 / Virus Database: 269.8.13/844 - Release Date: 11/06/2007
17:10

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: ISPF Panel Issue with HEX Data

2007-06-12 Thread Steve Comstock

Lizette Koehler wrote:

Hi All,

We are z/OS V1.7.

I am trying to validate HEX data in an ISPF Panel.  I am working with UCB 
strings.  So they are 4 digits long containing  - .

I have a test in my panel
  IF (&SR01 > &ER01) then produce a message indicating beginning range is greater than ending range.  
  So if SR01 = 100F adn ER01 = 1000 I want the message produced.  Else if SR01 = 1000 and ER01 = 100F it is okay.




My data is SR01 = 3000and ER01 = 30DF

  If (&SR01 > &ER01) .MSG = DRM001   


I get the message saying SR01 is greater than 30DF and I cannot determine why.  
It is almost like it is ignoring the rules for Hexidecimal data.

SR01 Pool (S)  - ISPYX211  VALUE(3000)  
 ..CHG by SELECT   - ISPYX212   
ER01 Pool (S)  - ISPYX211  VALUE(30DF)  
 ..CHG by SELECT   - ISPYX212   



If this looks okay, I will open an ETR with IBM.  I know this was working under 
z/OS V1.4.  But for some reason this same code is not working for z/OS V1.7.

Lizette


Try indenting the assignment, on a separate line. That is:

If (&SR01 > &ER01)
   .MSG = DRM001



Kind regards,

-Steve Comstock
The Trainer's Friend, Inc.

303-393-8716
http://www.trainersfriend.com

  z/OS Application development made easier
* Our classes include
   + How things work
   + Programming examples with realistic applications
   + Starter / skeleton code
   + Complete working programs
   + Useful utilities and subroutines
   + Tips and techniques

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: ISPF Panel Issue with HEX Data

2007-06-12 Thread Steve Comstock

Thompson, Steve wrote:

-Original Message-
From: IBM Mainframe Discussion List [mailto:[EMAIL PROTECTED] On
Behalf Of Lizette Koehler
Sent: Tuesday, June 12, 2007 1:06 PM
To: IBM-MAIN@BAMA.UA.EDU
Subject: ISPF Panel Issue with HEX Data

Hi All,

We are z/OS V1.7.

I am trying to validate HEX data in an ISPF Panel.  I am working with
UCB strings.  So they are 4 digits long containing  - .

I have a test in my panel
  IF (&SR01 > &ER01) then produce a message indicating beginning range
is greater than ending range.  
  So if SR01 = 100F adn ER01 = 1000 I want the message produced.  Else

if SR01 = 1000 and ER01 = 100F it is okay.


I'm going to take a guess: your numbers may be getting extended so that
they are negative (a la LH into a register rather than ICM...) and so
your compares are tainted by that side effect (unwanted though it may
be).

Later,
Steve Thompson


I don't think so, since neither of the values have an '8' or
higher for their leftmost hex digit.


Kind regards,

-Steve Comstock
The Trainer's Friend, Inc.

303-393-8716
http://www.trainersfriend.com

  z/OS Application development made easier
* Our classes include
   + How things work
   + Programming examples with realistic applications
   + Starter / skeleton code
   + Complete working programs
   + Useful utilities and subroutines
   + Tips and techniques

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: ISPF Panel Issue with HEX Data

2007-06-12 Thread Veilleux, Jon L
Since you are talking about a panel, you aren't trying to compare
display characters are you? Are the values truly hex values or the
display equivalent? (1000x vs F1F0F0F0c) 


Jon L. Veilleux
[EMAIL PROTECTED]
(860) 636-2683 


-Original Message-
From: IBM Mainframe Discussion List [mailto:[EMAIL PROTECTED] On
Behalf Of Lizette Koehler
Sent: Tuesday, June 12, 2007 2:06 PM
To: IBM-MAIN@BAMA.UA.EDU
Subject: ISPF Panel Issue with HEX Data

Hi All,

We are z/OS V1.7.

I am trying to validate HEX data in an ISPF Panel.  I am working with
UCB strings.  So they are 4 digits long containing  - .

I have a test in my panel
  IF (&SR01 > &ER01) then produce a message indicating beginning range
is greater than ending range.  
  So if SR01 = 100F adn ER01 = 1000 I want the message produced.  Else
if SR01 = 1000 and ER01 = 100F it is okay.



My data is SR01 = 3000and ER01 = 30DF

  If (&SR01 > &ER01) .MSG = DRM001   

I get the message saying SR01 is greater than 30DF and I cannot
determine why.  It is almost like it is ignoring the rules for
Hexidecimal data.

SR01 Pool (S)  - ISPYX211  VALUE(3000)  
 ..CHG by SELECT   - ISPYX212   
ER01 Pool (S)  - ISPYX211  VALUE(30DF)  
 ..CHG by SELECT   - ISPYX212   


If this looks okay, I will open an ETR with IBM.  I know this was
working under z/OS V1.4.  But for some reason this same code is not
working for z/OS V1.7.

Lizette

--
For IBM-MAIN subscribe / signoff / archive access instructions, send
email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO Search
the archives at http://bama.ua.edu/archives/ibm-main.html
This e-mail may contain confidential or privileged information. If
you think you have received this e-mail in error, please advise the
sender by reply e-mail and then delete this e-mail immediately.
Thank you. Aetna

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: ISPF Panel Issue with HEX Data

2007-06-12 Thread Thompson, Steve
-Original Message-
From: IBM Mainframe Discussion List [mailto:[EMAIL PROTECTED] On
Behalf Of Steve Comstock
Sent: Tuesday, June 12, 2007 1:59 PM
To: IBM-MAIN@BAMA.UA.EDU
Subject: Re: ISPF Panel Issue with HEX Data

Thompson, Steve wrote:

> I'm going to take a guess: your numbers may be getting extended so 
> that they are negative (a la LH into a register rather than ICM...) 
> and so your compares are tainted by that side effect (unwanted though 
> it may be).
> 
> Later,
> Steve Thompson

I don't think so, since neither of the values have an '8' or higher for
their leftmost hex digit.



Yeah, after I saw someone else's post I realized that she wasn't in IPCS
using CLIST. I'm working on internal tools in REXX and having some
issues here and there and so have a severe case of tunnel vision. So I
missed the type of ISPF stuff she was actually in...

Regards,
Steve Thompson

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: ISPF Panel Issue with HEX Data

2007-06-12 Thread Lizette Koehler
Maybe I am not clear myself on what ISPF can do in the PANEL options.

I have a field on my Selection Panel.  It has SR01 and ER01 (Starting Range and 
Ending Range) that are to be UCB addresses.  This field is EBCDIC though the 
numbers are Hex in nature.  I am trying to validate that the field entered is a 
range from - and that the Ending Range is not smaller than the starting 
range.

I would enter 30FF for a valid UCB Address (not x'30ff' but c'30ff').  I like 
letting the panel do as much of the work as possible.  But I am not yet ready 
to jump into using REXX in the panel.  

I can place this code in the REXX in my routine that displays the Panel, but 
had hoped that ISPF could handle it thru the VER PICT function or something 
similar.

I maybe barking up the wrong tree and just need to adjust my process to use 
REXX to do the validation and verification.  

I will noodle this some more over the weekend.

Thanks for your input.

Lizette

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: ISPF Panel Issue with HEX Data

2007-06-12 Thread Tony Harminc
On Tue, 12 Jun 2007 16:16:59 -0400, Lizette Koehler wrote:

>Maybe I am not clear myself on what ISPF can do in the PANEL options.
>
>I have a field on my Selection Panel.  It has SR01 and ER01 (Starting Range
and Ending Range) that are to be UCB addresses.  This field is EBCDIC though
the numbers are Hex in nature.  I am trying to validate that the field
entered is a range from - and that the Ending Range is not smaller
than the starting range.
>
>I would enter 30FF for a valid UCB Address (not x'30ff' but c'30ff').  I
like letting the panel do as much of the work as possible.  But I am not yet
ready to jump into using REXX in the panel.

It's a classic problem found in any situation where you are trying to
manipulate hex values as character strings. In EBCDIC, the byte values for
the characters A-F are lower than those for the numbers 0-9. In ASCII they
are higher, so sorting hex numbers-as-strings works fine. You can see the
problem using anything that compares strings, e.g. sort in ISPF EDIT.

The classic way around it is to translate one or both ranges to something
else, e.g. 0-9 could become lower case a-j for sorting and comparison
purposes. Then you have to retranslate for display. Or perhaps you don't
have to sort; maybe you are just checking ranges or the like. In this case
you can convert just for the compares.

There is one other common gotcha that will surely eventually bite you if you
decide to use REXX to work with hex values in strings. One day one of your
UCBs will be something like 30E0, and you will compare it to say 1000, and
30E0 will be less! This is because REXX treats 30E0 as 30*10**0, or 30. You
have to use the == operator rather than simple = to force strong comparison.

But that's not (yet) your problem here.

Tony H.

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: ISPF Panel Issue with HEX Data

2007-06-12 Thread Ted MacNEIL
>I would enter 30FF for a valid UCB Address (not x'30ff' but c'30ff').

Unfortunately, C'30FF' is much different.
You have to convert to HEX to do the comparison.
And, I have not been able to see how to do it in RAW panels.

You need an exit, or a wrapper, to convert to C2X and do the comparison.


-
Too busy driving to stop for gas!

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html


Re: ISPF Panel Issue with HEX Data

2007-06-13 Thread Veilleux, Jon L
If you are on z/OS 1.8 you can imbed REXX code in the panel definition
using the *REXX statement. See chapter 7 in the ISPF Dialog Developers
Guide. 

7.2.7 The *REXX Statement


The *REXX statement is used to invoke REXX code in a panel's )INIT,
)REINIT, or )PROC section. The REXX can be coded within the panel source
immediately after the *REXX statement, or the name of a member
containing a REXX program can be supplied. 




   *REXX[([*,]value,value,...[,(>member)])]

 


 


Jon L. Veilleux
[EMAIL PROTECTED]
(860) 636-2683 


-Original Message-
From: IBM Mainframe Discussion List [mailto:[EMAIL PROTECTED] On
Behalf Of Ted MacNEIL
Sent: Tuesday, June 12, 2007 4:29 PM
To: IBM-MAIN@BAMA.UA.EDU
Subject: Re: ISPF Panel Issue with HEX Data

>I would enter 30FF for a valid UCB Address (not x'30ff' but c'30ff').

Unfortunately, C'30FF' is much different.
You have to convert to HEX to do the comparison.
And, I have not been able to see how to do it in RAW panels.

You need an exit, or a wrapper, to convert to C2X and do the comparison.


-
Too busy driving to stop for gas!

--
For IBM-MAIN subscribe / signoff / archive access instructions, send
email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO Search
the archives at http://bama.ua.edu/archives/ibm-main.html
This e-mail may contain confidential or privileged information. If
you think you have received this e-mail in error, please advise the
sender by reply e-mail and then delete this e-mail immediately.
Thank you. Aetna

--
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html