OPENDB
Open (or re-open) a database.
The database nametag must have been defined in DATABASES first (i.e. Database /Name=DBNAME).

Format
 Opendb expression as DBNAME [/Qualifiers ... ]

Qualifiers
 /Default_filename=def_filenameUse 'def_filename' as the default file specification.
/Fail=LABELLabel to which to branch if the statement fails.
If LABEL is %EXIT, exit the routine or loop.
If in a loop, and LABEL is %CONTINUE, continue the loop. If not in a loop, and LABEL is %CONTINUE, an error message displays.
 /Succeed=LABELLabel to which to branch if the statement succeeds.
If LABEL is %EXIT, exit the routine or loop. If in a loop, and LABEL is %CONTINUE, continue the loop. If not in a loop, and LABEL is %CONTINUE, an error message displays.
 /NofailDo not signal an error. Instead, set the
internal variable %FAIL.
 /Options=exprPlease refer to the DATABASE section for opening options.
 /ViewThe specified database is a VIEW ofone or more databases. When the view database is opened, the databases that were used to create the view are re-associated with the view. Therefore, when a record is retrieved from the view database, the records from the original databases are also made current.

Example
 START:
 Menu GET_DB_NAME
 Opendb %ITEM as INPUT_FILE /Nofail
 If %FAIL then
 Error "ERROR OPENING"; %ITEM
 Goto START
 End_if