Create a view concatenating information to use in @DbLookup

Posted on 2008-02-01
Medium Priority
Last Modified: 2013-12-18
I have Documents describing Reports that have the fields, RptName, RptRecipient and AltRecipient.

Any one recipient might be on many documents, there are about 80.

I want a view that will show a person in one column, whether they appear in the RptRecipient OR the AltRecipient field in any of the documents, and the associated RptNames they show up on.

So the result might have, in one row

Recipient              Report
Jane Doe               Expense Rpt, HR Rpt, Vacat Rpt

Where there are three documents, one for each report, and Jane may have been in either the RptRecipient OR the AltRecipient field, but in this view there is only one row.

The purpose is to use this view for an @DbLookup formula based on the user name.

1.  I have a view that displays the RptRecipient and one Report per row, so there are multiple rows with one user name, and I don't know if @DbLookup will step through all the rows
2.  I can't get the first column to list both the RptRecipient and AltRecipient together.  I've tried RptRecipient : AltRecipient but it won't show the AlRecipient.
Question by:jkee54
LVL 63

Expert Comment

ID: 20800239


also this might be helpful.

Also , can either field be blank or have multiple values

Also have you considered using @DBcolumn instead of  @DbLookup ?

I hope this helps !
LVL 46

Accepted Solution

Sjef Bosman earned 1000 total points
ID: 20800618
In a view, one row contains data from one document, unless it is a category row. One row never contains data from multiple documents.

1) @DbLookup doesn't "step through", but if you categorise the view, @DbLookup will give you only the distinct values
2) What do you mean "together"? Is the column categorised? Then use a formula like:
      @Trim(@Unique(RptRecipient : AltRecipient))


Author Comment

ID: 20874571
That did the trick, works like a charm, thanks!

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

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

For Desktop Techs: How to retain a user's Notes configuration data when swapping out the end user's computer. (Assuming that you are not upgrading to a completely different version of Notes client) All you need to do is: 1) install Notes o…
  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…
How to fix display issue, screen flickering issue when I plug in power cord to the machine. Before I start explaining the solution lets check out once the issue how it looks like after I connect the power cord. most of you also have faced this…
The video provides a quick and easy steps to migrate MBOX file to well known Outlook PST and Office 365. Besides this, it also supports and migrates more than 20 email clients of MBOX which include AppleMail, Opera, Thunderbird and SeaMonkey effortl…
Suggested Courses

601 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