LogiView

Functions and Commands

Date and Time

     

The following functions are available to edit date and time information:

date {DAT_VAR | STR_VAR}= date() or
{DAT_VAR | STR_VAR}= date({STR_EXPR})

This function returns a string with the current date.
date_add {DAT_VAR|STR_VAR}= date_add({DAT_EXPR},{DAT_EXPR})
This function is used to add two dates.
date_sub {DAT_VAR|STR_VAR}= date_sub({DAT_EXPR},{DAT_EXPR})
This function is used to subtract two dates.
day_nr {INT_VAR}= day_nr({DAT_EXPR})
This function returns the number "25569 + x" which corresponds to the forwarded date. Hence, the date 01.01.1970 is defined as 25569; for every further day "1" is added.
time {STR_VAR}= time()
This function returns a string with the current time. The time format corresponds to the common representation in DataView.
weekday {INT_VAR}= weekday({DAT_EXPR})
This function returns the day of the week for a certain date. Monday is defined as "1", Sunday is defined as "7".
year_week {INT_VAR}= year_week({DAT_EXPR})
This function returns the calender week for a date as a value from 0 to 53. "Monday" is considered as the first day of the week.