DB_ITEM
Name
DB_ITEM
Purpose
Returns the item numbers and other info. for an item name.
Explanation
Procedure to return the item numbers and other information
of a specified item name
Calling Sequence
db_item, items, itnum, ivalnum, idltype, sbyte, numvals, nbytes
Inputs
items - item name or number
form 1 scalar string giving item(s) as list of names
separated by commas
form 2 string array giving list of item names
form 3 string of form '$filename' giving name
of text file containing items (one item per
line)
form 4 integer scalar giving single item number or
integer vector list of item numbers
form 5 Null string specifying interactive selection
Upon return items will contain selected items
in form 1
form 6 '*' select all items
Outputs
itnum - item number
ivalnum - value(s) number from multiple valued item
idltype - data type(s) (1=string,2=byte,4=i*4,...)
sbyte - starting byte(s) in entry
numvals - number of data values for item(s)
It is the full length of a vector item unless
a subscript was supplied
nbytes - number of bytes for each value
All outputs are vectors even if a single item is requested
Optional Input Keywords
ERRMSG = If defined and passed, then any error messages will
be returned to the user in this parameter rather than depending
on the MESSAGE routine in IDL. If no errors are encountered,
then a null string is returned. In order to use this feature,
ERRMSG must be defined first, e.g.
ERRMSG = ''
DB_ITEM, ERRMSG=ERRMSG, ...
IF ERRMSG NE '' THEN ...
Procedure Calls
DB_INFO, GETTOK, SELECT_W
Revision History
Written: D. Lindler, GSFC/HRS, October 1987
Version 2, William Thompson, GSFC, 17-Mar-1997
Added keyword ERRMSG
Use STRSPLIT instead of GETTOK to parse form 1, W. Landsman July 2002
Assume since V5.4 use FILE_EXPAND_PATH() instead of SPEC_DIR()
W. Landsman April 2006
Support new DB format allowing entry lengths > 32767 bytes WL Oct 2010
Ignore blank lines in .items file WL February 2011