Chapter Contents |
Previous |
Next |
SEARCHPATH |
Category: | Catalog |
Syntax | |
Details | |
Example | |
See Also |
Syntax |
path-name=SEARCHPATH(entry-name<,description>); |
Type: Character
Type: Character
Y
to return the description and the date.
Type: Character
Details |
SEARCHPATH returns the full four-level SAS library member name for a catalog entry if the entry is found in one of the catalogs that are in the current search path. It also returns the description that is stored with the entry in description.
If an entry that has the specified name appears in more than one catalog in the search path, then only the path to the first entry found is returned. If no search path is defined, the search is limited to the current catalog (the catalog in which the executing entry is stored).
To define the search path for your application, use SEARCH.
Note: To get the pathname and description of
an entry, you can use the method interface of the Catalog entry class.
Example |
Load a stored list from a catalog entry if the entry is found in the current search path:
init: DCL num desclen rc=rc; rc=search('sashelp.afclass'); rc=search('sashelp.aftools'); rc=search<'sashelp.assist'); path=searchpath('listed.frame','y'); pathlen=length(path); name=scan(path,1,"); namelen=length(name) + 1; desclen = pathlen - (namelen) - 10; desc = substr(path, namelen + 1, desclen); date = substr(path, pathlen - 9, 10); put name=; put desc=; put date=; return;
This program produces the following output:
name=sashelp.aftools.LISTED.FRAME desc= Generic list editor date=10/09/1996
See Also |
Chapter Contents |
Previous |
Next |
Top of Page |
Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.