Hi team,
while generating (csv) report using the GitHub - opensearch-project/dashboards-reports: Export and automate PNG, PDF, and CSV reports in OpenSearch Dashboards plugin the timestamp field which contains seconds (and in some cases, this is quite important to also include seconds) short them to .00 only. I didn’t manage to find any comment which explains why there is such a format (cut) of seconds while doing the export.
Please, could someone let me know if there is a configuration I’m missing that will allow seconds on datetime or that is already part of the plugin and can’t be changed but rather implemented on the plugin directly?
Best regards,
hey @GezimSejdiu - could you give an example of the output that you’re describing?
Hi @searchymcsearchface ,
sure. The records/search contain @timestamp: Jul 5, 2021 @ 17:06:16.177
and when generating the report (csv) it removes the seconds/milisec. : 07/05/2021 3:06:00 pm
.
We can reproduce with any data which contains timesteps with seconds and just export as CSV.
Feel free to let me know if you need more info e.g. how we an reproduce it.
Best regards,
That sounds like a ‘feature’ rather than a ‘bug’ (but still bad!). I’m guessing that the reporting plugin is formatting with a specific template that just doesn’t include decimalized seconds.
I would create an issue for that on the repo for that.
@reporting-team - want to weigh in?
1 Like
@searchymcsearchface Sure, I can also create the issue in repo.
2 Likes
@GezimSejdiu Hi
This is indeed an issue. The root cause is in the code, we are using the date_hour_minute
format for date field value rendering(querying from engine). But this is not a good choice. We have the following format as available options
We should at least use date_hour_mintue_seconds
. And as you pointed out, it also makes sense to add the last 3 digits fraction of seconds, which is date_hour_minute_second_fraction
2 Likes
Cool. Thanks a lot @CyberGod (cc:/ @searchymcsearchface ) for your prompt reply and creating the issue on GitHub. Looking forward to the fix.
Thank you.
1 Like