Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Checks whether the portal is viewed in HTTPS (secure communication).
In Portal - Hostname Settings you can activate [force https] to make your portal run in secure https-mode.
This function is SQL compatible. For more information about SQL compatibility, see our documentation.
Returns yes/true
if the portal is running in secure https mode.
Returns no/false
if portal is running in unsecure http mode.
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
The Average()
function calculates the average of a list of numbers, date times or duration.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns number, datetime or duration that is the average of the given values
.
Returns Unknown
if one of the parameter values is unknown or outside the common valid boundaries.
Name | Type | Required | Description |
---|---|---|---|
| list of numbers datetimes or durations. | The list of values for which the average is calculated. The values can be either numbers, datetimes or durations. |
The Count()
function returns the number of items in a list or concept set.
This function is SQL compatible. For more information about SQL compatibility, see our documentation.
Returns the number of items in the given list
or concept_set
.
Returns Unknown
if one of the parameter values is unknown or outside the common valid boundaries.
Name | Type | Required | Description |
---|---|---|---|
| List of elements of the same type | a list of values or elements of the same type. | |
| A list of concepts | a list of concepts |
The First()
function returns the first item in a list or concept set.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns the first item in the given list
or concept_set
.
Returns Unknown
if one of the parameter values is unknown or outside the common valid date boundaries.
Name | Type | Required | Description |
---|
The Last()
function returns the last item in a list or concept set.
For (persistent) lists it must indicate a field of that list.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns the last item in the given list
or concept_set
.
Returns Unknown
if one of the parameter values is unknown or outside the common valid date boundaries.
Possible fault message in expression editor: Invalid call to a function: parameter mismatch at position(x,y): Last
This could mean that there is no field of list used, but only the (reference to a) list.
The Last function needs a field from list where filter construction, or if you only want to get the last row of a list, use RowId([list]) of [list] where [filter]
.
Name | Type | Required | Description |
---|
The Max()
function calculates the highest value of a list of numbers, datetimes or durations.
This function is SQL compatible. For more information about SQL compatibility, see our .
Returns a number, datetime or duration that is the highest value of the given values
.
Returns Unknown
if one of the parameter values is unknown or outside the common valid date boundaries.
Name | Type | Required | Description |
---|
The Min()
function calculates the lowest value of a list of numbers, datetimes or durations.
This function is SQL compatible. For more information about SQL compatibility, see our .
Returns a number, datetime or duration that is the lowest value of the given values
.
Returns Unknown
if one of the parameter values is unknown or outside the common valid date boundaries.
Name | Type | Required | Description |
---|
The ConceptId()
function returns the internal id of a concept.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns a number that is internally used by wem to identify concept
.
Returns Unknown
if the parameter is unknown.
Name | Type | Required | Description |
---|
The MimeType()
function returns the type of a provided file, based on its extension and the first few bytes in the file.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a text that contains the mime type of a file.
Returns Unknown
if the parameter value (file) is unknown.
Common media types are listed on wikipedia.
Name | Type | Required | Description |
---|---|---|---|
| file | a file |
The IsNewRow()
function returns a boolean value that indicates if the specified row is newly created and not yet saved to the database.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns true if the specified row is not yet saved to the database. Returns false if the specified row is already saved to the database.
If the parameter is a list, then the current row of the list is taken.
If the parameter is a reference, then the referenced row is taken.
Name | Type | Required | Description |
---|---|---|---|
| list | a database list | |
reference | reference | a reference to a row of a database list |
The Totp()
function calculates a time-based one-time password based on the given secret and given UTC time.
WIKI: https://en.wikipedia.org/wiki/Time-based_one-time_password
MyWEM Forum: https://my.wem.io/forum?threadid=184
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a text
value based on the given secret and UTC time, containing 6 numbers.
Returns Unknown
if one of the parameter values is unknown or outside the common valid boundaries. May throw a Server500 error when the secret is NOT a proper Base32 value with characters from the collection "ABCDEFGHIJKLMNOPQRSTUVWXYZ234567
"
Name | Type | Required | Description |
---|---|---|---|
| Base32 text | secret the password is based on. Must be base32 encoded and must contain any of the characters from the collection as indicated in the syntax example. | |
| date time | UTC time or time and interval the password is based on. |
| list or a concept_set | a collection of values or elements of the same type, or a list of fields from a (persistent) list. |
| List of elements of the same type | a list of values or elements of the same type. |
| A list of concepts | a list of concepts |
| concept | a single concept, either literal or as expression |
| list | list of values which can be either numbers, datetimes or durations. |
| list | the list of values. The values can be either numbers, datetimes or durations. |
The Description()
function returns the description of a concept.
Read general information about Concepts and Ontology
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns the description of a concept. This description can be edited in the properties of the concept.
Returns Unknown
if the parameter is unknown, or if the description property is empty.
Name | Type | Required | Description |
---|---|---|---|
The GetDescendants()
function returns all descendant concepts of a concept.
Read general information about Concepts and Ontology
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a concept set that contains all the descendant concepts of a concept.
The concept
parameter is not included.
An unknown value is returned if the concept has no descendants or the given parameter is unknown.
The GetChildren() function only returns the direct child concepts.
Name | Type | Required | Description |
---|---|---|---|
The GetAncestors()
function returns all the parents (ancestors) of a concept.
Read general information about Concepts and Ontology
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a Concept Set with all the parent concepts of a concept. The concept
parameter is not included in the result.
An unknown value is returned if the concept has no parent or the given parameter is unknown.
The GetParent() function only returns the direct parent of a concept.
Name | Type | Required | Description |
---|---|---|---|
The GetChildren()
function returns all the child concepts of a concept.
Read general information about Concepts and Ontology
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a concept set that contains the direct child concepts of a concept.
An unknown value is returned if the concept has no children or the given parameter is unknown.
The GetDescendants() function includes all descendants (multiple levels).
Name | Type | Required | Description |
---|---|---|---|
The FindConcepts()
function searches concepts by text and/or synonyms within an indicated set.
Read general information about Concepts and Ontology
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a concept set that contains all the concepts found with the given parameters.
Returns Unknown
if one of the parameter values is unknown, or if the search parameters yield no result.
Name | Type | Required | Description |
---|---|---|---|
The Sum()
function calculates the total value of a list of numbers or durations.
This function is SQL compatible. For more information about SQL compatibility, see our .
Returns a number or duration that is the total value of the given values
.
Returns Unknown
if one of the parameter values is unknown or outside the common valid date boundaries.
Name | Type | Required | Description |
---|
The GetParent()
function returns the direct parent concept of a given concept.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns the direct parent concept of a given concept.
An unknown value is returned if the concept has no parent or the given parameter is unknown.
The function includes the entire parent chain from root to concept (excluding root and concept).
Name | Type | Required | Description |
---|
The Intersection()
function produces a concept set that contains the concepts that a part of all given concept sets in the parameters.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns a concept set with the concepts that occur in each concept set provided in the parameter list.
An unknownconceptset value is returned if any of the conceptsets in the list is unknown, or if there is no concept available in all sets in the parameterlist.
Name | Type | Required | Description |
---|
The Union()
function produces a concept set with all the concepts from a collection of concept sets and concepts (needs the List() function to combine literal sets and concepts).
Combining concepts and concept sets into a new concept set can also be achieved using addition (+).
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns a new concept set with all concepts provided in the parameter list. This collection can contain concepts from different parents.
Returns Unknown
if one of the parameter values is unknown.
Name | Type | Required | Description |
---|
The ToConcept()
function returns the concept with the given Local Name or Concept Id.
Be aware that using this function with a Local Name, this can only work if the local name used is unique in the total ontology collection. If there are more than one concept with the same local name that you are looking for, the ToConcept will not work because it searches through all of the Ontology and expects only 1 specific result to return as Concept.
For finding concepts when local name may not be unique and you want to search within a specific parent, we recommend using one of the other Concept Functions available, where you can search more specifically, like or .
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns the concept that is found with the given argument.
Returns Unknown
if:
the parameter is unknown;
if no concept can be found for the provided parameter;
if there are multiple matches for the provided parameter (local name).
Name | Type | Required | Description |
---|
The Today()
function returns the current date.
This function is SQL compatible. For more information about SQL compatibility, see our documentation.
Returns the current date without the time.
The Now() function includes the current time.
The Now()
function returns the current date.
This function is SQL compatible. For more information about SQL compatibility, see our documentation.
Returns the current date with the current time
The Today() function excludes the current time.
| text | text that is used to search the local name of a concept |
| numeric | number that is used to search concept by Concept Id |
The Date()
function accepts numeric values for each part of a date, optionally with time, and returns it as a datetime value.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a Date Time
value compiled from the separate input values for each part.
Returns Unknown
if one of the parameter values is unknown or outside the common valid date boundaries.
concept
concept
a single concept, either literal or as expression
concept
concept
a single concept, either literal or as expression
concept
concept
a single concept, either literal or as expression
concept
concept
a single concept, either literal or as expression
text
text
text to search for in names (local/display) and optionally synonyms
concept_set
list of concepts
a concept set as source for the search
include_synonyms
Yes/No
either true or false, which indicates if synonyms must be included in the filter or not.
| list | the list of values of which the sum is calculated. The values can be either numbers or durations. |
| concept | a single concept, either literal or as expression |
| list of concepts | 2 or more sets of concepts (or a single concept) combined with the List() function as parameterlist. |
| A list of concepts and/or concept-sets | a list of separate concepts or concept-sets |
The DatePart()
function retrieves a part from a date. For example, the year, the month, the week, the day, the hour, the minutes or the seconds.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a number that is a part of a date. If the date is unknown then this function returns unknown.
Returns Unknown
if one of the parameter values is unknown or outside the common valid date boundaries.
Name | Type | Required | Description |
---|---|---|---|
The DateOnly()
function only returns the date part without the time part of a date.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns the date only.
Returns Unknown
if one of the parameter values is unknown or outside the common valid date boundaries.
Name | Type | Required | Description |
---|---|---|---|
The DateDiff()
function calculates the difference between two dates. You can use the DateDiff for the difference in: year, month, week, day, hour, minute or second.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a number that is the difference between two dates in a specific unit. If one of the two dates is unknown then this function returns unknown.
Returns Unknown
if one of the parameter values is unknown or outside the common valid date boundaries.
Name | Type | Required | Description |
---|---|---|---|
The Synonyms()
function returns the synonym text values of a concept.
Read general information about Concepts and Ontology
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns an array with text values that contain the synonyms of the given concept.
An unknown value is returned if the concept is unknown or there are no synonyms provided in the concept properties.
Name | Type | Required | Description |
---|---|---|---|
The TimeOfDay()
function returns the duration that represents the fraction of the day that has elapsed since midnight.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns the duration that represents the fraction of the day that has elapsed since midnight.
Returns Unknown
if one of the parameter values is unknown or outside the common valid date boundaries.
Name | Type | Required | Description |
---|---|---|---|
The ToLocal()
function converts a UTC date to a local date with the given timezone (TZ database name). You can find the time zones used in wem in the list of IANA Standard Time zones.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns the local date with the given timezone.
Returns null if the timezone argument is not recognized.
Name | Type | Required | Description |
---|---|---|---|
The ToDuration()
function converts provided input to a specific Duration value. Possible values are a string ("dd.HH:mm:ss.fff"), ticks, a number with specified date-unit or specific numeric values for days, hours, minutes, seconds and milliseconds.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a Duration
value compiled from the input values.
Returns Unknown
if one of the parameter values is unknown or outside the common valid boundaries.
The FromUnixTimestamp()
function converts a unix timestamp to a date.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns the date represented by the given unix timestamp
Returns Unknown
if one of the parameter values is unknown or outside the common valid date boundaries.
This function returns the date in the format settings of your project.
Name | Type | Required | Description |
---|
The DayOfWeek()
function returns the day of the week. Monday is day 1 and Sunday is day 7.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns a number that represents the day of a week where 1 is Monday, 2 is Tuesday, etc.
Returns Unknown
if one of the parameter values is unknown or outside the common valid date boundaries.
Name | Type | Required | Description |
---|
The MoveDate()
function shifts a date by a given amount of a date unit.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns a new date where a number of units is added/subtracted to/from a date.
Returns Unknown
if one of the parameter values is unknown or outside the common valid date boundaries.
Name | Type | Required | Description |
---|
The LocalName()
function returns the local name of a given concept.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns a text that contains the local name of a concept.
An unknown value is returned if the concept is unknown.
Name | Type | Required | Description |
---|
The ToUTC()
function converts a local date with the given timezone (TZ database name) to a UTC date. You can find the time zones used in wem in the list of .
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns a UTC date.
Returns null
if the time zone argument is not recognized
Name | Type | Required | Description |
---|
The ToUnixTimestamp()
function converts a date to a unix timestamp.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns the date as a unix timestamp.
Returns Unknown
if one of the parameter values is unknown or outside the common valid date boundaries.
Name | Type | Required | Description |
---|
Name | Type | Required | Description |
---|---|---|---|
Name | Type | Required | Description |
---|---|---|---|
The IsPreview()
function checks if the portal is being used in the Preview Runtime environment.
This function allows you to make certain features available only in the Preview environment. For example in a "Visible when" property of a navigation item, or even using a Decision Node in a flowchart to make a detour.
This function is SQL compatible. For more information about SQL compatibility, see our documentation.
Returns yes/true
if the portal is being used in the Preview environment.
Returns no/false
otherwise (staging or live).
The IpAddress()
function gets the IP address of the client.
This function can be used to route users from a certain network to a specific page or a custom login process. It can also be used to track the (public) IP-addresses of your users. Please note that some countries have legislation about using and storing IP-addresses (GDPR).
WIKI: http://en.wikipedia.org/wiki/IP_address
This function is SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a text that contains the IP-address of the client viewing the WEM website.
The IsFirstRequest()
function checks if the server is handling the first request of the client.
The first request of a client is the first time a browser tab connects to any page in your application. All subsequent actions in that same browser tab will no longer be viewed as the first request as long as the session is active.
This function can be used for an action that you would only like to perform when a user opens your application for the first time.
This function is SQL compatible. For more information about SQL compatibility, see our documentation.
Returns yes/true
if the server is handling the first request of the client.
Returns no/false
otherwise.
The IsStaging()
function checks if the portal is being used in the Staging Runtime environment.
This function allows you to make certain features available only in the Staging environment. For example in a "Visible when" property of a navigation item, or even using a Decision Node in a flowchart to make a detour.
This function is SQL compatible. For more information about SQL compatibility, see our documentation.
Returns yes/true
if the portal is being used in the Staging Runtime environment.
Returns no/false
otherwise (preview or live).
year
numeric
the year unit
month
numeric
the month unit (1 - 12)
day
numeric
the day unit (1 - 31)
hour
numeric
the hour unit (0 - 23)
minute
numeric
the minute unit (0 - 59)
second
numeric
the second unit (0 - 59)
text
text
text containing duration in dd.HH:mm:ss:fff form
ticks
numeric
the number of ticks (tenthousandth of a millisecond)
number
numeric
a numeric value to combine with the date_unit
date_unit
keyword
one of the date_units: day, hour, minute, second, millisecond
day
numeric
the day unit (number of days)
hour
numeric
the hour unit (0 - 23)
minute
numeric
the minute unit (0 - 59)
second
numeric
the second unit (0 - 59)
millisecond
numeric
the millisecond unit (0 - 999)
date
date time
a date
unit
keyword
Date unit keyword
Possible values: year, month, week, day, hour, minute or second.
datetime
date time
a date
start_date
date time
the start date
end_date
date time
the end date
unit
Keyword
the date unit of which the difference is calculated. Possible values: years, months, weeks, day, hour, minute or second.
concept
concept
a single concept, either literal or as expression
datetime
date time
a specified date and time
utcdate
date time
a UTC date value
timezone
text
full timezone name
| numeric | A unix timestamp (seconds passed since JAN 01 1970) |
| date time | a date |
| date time | a date |
| numeric | | the number or amount that a date the value is moved. |
| Keyword | | the [date unit] that is moved in |
| concept | a single concept, either literal or as expression |
| date time | a date value |
| text | Full timezone name. You can find the different names in the portal settings. |
| date time | a date value |
The CountryName()
function returns the name of the country that belongs to the specified language
parameter.
The language
parameter is a specific language-code which is in the form en_US
or nl_NL
. (not a text with double quotes). The Expression Editor Functions Pane has a folder Localization where you can find the specific LanguageCodes.
This function is SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a text that contains the name of the country that belongs to the specified language.
Returns Unknown
if the parameter is unknown.
Shows a syntax error "parameter mismatch" in the expression editor if the parameter is not a valid LanguageCode.
Name | Type | Required | Description |
---|---|---|---|
The Hostname()
function returns the domain name of the active portal of your published WEM project. For more information about the domain name visit .
This function can be used to create links to (specific pages of) your application. For example a link in a reset password or create account e-mail (see syntax for an example). By using the hostname function you ensure that the generated link always points to the right portal in the right environment.
This function is SQL compatible. For more information about SQL compatibility, see our .
Returns a text that contains the hostname of the portal in its particular runtime environment when used.
The IsLive()
function checks if the portal is being used in the Live Runtime environment.
This function allows you to make certain features available only in the Live environment. For example in a "Visible when" property of a navigation item, or even using a Decision Node in a flowchart to make a detour.
This function is SQL compatible. For more information about SQL compatibility, see our .
Returns yes/true
if the portal is being used in the Live environment.
Returns no/false
otherwise (preview or staging).
The IsOnRow()
function returns a yes/no value that indicates that the indicated list has a specific Row selected; this can be achieved for example by using a list node (go to row), loop node (going though multiple rows in a list) or clicking on a row in a datagrid. or - in case a reference-field is used with this function - the reference-field has a value and is indeed pointing to a specific row in the referenced list (achieved using an assignment node).
When a List is on a specific row, you can access the values of the fields in the list (to read or write values). If you try to read or write specific fields in a list, when there is no current row, you will get a fault message with something like "there is no current row". So, to be sure you can access fields of a specific item in a list and to avoid this fault situation, you can check this using the IsOnRow function.
The list-node action Reset Row Position
will set the IsOnRow to false: there will be no specific row selected on the list. The assignment action Clear value
on a reference-field will clear the reference so it will no longer point to a specific row - the IsOnRow will in that case also yield false.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns True if the list has a specific row selected and the list-fields can be used to read/write values. Or - in case a reference-field is used - the reference field points to a specific row item in the list.
Returns False if the list has no current active row which can be used, or - in case a reference-field is used - the reference field is not yet set to point to a specific row (or has been cleared with an assignment node)
language
languagecode
Specific language code (available within the Localization folder in the Expression Editor.
The FileUrl()
function returns the URL of a file.
Optionally - with the second parameter includeDomain
set to true - it will return the URL including the full domain so it can be used externally as full absolute path.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns the URL that points to the file
, by default excluding the hostname (relative path).
If the second parameter is provided as true
, it will include the hostname (full, absolute path).
Returns Unknown
if the parameter value (file) is unknown.
Name | Type | Required | Description |
---|---|---|---|
The CountryCode()
function returns two-letter country code of a language
parameter.
The language
parameter is a specific language-code which is in the form en_US
or nl_NL
. (not a text with double quotes). The Expression Editor Functions Pane has a folder Localization where you can find the specific LanguageCodes.
This function is SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a text that contains the two-letter country code of a language.
Returns Unknown
if the parameter value is unknown.
Shows a syntax error "parameter mismatch" in the expression editor if the parameter is not a valid LanguageCode.
Name | Type | Required | Description |
---|---|---|---|
The Distinct()
function returns a list of unique values from a provided list of values. The list must contain only values of the same type, and they may be numbers, dates, concepts, texts, yes/no booleans.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a collection of values where duplicates are filtered out of.
Name | Type | Required | Description |
---|---|---|---|
The NodeTrail()
function returns the most recent flowchart nodes (to a max of 20 nodes) that the user passed in current flow.
This function can be used in debugging, allowing you to see the history of steps taken before a certain situation is reached. Every number divided by the "," can be used to search for in the flowchart tab, to find the corresponding node.
This function is SQL compatible. For more information about SQL compatibility, see our .
Returns a text that lists up to the last 20 flowchart nodes that the user passed.
The Exp() function calculates the e-number
raised to the power n, where n is an number.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns a number.
Returns Invalid expression
if the parameter is not a valid number.
Name | Type | Required | Description |
---|
Function call | Result |
---|
The RowId()
function returns the ID of the current row of a list.
Any database list also has a numeric [ID] field which holds the numeric primary key value for each row and gets automatically incremented on each add new row action. When you use that ID field in your expressions, you will see it in the form [12345: ID]
, which does not make it immediately clear which field (or rather, which list) you are pointing to. Other fields use the Technical Name in expressions, which helps to understand where they are coming from. When using the RowId(list) function in expressions, you will see immediately to which list you are referring, so this makes it far more usable.
A RowId of a List-item has multiple forms:
directly displaying in a label, will use the ToString() version, and yields the combined identifying information for the List and the Row;
with the ToNumber() function, it will yield the numeric id value - same as the numeric [ID] field;
This function is SQL compatible. For more information about SQL compatibility, see our .
The Row ID value of one of the following:
The current row of a list (when using the List as parameter)
The referenced row of a reference field (when using a reference field as parameter)
The Ceiling()
function rounds a number up to an integral value (integer number without decimals) larger than or equal to the given number.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns the closest integral value that is larger than or equal to number
.
Returns Invalid expression
if the parameter is not a valid number.
Name | Type | Required | Description |
---|
Function call | Result |
---|
Name | Type | Required | Description |
---|---|---|---|
Name | Type | Required | Description |
---|
list
list
a list
reference
reference
a reference field pointing to a specific list
| List | a list from the data-model |
| reference field | a reference field |
file
file
the file of which the URL will be returned
includeDomain
boolean
indicate whether or not to include the full domain (default false)
language
languagecode
Specific language code (available within the Localization folder in the Expression Editor.
values
list
a list of values or elements of the same type.
| numeric | a numeric value. |
Exp(0) | 1 |
Exp(-0.6) | 0.548812 |
Exp(-1000) | 0 |
Exp(10) | 22026.4658 |
| numeric | a number |
Ceiling(5) | 5 |
Ceiling(5.0001) | 6 |
Ceiling(123.123) | 124 |
Ceiling(-123.89) | -123 |
The Log10()
function calculates the base-10 logarithm of a given number.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns the base-10 logarithm of number
.
Returns Invalid expression
if the parameter value is not a valid number.
Name | Type | Required | Description |
---|---|---|---|
Function call | Result |
---|---|
The URLPath()
function returns the path of the current page.
The URLPath can be configured in a when it is a deeplink. Combined with the hostname of the portal, the UrlPath provides a link that can be used as an address or link from outside (in e-mail for example) directly to the flowchart that is linked to the Navigation Item.
This function is SQL compatible. For more information about SQL compatibility, see our .
Returns a text with the URL path of the current page.
The Sqrt()
function calculates the square root of a number.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns a number that is the square root of a givennumber
.
Returns Invalid expression
if the parameter is not a valid number.
Name | Type | Required | Description |
---|
Function call | Result |
---|
The AesEncrypt()
function generates a base64 encoded ciphertext based on the given plaintext, key and initialization vector.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns a base64 encoded ciphertext
Returns invalid key
if the wrong key is used and invalid initialization vector
if the wrong vector is used.
Name | Type | Required | Description |
---|
The Round()
function rounds a number.
Rounding a number can be done according to different strategies when it comes to the edge cases (like x.5). WEM uses the Banker's Rounding strategy because of its statistical superiority and standard use in financial and statistical operations. Mind, this only applies to the Mid-Point values: the middle of the spectrum, where a decision needs to be made which way to go. So if you expect 3.85 to be rounded to 3.9 (away from zero), you'll be surprised to see WEM shows 3.8 (Banker's).
Read about rounding strategies.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns a number that is rounded to an integral number or a number of fractional digits.
Returns Invalid expression
if one of the parameter values is not a valid number.
Name | Type | Required | Description |
---|
The Sin()
function calculates the sine of a number given in radians.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns the sine of a number.
Returns Invalid expression
if rad
has no value.
Name | Type | Required | Description |
---|
Function call | Result |
---|
Function call | Result |
---|
Round(5.499) | 5 |
Round(5.501) | 6 |
Round(3.85, 1) | 3.8 |
Round(5.489, 2) | 5.49 |
Round(5.499, 2) | 5.50 |
The ProjectName()
function gets the name of the current project.
This function is SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a text with the current project name.
| numeric | a number |
| numeric | the number of fractional digits |
number
numeric
a numeric value.
Log10(0)
(no value)
Log10(100000)
5
Log10(0.00005)
-4.3010299957
Log10(-20)
(no value)
| numeric | a number. |
Sqrt(100) | 10 |
Sqrt(9) | 3 |
Sqrt(2) | 1.4142135623731 |
| text | The text to encrypt. |
| text | Text or data field that holds the encryption key. A key can be generated using |
| text | Text or data field that holds the encryption vector. A proper Vector value can be generated using |
| yes/no | enable or disable encoding with BOM (check the receiving party if BOM is required/expected). |
| numeric | a number given in unit of radians. |
Sin(0) | 0 |
Sin(Pi/2) | 1 |
Sin(1) | 0.8414709848078965 |
The Setting()
function returns the text value of a project variable. Project variables are configured in the Project Configuration page.
This function in combination with the project variables allows you to have a single place to edit variables that are used in multiple parts of your application. In the example below a project variable named "Support e-mail" is added.
This function is SQL compatible. For more information about SQL compatibility, see our documentation.
Returns the text value of a project variable.
Name | Type | Required | Description |
---|---|---|---|
The FileSize()
function returns the size of a file, in KB’s.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a number, which is the size of the given file, in KB’s.
Returns Unknown
if the parameter value (file) is unknown.
Name | Type | Required | Description |
---|---|---|---|
The HmacSha256()
function calculates a MAC (message authentication code) on provided message using the SHA256 hash function and a key/secret, and returns the calculated MAC as a hexadecimal text string.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Hashed values cannot be decoded, usually you check an incoming value against a known value that you hash yourself and check if both values are identical, to verify correctness without knowing the actual value.
Returns a hexadecimal text representation of a message, which is hashed using the Sha265 function and the key/secret for additional calculation/hashing.
Returns Unknown
if one of the parameter values is unknown or outside the common valid boundaries.
Name | Type | Required | Description |
---|---|---|---|
The List
()
function creates a list-typed collection of the provided values so it can be used in other functions and features that work with a list. All values must be of the same type.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
A collection of same-typed values that can be used as a list in other functions or list-based features. This list can be iterated through, or a specific item can be accessed using its index-position, or using the Distinct function can be narrowed down to its unique values.
Returns Unknown
if one of the parameter values is unknown or outside the common valid boundaries.
Name | Type | Required | Description |
---|---|---|---|
The AsText()
returns a rich text as plain text, including all HTML tags as normal and visible text.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns a text that includes all HTML tags as normal text.
Returns Invalid expression
if one of the parameter values is unknown, or when the input text is not a rich text.
Name | Type | Required | Description |
---|
The Sha1()
function hashes a specified text string with SHA1, and returns a hexadecimal text string.
SHA-1 is not considered secure, but some older systems still use this encryption. WEM supports this ONLY at your own risk, and ONLY to be used to integrate with other systems that provide no other way.
WIKI:
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Hashed values cannot be decoded, usually you check an incoming value against a known value that you hash yourself and check if both values are identical, to verify correctness without knowing the actual value.
Returns a hexadecimal text string.
Returns Unknown
if one of the parameter values is unknown or outside the common valid boundaries.
Name | Type | Required | Description |
---|
name
text
a text with the name of a project setting
file
file
the file of which the size has to be calculated
key
text
a text with the secret key for HmacSha256 encryption
message
text
the message or content
returnbase64
yes/no
return result as base64 (if true)
value1
any
Accepts any (at least one) number of values of the same type.
| text | a HTML text |
| text | a text |
The NameOf()
function returns the name of an item from the data model.
This function is SQL compatible. For more information about SQL compatibility, see our documentation.
Returns the name of an item from the data model (the value as entered in the Name-property of the data-model item).
Name | Type | Required | Description |
---|---|---|---|
The Base32ToText()
function decodes a base32 encoded string to a text value. Decoding is carried out using the UTF8 charset.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a base32 decoded text.
Returns [no value]
if one of the parameter values is unknown or not base32 encoded.
Name | Type | Required | Description |
---|---|---|---|
The Distance()
function returns the geographical distance (in kilometers - as the crow flies) between two points of (latitude
,longitude
).
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns the geographical distance (in kilometers - in a straight line) between two geographical points.
Returns Invalid expression
if one of the parameter values is not a valid number.
Name | Type | Required | Description |
---|---|---|---|
Function call | Result |
---|---|
The Abs()
function takes the absolute value of a number.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns an absolute number
Returns Invalid expression
if the parameter is not a valid number.
Name | Type | Required | Description |
---|---|---|---|
Function call | Result |
---|---|
The Cos()
calculates the cosine of a given radian value.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns cosine of number
Returns invalid expression
if the parameter has no value or is not a valid number.
Name | Type | Required | Description |
---|---|---|---|
Function call | Result |
---|---|
The FileName()
function returns the name of a file.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns the name of the file.
Returns Unknown
if the parameter value (file) is unknown.
Name | Type | Required | Description |
---|---|---|---|
The Pow()
function calculates a number to the power of another number.
The operator ^ can also be used to do power-calculation.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a number
.
Returns Invalid expression
if one of the parameter values is not a valid number, and returns unknown
if one of the parameters is unknown.
Name | Type | Required | Description |
---|---|---|---|
Function call | Result |
---|---|
The Log()
function calculates the natural logarithm (base e
) of a given number, or calculates the logarithm of a number by specified base.
Read .
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns the logarithm of a givennumber
, using base e
or a specified base number.
Returns Invalid expression
if one of the parameter values is not a valid number.
Name | Type | Required | Description |
---|
Function call | Result |
---|
Log(5) | 1.6094 |
Log(25, 5) | 2 |
Log(5, 25) | 0.5 |
number
numeric
a number
power
numeric
a number
Pow(1, 0)
1
Pow(0, 1)
0
Pow(2, 3)
8
Pow(0.5, -0.5)
1.4142135624
Pow(-0.5, 0.5)
NaN (not a number)
Pow(1234, 1234)
infinity
| numeric | a numeric value. |
| numeric | a numeric value. |
data-item
field
a field from your data model
text
text
a base32 encoded text
latitude1
numeric
a geographic coordinate that specifies the north–south position of a point on the Earth's surface in decimal degrees.
longtitude1
numeric
a geographic coordinate that specifies the east-west position of a point on the Earth's surface decimal degrees.
latitude2
numeric
a geographic coordinate that specifies the north–south position of a point on the Earth's surface in decimal degrees.
longtitude2
numeric
a geographic coordinate that specifies the east-west position of a point on the Earth's surface decimal degrees.
Distance(52.370216, 4.895168, -37.814, 14496332)
16545.7337
number
numeric
a number
Abs(123.456)
123.456
Abs(-123.456)
123.456
Abs(1.23456*10^6)
1234560
rad
numeric
a number given in unit of radians
cos(1)
0.5403023059
cos(Pi)
-1
cos(Pi/2)
0
file
file
the file
The Random()
generates a random number.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a random integral number between 0 or a minimum value, and a maximum value.
Returns Invalid expression
if one of the parameter values is not a valid number, or is a negative number, or when a maximum value is 0, or when a maximum value is less than a minimum value.
Name | Type | Required | Description |
---|---|---|---|
The ToNumber()
converts a value to a number.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Note: this function uses the language setting of a portal when converting text.
Returns the number converted from text
or a unit from date
.
Returns Invalid expression
when text
is not a number, or when reference
is not a valid RowId, or when date
is not a valid date value or unit
is not a valid date unit.
The Floor()
function rounds down to the closest integral number (integer number without decimals) smaller than or equal to the given number.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns the closest integral value that is smaller than or equal to number
.
Returns Invalid expression
if the parameter is not a valid number.
Name | Type | Required | Description |
---|
Function call | Result |
---|
The CreateJsonWebTokenH256()
function returns the HMAC-SHA256 encoded JWT () for given payload (json value) and secret (password text), using the standard JWT header {alg=HS256 and typ=JWT} or a custom header.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
JWT tokens are used in authentication (Single Sign On) contexts, and designed to be compact, URL-safe and secure. Sites like Google or Zoom use JWT. They may provide information on how to work with their JWT for sign-on (with code examples for PHP, Python or C#), and if it supports the standard implementation, you can use this WEM Function to create the proper JWT - just provide the proper values for the payload and the secret. For the extensive standard information behind standard JWT, read the wiki pages.
This WEM implementation is following the basic standards - some sites may have custom implementations that deviate and therefore may not work with the WEM implementation.
Returns a Json Web Token () using the HMAC-SHA265 algorithm.
Returns Unknown
if one of the parameter values is unknown or outside the common valid boundaries.
Name | Type | Required | Description |
---|
Name | Type | Required | Description |
---|
Generates a unique 256 bit AES key, to be used with the AES encryption and decryption functions.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
| text | a text containing a number. |
| reference | reference field, holding a rowid of a list. |
| date | a date. |
| text |
| text |
| text | Text or data field that holds the encryption secret. |
| yes/no | indicates whether the secret is base64 encoded (true) or plaintext (false) |
| text |
max_num
numeric
the maximum value of the generated number.
min_num
numeric
the minimum value of the generated number.
| numeric | a numeric value. |
Floor(5) | 5 |
Floor(5.999) | 5 |
Floor(-123.89) | -124 |
The AesDecrypt()
function decrypts a base64 encoded ciphertext to plaintext, using the given key and initialization vector.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Returns a plaintext.
Returns Unknown
if one of the parameter values is unknown or outside the common valid boundaries.
Name | Type | Required | Description |
---|---|---|---|
The Md5()
function hashes one or more text strings into one hexadecimal text value which is hashed using the MD5 algorithm.
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Hashed values cannot be decoded, usually you check an incoming value against a known value that you hash yourself and check if both values are identical, to verify correctness without knowing the actual value.
Returns a 128-bit hexadecimal representation of an MD5 hashed value.
Returns unknown
if one of the parameter values is unknown or outside the common valid boundaries.
Name | Type | Required | Description |
---|---|---|---|
The PasswordStrength()
function Calculates a numeric representation of the strength of a password from 0 (blank), 1 (very weak) up to 5 (very strong).
Combining different types of characters makes for stronger passwords, but a very long password of only lowercase characters (like a sentence) can also be strong.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns a number between 0 and 5.
0 - blank
1 - very weak
2 - weak
3 - medium
4 - strong
5 - very strong
The following factors increase the strength of a password:
Lowercase characters
Uppercase characters
Numbers
Symbols
Password length
The PBKDF2()
function creates a secure password hash for a password and a salt by using the PBKDF2 hashing algorithm with 1000 iterations.
WIKI:
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Hashed values cannot be decoded, usually you check an incoming value against a known value that you hash yourself and check if both values are identical, to verify correctness without knowing the actual value.
Returns a text that contains a hash key of 40 characters. Returns unknown if the salt length is less than 8
Name | Type | Required | Description |
---|
The Password()
function returns a text that contains a randomly generated strong password with a specified number of characters.
This function is NOT SQL compatible. For more information about SQL compatibility, see our .
Returns a text by default of 8 characters.
Returns Unknown
if one of the parameter values is unknown or outside the common valid boundaries.
Name | Type | Required | Description |
---|
the that is retrieved from date
.
A json-formed set of claims (see )
You can also use a custom header according to the .
Name | Type | Required | Description |
---|
| text | input password |
ciphertext
text
The input base64 encoded text which was encrypted you want to decrypt. It should be encrypted with the same key and vector values and using the AES algorithm.
key
text
Text or data field that holds the encryption key. A key can be generated using AesKey()
vector
text
Text or data field that holds the encryption vector. A proper Vector value can be generated using AesIv()
encoding with BOM
yes/no
enable or disable encoding with BOM.
text1
text
a text
text2
text
another text
file
file
a file
| text | text containing a password |
| text | a salt text. The value must be at least 8 characters long. An unknown value is returned if the length is less than 8. |
| numeric | a number representing the amount of characters of the generated password. Should be at least 4, higher is better. |
The Sha256()
function hashes a specified text string with SHA256, and returns a hexadecimal text string. This hash function is preferred to SHA-1, being more secure.
WIKI: http://en.wikipedia.org/wiki/SHA-2
This function is NOT SQL compatible. For more information about SQL compatibility, see our documentation.
Hashed values cannot be decoded, usually you check an incoming value against a known value that you hash yourself and check if both values are identical, to verify correctness without knowing the actual value.
Returns a hexadecimal text string.
Returns Unknown
if one of the parameter values is unknown or outside the common valid boundaries.
Name | Type | Required | Description |
---|---|---|---|
text
text
a text