-
Problem report
-
Resolution: False Positive
-
Trivial
-
None
-
7.4.0beta1 (master)
-
None
In db_read_values_by_count (src/libs/zbxhistory/history_sql.c), I noticed that the query ordering is specified as
zbx_strcpy_alloc(&sql, &sql_alloc, &sql_offset, " order by clock desc");
However this means that values occurring within the same second are returned in an unspecified order, even though the order within the second is known (ns field). Shouldn't it be
zbx_strcpy_alloc(&sql, &sql_alloc, &sql_offset, " order by clock desc, ns desc");
?
Rummaging around in the same source file, it seems that db_read_values_by_time_and_count has the same issue.