Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Modify the value of a extensionvariable in an ISPF-Table
Goto page 1, 2  Next
 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
UmeySan

Active Member


Joined: 22 Aug 2006
Posts: 768
Location: Germany

PostPosted: Wed Nov 14, 2018 11:48 pm    Post subject: Modify the value of a extensionvariable in an ISPF-Table
Reply with quote

Hi Experts,

I'm trying to modify the value of a extensionvariable of a ISPF table.
The table has no key-fields, only these extensionvariables.
The table has only one row.

After a TBGET i loop through all variable-names. For a specific variable i modify the value. At end i try to update the row with TBPUT .

TBGET EQQAPROF SAVENAME(UV) ...
VARNAMES = TRANSLATE(UV," ","()")
VARCOUNT = WORDS(VARNAMES)

DO VARINDX = 1 TO VARCOUNT
VAR = WORD(VARNAMES,VARINDX)
IF VAR = 'blablabla'
VAR = ZZSTRG ...new Value is in ZZSTRG
SAY LEFT(VAR,16,".")"--"VALUE(VAR) ...just to be sure
END

TBPUT EQQAPROF SAVE("VARNAMES") ORDER

So everything seams right, only the TBPUT gets an Error ISPS110
Saying that there are more than 254 variables in the variable-list.

OK, thats right, cause i have 697 extensionvariables in that [swear word deleted] table.

Doing a TBPUT directly after the modification of the specific variable with only the name of the variable destroys the table. Meaning it leaves the table with only the variable used in TBPUT, All others vanished.

So question is: How will i be able to update this table with all his 697
extensionvariables.

I tryed TBMOD, didn't work either. A TBMOD, in the lopp, directly after the check of the variable-name, with or without modifying the value, updates all extensionvariables but also adds some more rows to the table.

So hopefully someone can put me in the right direction to solve that problem.
Back to top
View user's profile Send private message

Willy Jensen

Active User


Joined: 01 Sep 2015
Posts: 248
Location: Denmark

PostPosted: Thu Nov 15, 2018 4:07 am    Post subject:
Reply with quote

Well, if the limit is 254 then that is it, no amount of cursing will change it.
Time for a rethink i.e. having just one variable with a separator between the values? Remember that you in REXX you can parse with a non-displayable separation character.
Back to top
View user's profile Send private message
UmeySan

Active Member


Joined: 22 Aug 2006
Posts: 768
Location: Germany

PostPosted: Fri Nov 16, 2018 7:28 pm    Post subject:
Reply with quote

Thank's a lot Will Jensen.

But is there a way to update only a specific variable of that row with it's 697 extension variables.

Doing a TBPUT with only one variable seams to destroy the table.

It's been a while that i'm doing some Rexx, so perhaps i'm missing something.

Jjeg √łnsker Dem en god weekend
Back to top
View user's profile Send private message
Willy Jensen

Active User


Joined: 01 Sep 2015
Posts: 248
Location: Denmark

PostPosted: Fri Nov 16, 2018 7:45 pm    Post subject:
Reply with quote

No, that is what I am saying, you have a a maximum of 254 extension variables. If you need more than that you have to do it differently.
TBPUT with one variable does not technically destroy the table, it just rewrites the row with that one variable. Do you really need 697 variables in one row? You could transpose the table to 697 rows with one variable in each. Or as I suggested initially, use a delimiter and REXX PARSE with one variable in the row. i.e.:
Code:
 "tbcreate tbl1 names(var1) nowrite"   
 p1='Kilroy'                           
 p2='was'                               
 p3='here'                             
 dlm = 'ff'x                           
 var1 = p1 dlm p2 dlm p2               
 "tbadd tbl1"                           
 . . .                       
 "tbget tbl1"                           
 parse var var1 p1 (dlm) p2 (dlm) p2 
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 2128
Location: Silicon Valley

PostPosted: Mon Nov 19, 2018 4:09 am    Post subject: Reply to: Modify the value of a extensionvariable in an ISPF-Table
Reply with quote

Can you provide a trace?

My theory is that your list of variable names includes unexpected text.

I doubt that you could have created a table with so many extension variables if you cannot update it with the same number of variables.
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2468
Location: Netherlands, Amstelveen

PostPosted: Mon Nov 19, 2018 11:55 am    Post subject:
Reply with quote

Table EQQAPROF is not created by the user as far as i remember.

To look at the specifics of the table use ISPF Dialog Test (option 7)
Back to top
View user's profile Send private message
UmeySan

Active Member


Joined: 22 Aug 2006
Posts: 768
Location: Germany

PostPosted: Mon Nov 19, 2018 3:55 pm    Post subject:
Reply with quote

Morning gents !

As Peter Holland suspects, this is not my own table. EQQAPROF is a Profile table from OPC. Among many other things, the Job-Name variable is stored there.

My Intension was to pick up a jobname from a member, open in edit mode, via Rexx (Cursor Position - Point & shoot), open a new Screen and branch direclty into the OPC Panel where you could specify the Job you want to browse.
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2468
Location: Netherlands, Amstelveen

PostPosted: Mon Nov 19, 2018 4:28 pm    Post subject:
Reply with quote

Among many other things, the Job-Name variable is stored there.


How do you know? Subsystem name, yes, but jobname ? Which jobname?

My Intension was to pick up a jobname from a member, open in edit mode, via Rexx (Cursor Position - Point & shoot), open a new Screen and branch direclty into the OPC Panel where you could specify the Job you want to browse.


I don't understand this.
Back to top
View user's profile Send private message
Willy Jensen

Active User


Joined: 01 Sep 2015
Posts: 248
Location: Denmark

PostPosted: Mon Nov 19, 2018 7:03 pm    Post subject:
Reply with quote

I did not note the table name in the original entry, sorry. Now I see that it belongs to TWS (OPC). This probably means that the table is created and updated from a program using the CALL with namelist interface. The documentation (zos 2.1) states a limit of 254 extension variable names also for a namelist, though I seem to remember that the limit was greater at some point in time. TWS, being an IBM product, might have access to an alternate interface, or the documentation could be wrong. In any case I think that you are stuck with the limit of 254 names when using REXX. You could try to write a program to test the CALL namelist interface.
By the way, good to see a description of what you are attempting.
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 2128
Location: Silicon Valley

PostPosted: Mon Nov 19, 2018 11:15 pm    Post subject: Reply to: Modify the value of a extensionvariable in an ISPF-Table
Reply with quote

Quote:
EQQAPROF is a Profile table from OPC

Instead of treating it like a table (which it is), treat it like a profile (which it is).

That is, start your rexx program with NEWAPPL and then use VGET PROFILE to retrieve the variables and VPUT PROFILE to set your variables.
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 2128
Location: Silicon Valley

PostPosted: Mon Nov 19, 2018 11:21 pm    Post subject: Reply to: Modify the value of a extensionvariable in an ISPF-Table
Reply with quote

Quote:
being an IBM product, might have access to an alternate interface


I worked for IBM for a number of years (retired now). I worked fairly closely with the developers of ISPF. I do not think there is an interface that was published within IBM for developers working on other teams.
Back to top
View user's profile Send private message
UmeySan

Active Member


Joined: 22 Aug 2006
Posts: 768
Location: Germany

PostPosted: Tue Nov 20, 2018 5:23 pm    Post subject:
Reply with quote

@Peter: You could use 3.16 to view/edit the EQQAPROF table.
The variable where the jobname is stored is "oajob", used by EQQASELP Panel.

@Willy: Yes, seams that i'm stuck with the limit of 254 names.
I'm also thinking about a little Assembler Programm.

@Pedro: I retired four yeares ago. reactivated for a project since summer this year.

Thank's a lot
Back to top
View user's profile Send private message
UmeySan

Active Member


Joined: 22 Aug 2006
Posts: 768
Location: Germany

PostPosted: Tue Nov 20, 2018 5:35 pm    Post subject:
Reply with quote

@Peter

Just think of a normal Member in a PO Dataset.

If you open this member in edit mode, you coud see lines where names of OPC applications with their associated Jobs are listed.

... APPL A#Appl01 XA001 XA002 XA003 XA004
... APPL B#Appl02 XB001 XB002 XB003 XB004

You Position the Cursor at the Job you would browse an press a defined pf key. Point-and-shoot. The rexx started via pf key extracts the jobname at curser Position and branches to OPC displaying Panel EQQASELP.

Hope i could make myself clear.

Fijne dag !
Back to top
View user's profile Send private message
Nic Clouston

Global Moderator


Joined: 10 May 2007
Posts: 2123
Location: UK

PostPosted: Tue Nov 20, 2018 5:51 pm    Post subject: Reply to: Modify the value of a extensionvariable in an ISPF-Table
Reply with quote

If you are only using the table to point and shoot why is there a need to update it?
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2468
Location: Netherlands, Amstelveen

PostPosted: Tue Nov 20, 2018 6:05 pm    Post subject:
Reply with quote

Panel EQQASELP (Application List Criteria) as the name implies is used to select applications. Probably a jobname (generic?) can be used and probably that jobname is saved in the profile table.

It would be nice you show a screen print of that part of the profile table.

Somewhere in the back of my memory i seem to remember that some table data consisting of multiple records form in reality 1 long strong with variables.
Back to top
View user's profile Send private message
UmeySan

Active Member


Joined: 22 Aug 2006
Posts: 768
Location: Germany

PostPosted: Tue Nov 20, 2018 8:23 pm    Post subject:
Reply with quote

As Peter describes, the TWS (OPC) application is reading this table to get all the needed variables. So only storing a variable with VPUT into the Profile pool doesn't work.

@Peter: Sorry, i didn't realy understand the last sentence, what's the meaning.
Back to top
View user's profile Send private message
Willy Jensen

Active User


Joined: 01 Sep 2015
Posts: 248
Location: Denmark

PostPosted: Tue Nov 20, 2018 8:49 pm    Post subject:
Reply with quote

Interesting, using profile vput allows me to add 800 extension variables to a profile, so Pedro's suggestion should help you achieve your goal.
My sampe pgm shows 1435 extension variables in the zzzz profile:
Code:
 address ispexec                           
 "vget zapplid"                           
 if zapplid<>'ZZZZ' then do               
   "select cmd(%ZZ) newpool newappl(ZZZZ)"
   exit 0                                 
 end                                       
                                           
 do n=1 to 800                             
   zz=Value('P'n,copies(n' ',4))           
   "vput P"n "profile"                     
   if rc<>0 then do                       
     say n 'put rc' rc zerrlm             
     exit 8                               
   end                                     
 end                                       
 say 'profile updated with' n 'variables' 
 "tbtop zzzzprof"                         
 "tbskip zzzzprof savename(names)"         
 say '#names='words(names)                 
 say names                                 
 drop p755                                 
 "vget p755 profile"                       
 say 'p755='p755                           
 exit 0                                     

So ISPF internally has a way of handling more than 254 extension variables.
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 2128
Location: Silicon Valley

PostPosted: Tue Nov 20, 2018 10:09 pm    Post subject: Reply to: Modify the value of a extensionvariable in an ISPF-Table
Reply with quote

Quote:
the TWS (OPC) application is reading this table to get all the needed variables. So only storing a variable with VPUT into the Profile pool doesn't work.


I probably was not clear earlier - I thought it was common knowledge: The ISPF profile information is saved in an ISPF table. But apparently they use an undocumented interface so that you and I cannot manipulate it as you would a table. You must use the interfaces provided for the profile.

I do not believe OPC 'reads this table' as you imply. It probably 'reads the table' through the use of VPUT and VGET services.
Back to top
View user's profile Send private message
PeterHolland

Global Moderator


Joined: 27 Oct 2009
Posts: 2468
Location: Netherlands, Amstelveen

PostPosted: Wed Nov 21, 2018 8:41 am    Post subject:
Reply with quote

@UmeySan

The meaning of the last sentence :

concatenating the table records to 1 long string
Back to top
View user's profile Send private message
UmeySan

Active Member


Joined: 22 Aug 2006
Posts: 768
Location: Germany

PostPosted: Wed Nov 21, 2018 3:44 pm    Post subject:
Reply with quote

Thank's a lot gent's, i appreciate your help.

Perhaps my Alzheimer's symptoms are getting worse, so i can't follow up your hints in every step. Or i schall reduce the bottels of red wine at dinner to a limit of one.

And as beeing a programmer, normaly using Assembler, Cobol, db2 cics, ims, i'm no Guru of Rexx language.

@Willy: I can't really see where you're updating a specific table without using TBPUT or TBMOD or TBADD. And what does this &ZZ proc does?

@Pedro:
>> It probably 'reads the table' through the use of VPUT and VGET services

Would you be so Kind to explain that in Detail.

I would be delighted to here form you, so you could enligthen my lack of knowledge here.
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
Goto page 1, 2  Next
Page 1 of 2

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Programmatically determine HLQ ISPF i... Mike.Fulton TSO/ISPF 4 Sat Dec 01, 2018 8:05 am
No new posts What is a table space in db2 for z/os? martin schlatter DB2 13 Sat Nov 24, 2018 11:19 pm
No new posts ISPF 3.4 edit of a ps file, disp use... Carrie Da Silva TSO/ISPF 3 Fri Sep 21, 2018 3:01 am
No new posts Facing Issue in Table Reorg satish.ms10 DB2 1 Tue Aug 07, 2018 2:44 am
No new posts KSDS file fields update by passing va... Anil Kumar Prajapati TSO/ISPF 5 Wed Jul 11, 2018 5:59 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us