From wiki.ginstr.com
Jump to: navigation, search
m (formatting)
(Set timestamp to variable)
Line 30: Line 30:
 
** hardcoded value (any <code>long</code> number)
 
** hardcoded value (any <code>long</code> number)
 
** keyword
 
** keyword
*** <code>NOW</code> - sets current timestamp into variable
+
*** <code>now</code> - sets current timestamp into variable
*** <code>START_TODAY</code> - sets timestamp of beginning of current day into variable
+
*** <code>startToday</code> - sets timestamp of beginning of current day into variable
*** <code>START_TODAY_GMT</code> - sets timestamp of beginning of current day as GMT into variable
+
*** <code>startTodayGMT</code> - sets timestamp of beginning of current day as GMT into variable
*** <code>START_TOMORROW</code> - sets timestamp of beginning of next day into variable
+
*** <code>startTomorrow</code> - sets timestamp of beginning of next day into variable
*** <code>START_TOMORROW_GMT</code> - sets timestamp of beginning of next day as GMT into variable
+
*** <code>startTomorrowGMT</code> - sets timestamp of beginning of next day as GMT into variable
*** <code>END_TODAY</code> - sets timestamp of end of current day into variable
+
*** <code>endToday</code> - sets timestamp of end of current day into variable
*** <code>END_TOMORROW</code> - sets timestamp of end of next day into variable
+
*** <code>endTomorrow</code> - sets timestamp of end of next day into variable
 
|-
 
|-
 
|}
 
|}

Revision as of 13:00, 20 July 2017

gn:act_setTimestampToVar

Description
Action used to load special timestamp values to variable which are defined by keywords, or hardcoded value.
Action returns
void

Action signatures

Set timestamp to variable

[gn:act_setTimestampToVar]|[target,value]
Parameter Description
target target where the value will be stored
value numeric value or keyword which is used to generate value
  • Valid value:
    • hardcoded value (any long number)
    • keyword
      • now - sets current timestamp into variable
      • startToday - sets timestamp of beginning of current day into variable
      • startTodayGMT - sets timestamp of beginning of current day as GMT into variable
      • startTomorrow - sets timestamp of beginning of next day into variable
      • startTomorrowGMT - sets timestamp of beginning of next day as GMT into variable
      • endToday - sets timestamp of end of current day into variable
      • endTomorrow - sets timestamp of end of next day into variable

Example

@variable/currentTime - target
now - keyword
[gn:act_setTimestampToVar]|[@variable/currentTime,now]

Set calculated timestamp to variable

[gn:act_setTimestampToVar]|[target,value;expression]
Parameter Description
target target where the value will be stored
value numeric value or keyword which is used to generate value
  • Valid value:
    • CALCULATION keyword
expression calculation expression (e.g. now-43200000)

Example

@variable/currentTime - target
calculation - keyword
now-43200000 - expression
[gn:act_setTimestampToVar]|[@variable/nowMinus12h,calculation;now-43200000]