Dear All,I am a Lotus Notes Client and Web Developer from many years…
i have read many post and articles in this forum about the @TextToTime(“Today”) problem in a view selection formula.
I think i have make the correct approach in my applications, but i wish to ensure about some things.
My application is replicated on 4 server and contains many views (more than 80 views) with:
-
Current Year, Next Year, Last Year views
-
Some views with Montlhy Recently documents
-
Some views with Daily Recently documents
-
Views by EndDate
all of this views contains in the selection formula the option @TextToTime(“Today”).
The database contains >20.000 documents and will work also as historycal archive in the future.
So,
actually I use to flag/tab each document with a 2 scheduled daily agent that run at 1.30 am each day.
This 2 agent are enabled to run on each server replica and each agent flag/tab/modify only the document that has been created in the related replica, and that need a real updating in order to move document from a view to another view only if really necessary.
The replication task runs 4 time each day. (8.30 am, 12.30am, 16.30pm, 20.30pm)
I have tested this 2 scheduled agents and seems it works correctly and the rebuild index is performed for the EndDate views.
I have only some problem with a 3-Daily late view that seems not works correctly…i need each day to perform SHIFT+F9 in order to update the view.
the selection formula of the view is:
SELECT Form = “FA”:“FB”: “FC” & @Created >= @Adjust(@TextToTime(“Today”);0;0;-3;0;0;0)
the scheduled agent perform the following:
in agent document selection i have put:
In folder ‘All By Person 3 Daily’
in the agent formula i have put:
@If(
Form = “FA”:“FB”: “FC” &
@Created < @Adjust(@TextToTime(“Today”);0;0;-3;0;0;0) & RefreshedTRDailyFlag=“”
& SITE =SERVER_CREATION_SITE;
@Do(
@SetField (“RefreshedTRDaily”;@Now);
@SetField(“RefreshedTRDailyFlag”;“1”)
);
“”);
So, the agent execute a correct flag of the document day-by-day. The RefreshedTRDaily field is correctly set…BUT THE VIEW IN NOT REBUILD.
I wish to ask you the following:
-
Using that flag/tab approach wiht an Agent ALL MY VIEWS IN DATABASE MUST HAVE AN HIDE-COLUMN WITH THE FIELD THAT IS CHANGED IN THE RELATED AGENT ? (in the above case i shold create an hide-column with the field RefreshedTRDaily value)
-
I have notice that all view in my database have the following propertys:
Index - Refresh: Automatically
Index - Discard: If inactive for 45 days
You think that i need to change this setting to the default Lotus Notes values ?
Index - Refresh: Auto, after first use
Index - Discard: If inactive for 45 days
PS:
For info i wish to tell you that i think that for me it is very impossible to use the approach to change the ViewSelectionFormula in each view because i have more and more views in my database.
We cannot perform a daily change in the design viewselectionformula because i have also 4 replication db!!!
I also try to use C-API rebuild but i have many problems because the server is a SUN SOLARIS machine, and i have many problem with the related .dll files (.so files on sun solaris machine)
Thank you very much to all
excuse me for my English
Davide