Limited Number Of Documents In A View.

115 pts.
Tags:
Lotus Notes Developement
I have a Notes database for Projects. The priority is calculated using various criteria. The manager wants a view that only shows the top 25 high priority projects. How can I create a view formula that only populates with 25 entries.

Thanks For Your Help.



Software/Hardware used:
Notes 6.5.3
ASKED: October 24, 2011  8:59 PM
UPDATED: October 26, 2011  5:39 PM

Answer Wiki

Thanks. We'll let you know when a new response is added.

It would be difficult in a view, as you would have to change values on the document to indicate that it belongs to this “top 25″. However, you can use a folder (which will look like a view to most everyone) as the view. Then write a QuerySave for those particular documents that run the analysis everytime a document is saved. If a new document is being added to the “top 25″ list based on this event, then have it clear the folder’s contents, and then re-add all of the top 25 entries.

I realize this may not be the only way to do this, and it has it caveats – if it does not suffice, please let me know why it won’t and I will try to offer another suggestion.

Discuss This Question: 4  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • Mglist
    Thank you SlikTool for your response. We may have 200 to 300 projects active at any one time and priorities changing based upon the customer's needs. So to recreated the folder each time a document is updated would be a lot of overhead. I was kind of hoping there was a parameter that could be set, or a view formula that would manage the amount of documents displayed. I think that I may have to write an agent in LotusScript that would evalute whether the document is in the top 25 and set a hidden field on the document to yes or no. Then use that field value in the view selection formula. If you know of a different way, please let me know. Thanks for your help.
    115 pointsBadges:
    report
  • Ledlincoln
    Mglist, I think you're on the right track. A nightly agent can set or reset the priority field on each document. An even simpler option would be for the manager to just look at the top 25 docs in a priority-sorted view. :-)
    1,620 pointsBadges:
    report
  • SlikTool
    @Mglist - an agent will work, nightly if you choose and thus a view will work. My recommendation was based on the assumption (always dangerous I know) that this Top 25 had to always be up to date. If it can wait nightly, or even every 4 hours or so, an agent is likely the safe route. A side thought though, is a view sorted by by the date time of being added to the Top 25 (so flag for Top 25, and flag for when it was set). The only issue is, the view will likely have more than 25 in the view at different times of the day, but you could purge the older ones (based on the "added to Top 25" field) hourly without likely causing an issue. Think that might work?
    1,840 pointsBadges:
    report
  • Mglist
    Thanks to all that responded with ideas. I created a view with the priority field in the first column sorted high to low. The second column used the simple function, # in View, so that it showned 1,2,3...etc. The manager insisted that he only wanted to see the top 25 and nothing more. You know how some people can be? I discuss the agent and a nightly update routine with the manager and explained with this method I could limit the documents in the view to be exactly 25. I also offered to have the agent run more often if it was necessary. He agreed to this solution and would see if once a day would serve his needs. So that is what I will do. I was hoping for a simpler solution, but it is what it is. Again, thanks for all the help. Mglist
    115 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following