FileOpenDatabase @Command (Formula Language)

Opens the specified database to the specified view, highlighting the first document whose value in the sort column matches the key. You specify a database using its server and file name.


@Command( [FileOpenDatabase]; server : database ; viewName ; key ; newinstance ; temporary )


@Command( [FileOpenDatabase]; server : database ; navigator ; solo ; newinstance ; temporary )



Text. The name of the server where the database resides.


Text. Optional. The path and file name (in the appropriate format for the operating system) of the database you want to open. If you omit the name of the database, and one is already open, Notes/Domino displays that database's view in the current window. If no database is open but one is selected on the workspace, the selected database is opened. If no databases are open or selected, Notes/Domino displays the Open Database dialog box, so the user can select a database.


Text. Optional. The name of the view you want to open in the database. If you omit the name of the view, the database opens to its default view; or, if the user has opened the database before, to the last view used by that user.


Text. Optional. Indicates which document you want Notes® to scroll to when it opens viewName. The key is a value that appears in the first sorted column of viewName. If you omit the key, no document is selected.


Number. Optional. Specify "1" if you want the view to open in a new window, even if the database is already open in that view. If you omit this parameter, the new window is opened only if the database is opened in a new view.


Number. Optional. Specify "1" if you only want the database opened on a temporary basis for browsing, without adding the database to the user's workspace. If you omit this parameter, the database is added to the user's workspace.


Text. Optional. The name of a navigator defined for the database. On opening the database, Notes® displays this navigator.


Number. Optional. A value of "1" instructs Notes/Domino to open the navigator named by navigator in its own window.


If you omit some of the parameters like viewName and key, but still include the parameters that come after it, substitute "" for each parameter that you're skipping, as in:

@Command([FileOpenDatabase]; "Sales":"PROBLEMS.NSF"; ""; ""; ""; "1" )

You can use this command in Web applications, but the server argument must be specified as a null string (""). When using the view argument, you must follow the command with @Command [OpenDocument].


  1. Notes/Domino opens the PROBLEMS.NSF database, which is stored on the Development server. If the database is already open, Notes/Domino brings that window to the foreground. If the database is not open, Notes/Domino opens it in a new window. Since no view was specified, the database opens either to the default view, or if the user has opened the database before, to the view last used by the user. If the database is not on the user's workspace, it will be added automatically.
  2. Notes/Domino opens the PROBLEMS.NSF database on the Development server. Additionally, Notes/Domino opens a new window, displays the Open Problem Reports view, and highlights the first document containing "Printer problems" in the key field. Since the temporary parameter is used, the database icon is not added to the user's workspace.
    @Command([FileOpenDatabase]; "Development":"PROBLEMS.NSF"; "Open Problem Reports"; "Printer problems"; "1"; "1" )
  3. This code, when added to the Open My Feedback hotspot button returns the All\By Employee view of the UserNotes.nsf database located in the feedback subdirectory of the Customers/ME/ACME server. The view, which contains documents grouped by category, where the categories are employee names appears with the category named after the current user highlighted and displayed in the first row of the view.
    @Command([FileOpenDatabase]; "Customer/ME/ACME" : "feedback\\UserNotes.nsf" ; "All\\By Employee" ; @Name([CN];@UserName(0)) ; "1" ; "1")
  4. This formula, when added to the "Int'l" hotspot button on a document whose design is based on the USUser form, opens the Int'l view. If the Int'l view's form formula is "IntlUser," the user can select the same document from this view and it will display using the IntlUser form. If you do not close the current USUser-based document first, it will redisplay based on the USUser form when selected from the Int'l view.