>If you use Private DataSession, the OPEN DATABASE in the main program is useless. You don't need to open the database manually, because opening a table open the corresponding database automatically. I rarely use OPEN DATABASE in programs. You would use SET DATABASE TO before calling a stored procedure.
Just to add one comment, if you need to check if the DB is open for any reason, there is a function DBUSED() for this.
The Anonymous Bureaucrat,
and frankly, quite content not to be
a member of either major US political party.