- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - OpenVMS
- >
- Re: Logical name wildcard search
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-28-2005 08:52 PM
тАО04-28-2005 08:52 PM
In a program I need to retrive logical names with wildcards like the DCL command:
$ sho log *AXES* and then do some procesing on the resulting list.
Have somebody any ideas/experience how to do that?
Thanks,
Peter
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-28-2005 09:00 PM
тАО04-28-2005 09:00 PM
Re: Logical name wildcard search
We do have the same problem(s). We did solve this by doing this the &^%$%^^*&% Unix methode.
$ show log *axes*/output=
$ open/read/error=error file_in
$ loop1:
$ read/end_of_file=end file_in line
.
.
$ goto loop1
$ end:
$ close file_in
$ error:
$ if f$search("
$ exit
Succes on you,
AvR
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-28-2005 09:23 PM
тАО04-28-2005 09:23 PM
Re: Logical name wildcard search
wouldn't it be nice to have F$TRNLNM behave like F$SEARCH, F$PID, F$DEVICE, or F$GETQUI?
I know, different concepts internally, but the final effect is that they allow to scan through a list of objects that satisfy some selection criterion.
Deserves a place on the wish-list, in my opinion.
Guy, would that be an easy or a hard one?
Proost.
Have one on me.
jpe
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-28-2005 10:15 PM
тАО04-28-2005 10:15 PM
Re: Logical name wildcard search
My offhand recollection is that SHOW LOGICALS uses a different set of scanning code than the normal search and translate functions.
The easiest way I can think of is:
- do the appropriate SHOW/LOGICAL command, and use the /OUTPUT=filename option
- process the resulting file, with due regard for:
o table names (beginning with a "(")
o blank lines
o search lists -- these will have a value on the right hand side of the "=", but no left hand side
An alternative to this is to use only the left hand side of the SHOW LOGICAL result and use F$TRNLMN to get the actual value of the name, and its associated attributes,. This approach is far less work in the form of ad-hoc parsing.
I hope that the above is helpful.
- Bob Gezelter, http://www.rlgsc.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-28-2005 10:34 PM
тАО04-28-2005 10:34 PM
Re: Logical name wildcard search
You can download LNMLOOKUP for VAX and Alpha by Ferry Bolh├Г┬бr-Nordenkampf at http://vms.process.com/scripts/fileserv/fileserv.com?LNMLOOKUP . The description says "System service to look up logical names (wildcards too!)"
HTH,
Marti
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-29-2005 01:38 AM
тАО04-29-2005 01:38 AM
Re: Logical name wildcard search
Having said that, it's not a simple case of adding wildcard support to F$TRNLNM; as with many lexical functions, F$TRNLNM is simply a wrapper around SYS$TRNLNM, so the modifications would need to be done to the system service. We would not entertain the possibility of allowing divergent behaviour between the DCL lexical and the system service by enhancing only the DCL lexical function.
The logical name subsystem is rather twisty and complicated; support for wildcarding would not be a quick midnight hack.
That said, if enough customers complain directly to product management, something may get done (stating support here or in other public fora does not help, as upper management does not tend to visit here)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-29-2005 02:09 AM
тАО04-29-2005 02:09 AM
SolutionShow log is really your only standard VMS tool today.
How often do you need to do this?
Once per login / batch job?
Once per minute?
It may well be reasonable to spawn SHOW LOG, or process it's output.
What kind of processing? I find the perl 'backtick' operator quit handy for a quick loop over command output. For example:
$ perl -e "foreach (`show log`){chop; $t=$_ if (/^\(/); print ""$t $1 $2\n"" if (/""(.*LOGIN.*)"" = ""(.*)\""/)}"
It looks a little ugly because you need to double up quotes in a quoted string.
The first regexp: (/^\(/)
^/\) = string that starts with (escaped) paren
The second: (/""(.*LOGIN.*)"" = ""(.*)""/)}"
"" = Find quote
( = remember in $1
.* = piece of string
LOGIN
.* = piece of string
) = stop remembering
"" = "" = quote space equal-sign space quote
( = remember in $2
.* = piece of string = translation
) = stop remembering
alternatively you can SPLIT the line by quotes selecting element 1 and 3 (0 based).
The example pick up the tablename in $tb, the logical name in $lo and the translation in variable $tr. It simply prints that lot.
$ perl -e "foreach (`show log`){$tb=$_ if (/^\(/); ($lo,$tr)=(split(/""/))[1,3]; print ""$lo $tr $tb"" if ($tr && $lo =~ /LOGIN/)}"
cheers,
Hein.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-29-2005 03:06 AM
тАО04-29-2005 03:06 AM
Re: Logical name wildcard search
thanks for the explanation
Hein,
no offence meant, but I think I will stick to DCL :-)
I want to be able to use my pet tools procedures on every system I happen to run in to.
Proost.
Have one on me.
jpe
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО10-31-2006 05:23 PM
тАО10-31-2006 05:23 PM
Re: Logical name wildcard search
Peter