DECS Administrator

The DECS Administrator database stores all the information necessary to connect an external data source with a Notes database. It's managed from the Notes client or from the Notes Administrator client, and it is stored on the server running the DECS task. On opening the database, you're presented with a View pane and a Navigator pane, as displayed in Figure 22.1. The Navigator pane is all you need to build and view the connection and activity information for all the applications that use DECS.

Figure 22.1. The DECS Administrator database defines all the data connections and activities that the DECS task can run.


The DECS Administrator database consists of two major types of information: connections and activities. There are views for each of these types, as indicated in Figure 22.1. Connections define how connections are made between the Notes database and the external data source. Activities describe which fields should be exchanged and the trigger that causes the exchange to happen. The Administrator database is responsible for providing all the information that the DECS server task needs to execute an activity and provide the appropriate responses.

Because it would be impossible to cover all the possibilities of DECS in this chapter, we'll instead guide you through the creation of a Notes database to access data stored in a dBASE format table and you'll access the data through an ODBC connection. In doing so, we'll cover the basics and a few helpful hints besides. The actual steps that we cover in this chapter are

  • Creating the application
  • Defining the external data source to ODBC
  • Creating a connection to the data source in the DECS Administrator database
  • Creating an activity for the connection in the DECS Administrator database
  • Accessing the application

Creating the Application

You'll work with a very simple application that provides you a way to access customer information stored externally in a Notes database that tracks customer calls. We are purposely not making this a full application; it's only enough to show how this works, and to give you ideas for implementing your own applications.

First, we've created a Domino database that contains a form called CustKey with the customer information that both Domino and the external database have in common. The fields with an asterisk ( * ) are the fields you retrieve from the external database. The Cname field is the key field used to compare the documents with the table. The dBASE field names are the same as the Notes field names . This is always a good idea to provide consistency between applications and standardized naming conventions throughout an organization. A second form contains all the fields in Table 22.1. A third form contains the Cname field and a Form field.

Table 22.1. Fields Created for Domino and dBASE Files; Fields Without an Asterisk Appear Only in the Domino Database

Field Name Field Type Field Description
Cname Text * Customer name
Cadd1 Text * Address line 1
Cadd2 Text * Address line 2
Ccity Text * City
Cstate Text * State
Czip Text * ZIP code
CallDate Date Date the call was received
CallSubject Text Short description of call
CallDetail Rich Text Full description of call
Author Text Person entering the information

The CustKey form defines the customer information. This is the form you'll use to populate the Domino database with the initial data from the external database. You'll use the Customer Call form to log customer calls and the third form, CustLog , to select the customer for a new customer call.

Defining the External Data Source to ODBC

Prior to setting up a connection to a data source, you must have a way to access the data. In the case of an ODBC connection, ODBC must be set up to provide a link to the data source. The ODBC data source is set up from the ODBC administrator program in Windows. You should create a system DSN, not a user DSN. This is necessary for clients to be able to make the connection. If the user DSN is used, the only computer that can see the connection is the server because a user DSN is available only to the local machine. The system DSN that you've created for this connection is displayed in Figure 22.2. Lotus also recommends using Intersolv's ODBC drivers unless a driver is provided by the vendor of the data source.

Figure 22.2. An ODBC connection should be set up as a system DSN.


Creating the Connection

Connections define the external data that's to be captured or manipulated. Based on the data source chosen , the appropriate form opens and the fields that are required for an appropriate connection are displayed. Common to all connections are the data source, the table or view to access, and the username and password that should be used for the connection. In the case of your connection, Figure 22.3 displays the document that's created to support the ODBC connection that you created.

Figure 22.3. The DECS Connection document for the ODBC connection defines which external data source and Notes database are connected.


The first field is the data source that defines the name for the ODBC connection that was created in ODBC administration. If the application you're accessing requires a username and password, they're entered in the next two fields. They must be entered here because you won't have a way for the user of the Notes application to be able to enter them. There's a button to enable encryption on the password field by using an encryption key. Setting up an encryption key isn't covered in this chapter.

Next, you must select the type of data ”table, view, or procedure ”from the external data source. You're using a table.

The section for table selection is next. If you want to use this connection to access multiple tables, nothing needs to be entered in this section; you specify the table you want to use when creating the Activity. However, if this connection is available for only one table, you can specify that table here. Leave this section blank so that we can demonstrate how to select the table within the activity itself. When you select the table you want to use, the column names appear in the column fields. You can see how this works in Figure 22.4, which shows the Custmain table.

Figure 22.4. The columns available from the Custmain table are automatically added to the connection document when the table is chosen.


Part I. Introduction to Release 6

Whats New in Release 6?

The Release 6 Object Store

The Integrated Development Environment

Part II. Foundations of Application Design

Forms Design

Advanced Form Design

Designing Views

Using Shared Resources in Domino Applications

Using the Page Designer

Creating Outlines

Adding Framesets to Domino Applications

Automating Your Application with Agents

Part III. Programming Domino Applications

Using the Formula Language

Real-World Examples Using the Formula Language

Writing LotusScript for Domino Applications

Real-World LotusScript Examples

Writing JavaScript for Domino Applications

Real-World JavaScript Examples

Writing Java for Domino Applications

Real-World Java Examples

Enhancing Domino Applications for the Web

Part IV. Advanced Design Topics

Accessing Data with XML

Accessing Data with DECS and DCRs

Security and Domino Applications

Creating Workflow Applications

Analyzing Domino Applications

Part V. Appendices

Appendix A. HTML Reference

Appendix B. Domino URL Reference

Lotus Notes and Domino 6 Development
Lotus Notes and Domino 6 Development (2nd Edition)
ISBN: 0672325020
EAN: 2147483647
Year: 2005
Pages: 288 © 2008-2020.
If you may any questions please contact us: