Functions
Contents
Index of Functions
This list aims to be a comprehensive list of default functions available with Presence 3.6.2. Please note that it is a work in progress.
Boolean Functions
- &equalsString {String1, String2}
This function compares String1 and String2. If they are equal it will return the value "true". Otherwise it will return "false".
- &if {"testString", "resultForTrue", "resultForFalse"}
This function performs a test on "testString". If it equals "true" or "1" the value of "resultForTrue" will be returned. Otherwise, "resultForFalse" will be returned.
Data Functions
- &onDemand{"taskAlias", "parameter","Parm2"+}
Calls an On Demand Task.
taskAlias: The alias of the Task to be called parameter+ : The Parameters to be passed (zero or more).
eg:
&onDemand{"myTask","id=5", "now=true"}
Calls the Task referenced by the alias "myTask" and sets the following variables:
${id} = 5 ${now} = true
- &doesColumnExist{"COL_NAME"}
Tests to see if the specified column name exists in the current data table - returns "true" if it does or "false" if not.
Parameter 1: The column name to test
Date Functions
- ¤tDate {format, offset}
format: The date format to use to format the current date (e.g. "dd/MM/yyyy"). offset: (Optional) The offset in days (e.g. -1, 1, 2, -5)
Returns: the current date in the format specified by the first parameter.
- &formatDate{"value_or_variable", "input format", "output format"}
Date and Time Patterns
G Era designator e.g. "AD" y Year e.g. yyyy="2015"; yy="15" M Month in year e.g. M="8" (August); MM="08"; MMM="Aug" MMMM="August" w Week in year e.g. w="33" (13/August/2015) W Week in month e.g. W="2" (13/August/2015) D Day in year e.g. D="225" (13/August/2015) d Day in month e.g d="13" (13/August/2015) F Day of week in month E Day in week e.g. E="Thu" a Am/pm marker H Hour in day (0-23) h Hour in day (1-12) m Minute in hour s Second in minute S Millisecond z Time zone e.g. z="BST"; zzzz="British Summer Time" Z Time zone (RFC 822 time zone) e.g Z="+0100" X Time zone (ISO 8601 time zone) e.g X="+01"; XX="+0100"; XXX="+01:00"