APPLICATION DESIGN


Creating a query view
1. In IBMR LotusR Domino(TM) Designer, open the database for which you want to create a query view.

2. Select Create - Design - View.

3. In the Create View dialog box, complete the following:
FieldAction
View nameEnter a name for this view
View typeChoose one of the following:
  • Shared
  • Private
Select a location for the new viewIf you want the view to appear at the top level in the list of views, do not select anything in this field. Otherwise, click the name of the view under which you want the new view to appear.
Copy style from viewClick this option and then:
  • Click Blank if you do not want to copy another view's style.
  • Click the view whose style you want to copy.
Selection conditionsEnable "By SQL Query." Note that when this option is selected, the View types are limited to the four options described above.
4. Click Query Window. Type your SQL query in the Edit SQL Query Formula dialog box. Make sure the query is contained in quotes. For example:


5. (Optional) Click Functions to obtain a list of functions to copy and paste into your query.

6. When you are finished, click Done.

7. Click Save and Customize. This opens the Designer View workpane. From here, you may continue to customize your view.

Note You can specify the maximum number of rows returned by an SQL query in View Properties. However, there is also a row limit set by the administrator at the server level, so you should know this limit prior to setting up any query views. As a designer, you can still set a row limit (in the View Properties) less than that set at the server. The default limit is 500 rows.

Note DB2 column names that have disallowed Notes field name characteristics (for example, columns starting with a digit) are reported when the query is run. You will get the following Designer error dialog:


and the console will report something like:
Additionally, the #UNID and #MODIFIED fields are not created. However, you will not get an invalid field name warning in these cases.

If you want to use the values returned by any of these invalid columns, use the AS syntax in the Query View's SQL formula to rename them.

See Also