Copyright 1991-2016 by Kevin G. Barkes All rights reserved. This article may be duplicated or redistributed provided no alterations of any kind are made to this file. This edition of DCL Dialogue is sponsored by Networking Dynamics, developers and marketers of productivity software for OpenVMS systems. Contact our website www.networkingdynamics.com to download free demos of our software and see how you will save time, money and raise productivity! Be sure to mention DCL Dialogue! DCL DIALOGUE Originally published January 1991 Things They Never Told You About DCL By Kevin G. Barkes Don't have a cow, man. I'm not going to reveal any deep, dark secrets about our favorite command language. Then why the hook in the title, you may ask? Let's be frank. If you knew this month's topic covered routine DCL commands used on a daily basis, you'd probably skip right over to Phil Bourne's Unix column. And that's the last thing I need. Anyway, now that I have you, listen up. This is for your own good. How did you learn DCL? If you're like most VMS users, you were plopped down in front of a terminal, shown how to log in and told to type HELP HELP or something along those lines. If your "teacher" was an especially compassionate fellow, he may even have told you how to invoke and exit EDT. These impromptu instructors constitute the "They" in the title. "They" never told you about DCL at all... "they" just threw you in, head first. Okay, now how do you stay current with DCL? Do you coerce the system manager to make you a copy of the release notes? Do you put a write sys$ouput f$getsyi("version") in your login file and eagerly wait for the number to increment? (I mention this only because the odometer on my car recently turned to 40000 miles, and I was so enthralled by the experience I nearly rear-ended a bakery truck.) As soon as the number jumps, you do a HELP Vnn_NEWFEATURES, right? Sure. The UPS guy just dumped four boxes worth of VMS 5.4 in my garage. I'm wary of any release of VMS that weighs more than my VAXstation, so it may be a while before I put it up. (This is an extension of Miss Piggy's "Never eat anything you can't lift" rule of survival.) Besides, I just finished updating my doc set to 5.3 last weekend. 5.4 will have to wait until I have the time. Sound familiar? The truth of the matter is we all have gaps in our DCL vocabulary. If you're in an environment where you're constantly putting out fires and trying to keep your users and management satisfied simultaneously, you know what I mean. You go through the release notes to see what will break and what will go away. You glance at the DCL commands to see if you've got to rewrite any procedures. If you're a mere user, you're really on your own. Undoubtedly, some things will fall through the cracks. I was recently embarassed at a customer site when someone pointed out to me the queue-name parameter in the DELETE/ENTRY command is optional, and has been for some time. When I looked it up, I also discovered the existence of the special $ENTRY symbol. How the heck did I miss that one? Sheesh. Some DCL whiz, eh? Still, there are some really basic features of DCL and VMS which some users have never learned. Traveling from site to site, I've compiled a list of common "forgotten" DCL features. Don't be too condescending; you may be surprised at your own blind spots. When I present this list at my training sessions, everyone laughs heartily; after all, many of these items are absurdly obvious. But invariably a few people approach me privately afterward and confess they were caught by one or two of these nuggets: -- Control-t. This constantly surprises me, but a lot of people are unaware of this stat display. It occurs mostly at sites where users remain primarily within a custom application and the manager has disabled control-t to keep the screen displays from being messed up. --The DEALLOCATE command has an /ALL qualifier which permits you to deallocate all devices which your process has allocated, without specifying device names. --File specification flexibility. You can get prior versions of files by specifying a version offset instead of an explicit version number. For example, EDIT FILE.DAT;-1 will edit the file one version number lower than the highest available version number. The version number ;0 specifies the highest version number. So, if you wanted to delete the latest version of a file, keeping prior versions intact, and you didn't know the actual version number, you could enter DELETE FILE.DAT;0. -- Command line continuation. A user once complained to me he couldn't enter a line on a command file he was writing because TPU kept breaking it. He'd never heard about the hyphen continuation character. -- Command prompting. Many are unaware VMS will ask for required parameters. -- Control-b recalls previously entered command lines. Especially helpful on hardcopy terminals. And command recall is also available from within a number of VMS utility programs. --For that matter, just about all the other control key combinations: control-a (switches between insert and overstrike mode); control-d (move cursor to the left); control-f (move cursor to the right); control-e (move cursor to end of line); control-h (move cursor to beginning of line); control-r (repeats command line); control-u (cancels current input line); control-x (cancels current line and all data in typeahead buffer), among others. --/CONFIRM options. Commands like DELETE, which have a /CONFIRM option, generally prompt the user prior to each operation, but the only prompt you get is the default [N]. You can enter Y, T or 1 for positive responses, N, F and 0 for negative responses; typing the word QUIT or entering control-z aborts the remainder of the command; and if you enter ALL, the command stops prompting and processes the rest of the command. --Key definition. The ability to assign commands to specific keys comes as a shock to some users. --Instead of creating a new directory, copying files into it and deleting the original files, you can just RENAME the .DIR file (provided the directories are on the same disk, of course). If you have some nuggets you'd like to share, drop me a line at the address below. Now it's down to the garage to tackle 5.4... ************************************************* Kevin G. Barkes is an independent consultant and publisher of the KGB Report newsletter. He lurks on comp.os.vms, maintains the www.kgbreport.com website, and can be reached at kgbarkes@gmail.com.