A problem with view selection formula

Hi All

I wanted the collection of the documents in the view for 2 condition.

e.g consider the e.g

SELECT form=“Lotus” & @year(datefield) < @year(now)

The above condition , gets the collection of the documents of the previous year’s document , except current year

2)I want to add another condition to it

SELECT form=“Lotus” & (@year(datefield) < @year(now))& (testfield=“”|testfield=“open”)

There is no collection of docuemnts

when the testfield is emppty or Open value.

but the field "testfield is having open and “” value .

How to write selection formula for 2 condtion

getting last year’s document and(&) testfield=“”|testfield=“Open”

Thanks

Subject: A problem with view selection formula

First I guess you want to use @Year(@Now) instead of @year(now). Second I recommend you not to use date/time formulas in the view selection since the index want to be updated every second because @Now has changed. Use an agent to update the documents instead, it only need to run once every year. Rest of the formula seems to be OK. Look out for the case, does the documents contain the value “open” or “Open”.

Subject: RE: A problem with view selection formula

Nowadays you can change the Selection Formula of a view using LotusScript. It makes a lot more sense to change the view annually rather than modify the documents, messing up everyone’s unread marks and causing a monster replication.