In a view - get column value from another view?

I have a problem with an inherited application.

There is a view “ViewOne” that builds up an array. It uses the form “Product”.

On each form “Product” there is a connection to a subform “delivery” with information such as prices and volumes. So when you create a “product” you get one document with Product info and then you get one document with PriceInfo.

The problem I have is to extend the view “ViewOne” with price. The normal way to find the price is to take the docID and then do a lookup in “ViewFive” where I see the price.

I know you cannot have a view column with the value

@dblookup another view.

Any ideas?

Subject: in a view - get column value from another view?

As far as I know, this is not possible using a view. If you are developing a browser based database, you can produce your own view-like page by writing HTML in an agent.

Subject: in a view - get column value from another view?

In a Notes view, the rules are simples: on one line is displayed one, single document. Any data showing in the columns is computed from that document.

In order to display the price on the view, you will have to inherit that price into the document first.

This could be done by using the lookup inside the document on the querysave, for instance, or running a scheduled agent to update the parent documents with the price on a regular basis. ou could also have an scheduled agent create and update new small documents contaning only the information you want to see in the view, and display these documents in the view instead; then code the queryOpen event of the view so that the real document is opened instead of the summary document.

But none of these solutions are perfect, because they won’t be real time solutions. The truth is, what you are trying to do is borderline out of Notes scope; because it should really be designed in a fully relational system, and Notes isn’t relational.

Still, another way to handle this problem would be to move away from traditional views:

  • Web based application could be worked to generate the HTML, just like a report, by analysing both the parent and the child document before creating the code

  • You could write an process that will generate an excel report, again by “joining” the parent and child documents when you are exporting.

  • You could produce a report into a RTF into a temporary notes document, based on a newsletter style, which display a list of links to the main documents, and shows the price…

These solutions would involbve a lot of work because they really are like reports, you are the one doing the whole joining job rather than letting Notes do it for you.

Hth

Nicolas Abesdris