Details
-
Bug
-
Status: Closed (View Workflow)
-
TBD
-
Resolution: Cannot Reproduce
-
34.0.0
-
None
-
None
-
CP: Sprint 148
-
1
-
Core: Platform
-
TBD
Description
Overview:
In scope of ticket MDEXP-556 it was found that at Morning Glory bugfest environment sorting mechanism by field total provide wrong result for job executions.
Data export job execution records are ordered in the alphabetical order by total value. But they should be sorted in the numeric order.
The data of sorting is provided by mod-data-export module.
The same behavior is reproduced locally:
CQL used:
(status=(COMPLETED OR COMPLETED_WITH_ERRORS OR FAIL)) sortby progress.total/sort.descending completedDate/sort.descending
In debug mode of mod-data-export module that was build from master branch was retrieved sql to get job executions:
SELECT * FROM diku_mod_data_export.job_executions WHERE ((get_tsvector(f_unaccent(job_executions.jsonb->>'status')) @@ tsquery_phrase(f_unaccent('COMPLETED'))) OR (get_tsvector(f_unaccent(job_executions.jsonb->>'status')) @@ tsquery_phrase(f_unaccent('COMPLETED_WITH_ERRORS')))) OR (get_tsvector(f_unaccent(job_executions.jsonb->>'status')) @@ tsquery_phrase(f_unaccent('FAIL'))) ORDER BY left(lower(f_unaccent(job_executions.jsonb->'progress'->>'total')),600) DESC, lower(f_unaccent(job_executions.jsonb->'progress'->>'total')) DESC, left(lower(f_unaccent(job_executions.jsonb->>'completedDate')),600) DESC, lower(f_unaccent(job_executions.jsonb->>'completedDate')) DESC LIMIT 100 OFFSET 0
Sql provides ordering result by job_executions.jsonb->'progress'->>'total' as string. The logic that responsible for sql generation is part of RMB 34.0.0.
Steps to Reproduce:
Are described in scope of MDEXP-556
Expected Results:
The records are ordered in the numeric order (1, 2, 15, 23)
Actual Results:
The records are ordered in the alphabetical order (1, 15, 2, 23)
TestRail: Results
Attachments
Issue Links
- blocks
-
UIDEXP-289 Numeric values are sorted alphabetically on View all logs form
-
- Closed
-