Treki
December 8, 2020, 12:03am
1
Hello,
we have strings in the format "2020-11-10T12:43:58" saved in Kibana.
When using ES SQL, we want to convert these strings into an integer or float so that the integer/float increases as the DateTime increases as well.
For example:
"2020-01-01T00:00:00" → 1
"2020-01-01T00:01:00" → 2
"2020-01-03T00:01:00" → 100
We want to add this new column to our SQL search result.
How can we do this?
Can someone show us an example, please?
With best regards
AClerk
December 8, 2020, 3:49am
2
What is the logic for numbering?
What is business use?
When you say ESQL, that is in Canvas workpad?
Please provide some more details.
Treki
December 8, 2020, 2:15pm
3
We have significant issues ordering our data table in the Canvas workpad accordingly to the timestamps.
I explain the full problem here: Link
If this problem is solved then we are happy and we can continue our work.
In order to make the data table only present elements which lie between two dates, we thought to take these steps:
Adjust the ES SQL code so that the preview of the result is what we would like to get
We add an additional column so that timestamp1 and timestamp2 (timestamp1 < timestamp2) are getting numbers which are number1<number2
In the expression editor, we set 'filterColumn' to the column, which we created at step 2
We hope that you understand our request.
We just want to filter our data table according to a given timespan.
With best regards
system
(system)
Closed
January 5, 2021, 2:15pm
4
This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.