Portal | IBM Manuals | Downloads | Products | Refer | Info | Programs | JCLs | Forum Rules*| Site Map | Mainframe CD 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index
 
Register
 
IBMMAINFRAMES.com - IBM Mainframe Support Forums Index FAQ Search Memberlist Usergroups Profile Log in to check your private messages Log in
 
give one example for LOW & HIGH functions in PL/1

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> PL/I & ASSEMBLER
Author Message
G.S.Sekhar

New User


Joined: 19 Aug 2005
Posts: 5

PostPosted: Thu Sep 29, 2005 5:41 pm    Post subject: give one example for LOW & HIGH functions in PL/1
Reply with quote

Hi,

If anyone give explanation and example for LOW & HIGH functions in PL/1. It's so greatful to me. Thanks in advance.
Back to top
View user's profile Send private message
References
PostPosted: Thu Sep 29, 2005 5:41 pm    Post subject: Re: give one example for LOW & HIGH functions in PL/1 Reply with quote

Athanga

New User


Joined: 29 Sep 2005
Posts: 9

PostPosted: Fri Sep 30, 2005 11:13 pm    Post subject: Re: give one example for LOW & HIGH functions in PL/1
Reply with quote

HI...

check this ..

let a variable be ABC and you want to initialize with low values or high values then use


ABC = LOW(CSTG(ABC))
ABC = HIGH(CSTG(ABC))

here CSTG menas current storage area of that variable will be taken or you can hard code to how many bytes of that variable need to be initialized.

ie

ABC = LOW(10)
ABC = HIGH(10)


I am not 100% sure..
Back to top
View user's profile Send private message
Sridevi_C

Active User


Joined: 22 Sep 2005
Posts: 107
Location: Concord, New Hampshire, USA.

PostPosted: Sat Oct 01, 2005 1:27 am    Post subject:
Reply with quote

Hi Sekhar,
LOW and HIGH buitin functions return character that is the lowest and highest respectively of the collating sequence.The returned character is repeated depending upon the length specified.
Example:
NAME = LOW(25);
Say,NAME is declared as CHAR(25) and the lowest value of the collating sequence is BLANK.Now the above statement moves 25 blanks to NAME,ie. NAME is initialized to spaces.
My explanation resembles Athanga's.I am very sure about what I spoke, but I couldn't speak in terms of CSTG.
Hope this helps...
Thanks!
Sridevi.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> PL/I & ASSEMBLER All times are GMT + 6 Hours
Page 1 of 1