## Consolidate customer data

It often happens that customer data is collected along the way, probably by a contact center team whose primary concern is different than having only one record per customer. So the database needs a consolidation from time to time.

With the following two rules it is possible to conceive a 100% automated solution:

• Any two customers can be made the same if they share at least one key information
• If two customers don’t share any key information, then nothing can be said about them, so they should be kept apart

So applying the equivalence relation and its transitive property to customer data, we get:

• Equivalence: Person1 = Person2 if and only if there exists at least one field F (key information) for which Person1.F = Person2.F
• Transitivity: if Person1 = Person2 and Person2 = Person3 then Person1 = Person3

Note that the Transitive property says not only that: if Person1.F = Person2.F and Person2.F = Person3.F then Person1 = Person3, but also that: if Person1.F = Person2.F and Person2.G = Person3.G then Person1 = Person3, being F different from G (this is what makes possible the 100%)

(revised text from my own comment 12517678 at Experts-Exchange)

## Paper documents

Lotus Notes possiblities are founded upon the concept of NotesDocument, which is just like a paper document. Paper documents are flexible because they can be updated in a breeze. For example you can add a date stamp to any paper document when it arrives to you, even if it was not created with a white space for that purpose. NotesDocuments can be individually changed as needed, both pasting in and cutting information from them.

(revised text from my own comment 12349953 at Experts-Exchange)

## Open a page from a document in a view

Some documents with web bookmarks appear in a Notes view. How do you open a bookmarked page bypassing the opening of the corresponding Notes document?
Two solutions follow: one uses Notes magic, and the other the InViewEdit event.

Notes magic

1. Create a Dummy form, used for doing nothing (it sounds weird but works)
2. Dummy: for preventing document creation, it should have a field [SaveOptions]=0 (text /computed for display)
3. Dummy: for preventing form opening, it shoud have a sentence Continue = False in the QueryOpen script
4. View: for inhibiting the default behaviour, in the FormFormula object write “Dummy”
5. View: put the formula @UrlOpen( Bookmark ) into the QueryOpenDocument formula

now, if you double click the Bookmark document, the page (just it) appears in a new window

(revised text from my own comment 12351627 at Experts-Exchange)

InViewEdit event

Something special happens if an editable column shows a value as an icon: The SAVE_REQUEST type of the InViewEdit event is triggered as soon as the user clicks on the icon.

``````Sub Inviewedit(Source As NotesUIView, Requesttype As Integer, Colprogname As Variant, Columnvalue As Variant, Continue As Variant)
' This view has one editable column, which is for display of an icon.

' Define constants for request types
Const SAVE_REQUEST = 3

' Define variables
Dim db As NotesDatabase
Dim doc As NotesDocument
Dim ws As New NotesUIWorkspace
Dim caret As String

' Get the CaretNoteID - exit if it does not point at a document
caret = Source.CaretNoteID
If caret = "0" Then Exit Sub

' Get the current database and document
Set db = Source.View.Parent
Set doc = db.GetDocumentByID( caret )

' Select the request type
Select Case Requesttype

Case SAVE_REQUEST
Dim w As New NotesUIWorkspace
w.UrlOpen doc.URL( 0 )
Continue = False

End Select
End Sub``````

(revised text from my own comment 12738085 at Experts-Exchange)