ct_int(Value 1, base=10)
Parameter | Description | Type | Required | Default Value | Value Range |
data | Numeric value or string that can be converted to a numeric value | number | Yes | - | - |
base | Base | number | No | 10 | [2-36] |
{"field1": "10"}
fields_set("result", ct_int(v("field1")))
{"result":"10","field1":"10"}
{"field1": "AB"}
fields_set("result", ct_int(v("field1"), 16))
{"result":"171","field1":"AB"}
ct_float(Value)
Parameter | Description | Type | Required | Default Value | Value Range |
data | Numeric value or string that can be converted to a numeric value | number | Yes | - | - |
{"field1": "123"}
fields_set("result", ct_float(v("field1")))
{"result":"123.0","field1":"123"}
ct_str(Value)
Parameter | Description | Type | Required | Default Value | Value Range |
data | Numeric value or string that can be converted to a numeric value | number | Yes | - | - |
{"field1": 123}
fields_set("result", ct_str(v("field1")))
{"result":"123","field1":"123"}
ct_bool(Value)
Parameter | Description | Type | Required | Default Value | Value Range |
data | Numeric value or string that can be converted to a numeric value | number | Yes | - | - |
{}
fields_set("result", ct_bool(0))
{"result":"false"}
{}
fields_set("result", ct_bool(1))
{"result":"true"}
{"field1": 1}
fields_set("result", ct_bool(v("field1")))
{"result":"true","field1":"1"}
Was this page helpful?