APPLICATION DESIGN


Formulas for response columns
Responses-only columns need formulas that generate text summarizing the response documents.

Tip You should create only one response column in a view.

Including information about the author

A discussion database could show the response document author, date, and subject line with this response column formula:

From + " added this comment: " + Subject + " (" + @Text(@Created) + ")"

to show a response this way:


Tracking document status

In an employee information database, a response column could show new employee surveys and exit questionnaires for departing employees as response documents to the regular Employee Record in the Employees by Name view. This formula shows two different messages depending on the form that was used for the response document and also displays the mailing status of the documents.

@If(Form = "Exit"; "Exit Form, "; "New Hire Information, ") + @If(Mailed = "Yes"; "mailed to employee  " + @Text(@Date(PostedDate)); "not yet mailed")

If the response uses an Exit form, the response row might look like this:


If the response uses a New Hire Information form, the response row might look like this:
Tracking the number of responses

You can use @DocDescendants to keep track of numbers of responses, so authors can quickly see how many responses they've received. This formula for a main document column (not the responses column) is helpful in response-style views.

Subject + "  (" + @Name([CN]; From) + @DocDescendants(")"; ", % response)"; ", % responses)")

If the document is a main document, the column displays the contents of the Subject field, the author name, and the number of response and response-to-response documents. If there is one response, the column displays "response." Otherwise, it displays "responses." Main document rows might look like this:


See Also