Solved

How to bring over field content

Posted on 2004-10-20
7
199 Views
Last Modified: 2013-12-18
Hi all,

I had 2 forms (eg. A & B) in a database and now in my B form, I'll like to show certain field's value (just 1 field) which is from A form inside B form.
Question 1
Pls advise what's the formula to use to search inside the DB for A form value and display inside B form?

Question 2 (just 1 of the field inside form A)
If my user had create many Form A by enter all different information in each form A and I will like to capture all the values (that is under only 1 field name) enter by different people inside form B, so that I can do some caculation. How should I do that?

Any kind help is greatly appreciated!

Rgds,
Eve
0
Comment
Question by:EvelynLoh
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
7 Comments
 
LVL 19

Accepted Solution

by:
madheeswar earned 25 total points
ID: 12357415
1)
Use @DbLookup

2)
Did not understood.
0
 
LVL 31

Assisted Solution

by:qwaletee
qwaletee earned 25 total points
ID: 12358257
You need for the B document to have a "key" value form the A document.  Preferably, this key is the UNID (Universal ID, the document's replica ID), because you can then use @GetDocField, which is really, really fast, and doe snot require additional setup.  if you have a different value for key, then you need a view that contains only A documents sorted on this key value, then you use @DbLookup on the B form, with that view and the A key value.

Note I keep saying A document and B document, not A form and B form.  The form is just what you use to edit and program.  The document is what contains the field values,a dn what appears in view, and is what is being looke dup.  You use a form to start looking up, but what you are looking up is always a document, never a form.

Question 2 is really confusing, and you shoudl opena separate question, because even if your question was clear, this whole thread will get confusing as some comments are refering to question 1 and some refer to question 2.  It sounds as if you have many B documents for each A document.  As long as all the Bs contain the key from A, you can do the same @DbLookup technique I described earlier -- have a view containing only B documents, sorted on the "foreign key" (the B documents field value that is the key found originally in A).  the, in the A form, you can use @DbLookup against that view, with A's own key.

Note that in each case, you need to use @IsError to check the result, because sometimes, @DbLookup will not be able to find a match, and will return an error value, which can really mess things up.  Here is a typical formula:

view := "name of view";
key := field_name_that_servers_as_key;
column := 12345; "The column number of the view that contains the value you want to retrieve -- not the key column";
result := @DbLookup(""; ""; view; key; column);
@If(@IsError(result); "Could not retrieve " + @Text(key) + " value from view " + view + ": " + @Text(result); result)
0
 
LVL 3

Expert Comment

by:Andrea Ercolino
ID: 12359572
something useful for you in my comments to question --> http://Q_21167331.html
0
 
LVL 3

Expert Comment

by:Andrea Ercolino
ID: 12359584
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

You’ve got a lotus Domino web server, and you have been told that “leverage browser caching” is a must do. This means that we have to tell the browser everywhere in the web to use cache. In other words, we set (and send) an expiration date in the HT…
  In today’s Arena we can’t imagine our lives without Internet as we are highly used to of it. If we consider our life style just for only 2 min we found that face to face communication is swapped by e-communication.  Every Where from Works place to…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…
Attackers love to prey on accounts that have privileges. Reducing privileged accounts and protecting privileged accounts therefore is paramount. Users, groups, and service accounts need to be protected to help protect the entire Active Directory …

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question