typeof()

Table of Contents

Definition

typeof() takes a value as an argument and returns the data type of that argument.

Examples

The following example returns "Number" for 'number' column, "String" for 'string' column, and "Boolean" for 'boolean' column.

| makeresults
| eval number=typeof(24)
| eval string=typeof("Hello World")
| eval boolean=typeof(1==2)
Screenshot of the previous example’s result

Further Reading