I have this query to check the application version
AppInventory_CL
| extend AppVersion_s_Dyn = split(AppVersion_s, '.')
| extend Versione = iif(toint(AppVersion_s_Dyn[0]) >= 5
and toint(AppVersion_s_Dyn[1]) >= 2
and toint(AppVersion_s_Dyn[2]) >= 7, 'OK', 'KO')
But I need that also superior versions such as 6.0.5 is OK. How can I do that? Thanks
Presuming the versions are well formatted, you might want to use the
parse_version
function?See https://learn.microsoft.com/en-us/azure/data-explorer/kusto/query/parse-versionfunction
where that function might do what you want, and then you can use standard equals/greater than operators on the version strings?
edit: from a deleted answer that should have been a comment:
if you look at the examples from the link, you wouldn't use the big numbers even if that's what it prints out if you use it in a query, you'd use
parse_version
on both sides of the operator:basically, let the
parse_version
do its internal things, and don't directly use the values it returns