Solved

View Selection formula doesn't work

Posted on 2000-05-06
5
208 Views
Last Modified: 2013-12-18
Hi,
I have a view that need to show all documents which Requested Date/Creation Date exceeds/equals to 60 days old compared to the current system date.

Here is my formula:
SELECT (form="Travel Request") & Status="Approved" & (@Today - @Date(TR_Date)) >= 60

However, it doesn't work at all.
I have a few documents which TR_Date is "02/05/2000", and yet they are showed in the view as well.

Is that anything wrong in my formula?

Thanks a lot!
0
Comment
Question by:kspuea
  • 2
  • 2
5 Comments
 

Expert Comment

by:makerman
Comment Utility
Hi!

Have you tried to compose your view formula in another way? I mean, why not do the counting in the form (in a hidden field) and then use that value in the view? For me it has worked just fine. What you need though is a scheduled agent that "changes" your field containing @Today formula.

Best regards,

Mira Å.
0
 

Author Comment

by:kspuea
Comment Utility
Thanks, makerman.
But what I need is just to compare today's date with a Date field in the document. I don't want to change the field value.
0
 
LVL 3

Accepted Solution

by:
Simon_Hendry earned 20 total points
Comment Utility
(@Today - @Date(TR_Date)) will return the number of seconds between the two dates your need to use

(form="Travel Request") & Status="Approved" & (@Today - @Date(TR_Date)) >= 5184000
0
 
LVL 3

Expert Comment

by:Simon_Hendry
Comment Utility
Just to add to this though... Using @Today in your view selection formula means that your view index has to be calculated every single time you access the view ... You will probably notice that the "View Refresh Required" marker is always on for this view.. In a small database this is probably not a problem but if this database grows to any substantial size then opening the view is going to be very slow and the server update task is going to be doing alot of work....

A better solution to this is to create an agent that runs once nightly that checks the documents in the database that have (form="Travel Request") & Status="Approved"  and checks whether they are older than 60 days , if they are then it marks them with a field value ( say InView="Yes"  for example) .. Then set your view formula to be

(form="Travel Request") & Status="Approved" & Inview="Yes"

That way your view index will be static and your server will have to do much less work !!!
0
 

Author Comment

by:kspuea
Comment Utility
Thanks a lot, Simon!!
That solved my problem now.
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

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…
I thought it will be a good idea to make a post as it will help in case someone else faces these issues. I trust this gives an idea how each entry in Notes.ini can mean a lot for the Domino Server to be functioning properly. This article discusses t…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …

771 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

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now