You are here: Home > Knowledge Refreshers

KR-225* Personal data sets


Command REFOPEND: opens the 'Personal Data Set Lists' screen which lists all the personal lists you have created (It will list REFLIST alone if you have not created any personal lists).

  • To create a new list, give the command NEW, in this screen.
  • Now, you can create a personalised list of all datasets that you frequently require.
  • Once you have mentioned all the datasets you require in the list give command S or A in the 'Action' field, to save the list with a name and description.
  • Once you have created your personal list you can summon the dataset list from any screen with the command DSLIST list-name (if you had saved your list as 'MYLIST', the command would be DSLIST MYLIST).
  • If you want to make changes to your personal list, you can do so anytime in the 'Personal Data Set Lists' screen (using command REFOPEND). You can also create any number of personal lists.
  • The command DSLIST can be used from any screen to list all the lists you have created. You can also use the DSLIST command to directly list datasets from any screen without having to use the 3.4 option. For eg. The command DSLIST 'MYID.TEST' from any screen will list all datasets whose high level qualifiers are MYID.TEST.*

Also try out the following commands:


REFACTD: Open or retrieve from the current personal data set list. (For eg: REFACTD MYLIST 3 retrieves the third data set from the personal data set list named MYLIST and places it in the Data Set Name field, in option 3.4.) REFACTL Open or retrieve from the current personal library list.


REFLISTD: Show the REFLIST personal data set list.

REFLISTL: Show the REFLIST personal library list.

REFADDD: Add the most recently referenced data set to a personal list. (For eg: REFADDD MYLIST)

REFADDL: Add the most recently referenced library to a personal list.



KR-226*: Extra Personal Client (EPC) macros


When ever we need to automate any routine and/or repetitive tasks, the easiest way is to write a EPC Macro. So here is a cheat-sheet with some very useful commands.




Types the desired keys at the current cursor location.



Sess.Screen.SendKeys (“Kr 226<Enter>”)

Special keys to be enclosed between '<>'


2. WaitHostQuiet


Waits for the specified amount of time (in milliseconds) to elapse.


Sess.Screen.WaitHostQuiet (500)

(Try for the least time that works fine with your session, usually you can use very low values)


3. MoveTo


To move the cursor to a specific location on the screen.


Sess.Screen.MoveTo 11, 76

(Moves cursor to Row: 11, Column: 76)


4. WaitForString


Stops macro playback until the STRING required is found. Row and Col are optional. If not given, the program will look for the string across the entire screen. After 30 seconds or so the macro will start back regardless.


Sess.Screen.WaitForString "CICS", 1, 73

Sess.Screen.WaitForString "KR"


5. GetString


To get data from the screen. This function will store the data in a variable for later use.


String1 = Sess.Screen.GetString (10,7,6)

(Get 6 chars from row 10, column 7; and store the data in the variable 'String1)


6. PutString


To put a STRING to a specific location on the screen.


Sess.Screen.PutString “Kr 226”, 2,11

Sess.Screen.PutString STRING1, 2,11

(Where STRING1 is the variable which has the string value to be put)


7. MsgBox


To display information to the user in a Messagebox.


Msgbox “Macro Finished”


8. InputBox


To query the user and ask for input, by displaying an Inputbox.


UserResponse = InputBox (“Was KR 226 useful?”)


While this is by no means a comprehensive list of commands, it can get you started with EPC Macro. For more commands/help look up in EPC help files or on the net :) or try recording what you want to do and look up the macro code created by EPC.



KR 227*: How big is a dataset?


When transferring datasets from mainframes to Unix or Windows one might encounter a situation where you need to calculate the size occupied by a dataset in terms of bytes. How big is it?


So how do we find the number of bytes occupied by a dataset?

  • Do a “I” or “S” in 3.4 dataset listing option against the dataset name you want to check to get the number of cylinders used (or go into the ‘information’ option). Or you can do a F11 on the dataset listing screen to get the number of tracks allocated and used by this dataset.
  • Note down what is the device (device type) on which it is stored – most likely it will be a 3390 DASD.
  • In the website: you can find the number of bytes stored on a 3390 DASD track here; so multiply the number of bytes into the number of tracks occupied (ensure you use the “used tracks” and not allocated tracks for calculation – for example you might have “percentage used” as 90 while the tracks is given as 200 – this means only 90% of 200 or 180 tracks are actually used).
  • To cross check you can download a smaller file to your pc and verify if your calculation is correct.

Try calculating the size for a few of your datasets and you’ll be surprised by how big they really are! You’ll also appreciate what they mean when they say mainframes handles large volumes of data :-)