Functions Supported in Data Engine Syntax

Data Engine Syntax mode supports the following functions:

Numeric Functions

Formula Mode supports the Elasticsearch Math API (see Elasticsearch Math API reference).

Text Functions

Formula Mode supports the Elasticsearch Text API (see Elasticsearch Text API reference).

Date Functions

Supported date functions include:

now 
dateFormat 
dateParse 
dateAdd 
dateSubtract 
dateDiff 
dateIsNull 

Using dateFormat to display dates and times

The dateFormat function enables you to determine how to display the date and time. See for example the following function:

dateFormat("07/04/2001", "EEE, MMM d, ‘’yy")

The above function returns the following format:

Wed, Jul 4, ‘01

Note:You may use single or double quotes around the format string.

Note:All dates are treated as GMT.

The following table lists the formatting arguments:

Date and Time Patterns

Letter

Date or Time Component

Presentation

Examples

G

Era designator

Text

AD

y, Y

Year

Year

1996; 96

M

Month in year

Month

July; Jul; 07

w

Week in year

Number

27

W

Week in month

Number

2

D

Day in year

Number

189

d

Day in month

Number

10

F

Day of week in month

Number

2

E

Day name in week

Text

Tuesday; Tue

e

Day number of week (1 = Monday, ..., 7 = Sunday)

Number

1

a

AM/PM marker

Text

PM

H

Hour in day (0-23)

Number

0

k

Hour in day (1-24)

Number

24

K

Hour in AM/PM (0-11)

Number

0

h

Hour in AM/PM (1-12)

Number

12

m

Minute in hour

Number

30

s

Second in minute

Number

55

S

Millisecond

Number

978

z

Time zone

General time zone

PST; GMT-08:00

Z

Time zone

RFC 822 time zone

-0800

x

Time zone

iso 8601 time zone

-08; -0800; -08:00