Search code examples
lotus-noteslotuslotus-formula

How to add a field from a 2nd form?


I'm modifying an existing Lotus view to include a field from another form.

  1. I first appended a new column and set it to the desired field. However, after I refreshed, the new column was blank even though I know it has data.

  2. I then updated the View Selection formula from:

SELECT Form = "A" & StatusIndex < "06"
to:
SELECT (Form = "A"| Form = "B") & StatusIndex < "06"

Still no luck. The view is refreshing successfully, but the new field is still blank. What else is there to add this new column to this view?

This is my first time experimenting with Lotus, so if I seem to be missing some major concept, I probably am.

Edit

If I was pulling this data using SQL, the statement would probably be something like:

Select A.* , B.*  
from A inner join B on A.id=B.id  
where A.StatusIndex < "06";  

Which brings up another question: Where is the relationship between these tables/forms defined?


Solution

  • Unfortunately, there is no (intrinsic) "join" functionality available from a Notes view. If you absolutely need the different columns appearing in the same row (document) in a view, then one option is to de-normalize the data, such that upon saving of "Document B" you update the related "Document A" with the necessary field values. (This is also the only real way to get full-text searches to work across "joined" data).

    If the view is for display on browsers only, then you may have other options, such as making AJAX calls to load the related data fields, etc.