is there anywhere out someone, who has an example how to use ISPF option
3.16 in a REXX program instead of using in online. This would be very
helpful to build an application which should export a given table regulary.
Thanks in advance for any help.
--
Freundliche Gruesse / Kind regards
Dipl. Math. Juergen Kehr
IT Schulung & Beratung, IT Education + Consulting
Rengershaeuser Str. 28
34132 Kassel
Germany
Tel. +49-561-9528788
Fax +49-561-9528789
Mobil +49-172-5129389
ICQ 292-318-696 (JKehr)
mailto:KehrJ...@t-online.de
mailto:KehrJ...@JKehr.de
Well, there doesn't seem to be a callable service available. But
it looks like 3.16 lets you import table data, not export.
In any case, you should be able to use ISPF table services to
accomplish the function you need on your own, from a REXX-driven
dialog.
<ad>
Our five day course, "Developing Dialog Manager Applications in z/OS"
should help with this. It covers virtually all the callable services
and uses both CLIST and REXX in all examples and labs (you choose the
language to use).
More details at:
http://www.trainersfriend.com/TSO_Clist_REXX_Dialog_Mgr/a810descrpt.htm
(Follow the link "course outline" for even more details).
</ad>
--
Kind regards,
-Steve Comstock
The Trainer's Friend, Inc.
303-393-8716
http://www.trainersfriend.com
* To get a good Return on your Investment, first make an investment!
+ Training your people is an excellent investment
> you should be able to use ISPF table services
I agree. If you want to make a copy of a table that is currently open,
you can use the TBSAVE service. You can direct it to another dataset or
save it under a different name.
Pedro Vera
IMS Tools
http://www.ibm.com/software/data/db2imstools/products/ims-tools.html
Rob
In a message dated 6/23/2010 7:40:03 A.M. US Mountain Standard Time,
kehrj...@T-ONLINE.DE writes:
Hello,
is there anywhere out someone, who has an example how to use ISPF option
3.16 in a REXX program instead of using in online. This would be very
helpful to build an application which should export a given table regulary.
Thanks in advance for any help.
--
Am 23.06.2010 17:33, schrieb Steve Comstock:
>
> Well, there doesn't seem to be a callable service available. But
> it looks like 3.16 lets you import table data, not export.
thanks for your fast answer. Function 3.16 in fact does allow table
EXPORT ! Try the EXPORT command, otherwise the import wouldn't make much
sense anyway.
BTW: If you hold ISPF training classes, you should know that EXPORT is
although available. ;-)
>
> In any case, you should be able to use ISPF table services to
> accomplish the function you need on your own, from a REXX-driven
> dialog.
>
Of course I know that I can write a routine using ISPF table services to
export or import a table to a dataset, but using function 3.6. allows to
have a standard import/export format independant of the actual table
structure and I only want to reinvent the wheel.
Wow! Guess what: my reply was based at just looking at the
ISPF 3.16 screen, since it was available at the moment.
But based on your comment I went and looked at my ISPF course
and it has a whole chapter (20 pages)on 3.16 including importing
and exporting tables and even a lab on using. It's been a year
since I wrote that chapter so I even forgot I had it in there.
Good on me!
>
>>
>> In any case, you should be able to use ISPF table services to
>> accomplish the function you need on your own, from a REXX-driven
>> dialog.
>>
>
> Of course I know that I can write a routine using ISPF table services to
> export or import a table to a dataset, but using function 3.6. allows to
> have a standard import/export format independant of the actual table
> structure and I only want to reinvent the wheel.
It seems to be the case that the ISPF group often puts out a new
function as an ISPF option and then in one or two releases puts
out an ISPF service to allow non-IBM developers access to the
service. Maybe in z/OS 1.12?
Good luck.
Certainly as Q+D code that you use yourself it's pretty easy to fix the code if an error occurs.
But for myself I try to use REXX variable names that contain a non-ISPF valid character (!)
when it's possible that a random ISPF variable could enter the mix. So code below would
become:
...
address ISPEXEC "TBQUERY" table "KEYS(KEYS) NAMES(NAMES) ROWNUM(ROWS)"
parse var keys '(' !keys ')'
parse var names '(' !names ')'
!table = table
!rows = rows
say 'TABLE :' !table
say 'KEYS :' !keys
say 'NAMES :' !names
say 'ROWS :' !rows
!rowlen = 0
do !i=1 to !rows
csv.!i = ''
address ISPEXEC "TBSKIP" !table "SAVENAME(EXTRAS) NOREAD"
!extras = extras
address ISPEXEC "TBSKIP" !table "NUMBER(0)"
do !k=1 to words(!keys)
csv.!i = csv.!i||',"'||value(word(!keys,!k))||'"'
end
...
(I've also added code to get any 'extra' columns in a row, how you would handle that in a
CSV unload is left to your imagination.)
James Campbell
> Date: Wed, 23 Jun 2010 13:24:32 EDT
> From: Rob Zenuk <Robz...@AOL.COM>
....
> Just a word of warning to anyone writing code like Rob's - consider what would happen if one
> of the fields in the table was named TABLE, KEYS, K, NAMES, N, ROWLEN, or I.
>
> Certainly as Q+D code that you use yourself it's pretty easy to fix the code if an error occurs.
> But for myself I try to use REXX variable names that contain a non-ISPF valid character (!)
> when it's possible that a random ISPF variable could enter the mix. So code below would
> become:
>
ISPF really ought to provide a "stem" capability as
better-designed Rexx APIs do.
-- gil