Private GIT

Skip to content
Snippets Groups Projects
Commit 37d11936 authored by Quentin Garnier's avatar Quentin Garnier
Browse files

Bug #1834

Host overview doesn't sort IP Addresses not naturally

git-svn-id: http://svn.centreon.com/trunk/centreon@13383 6bcd3966-0018-0410-8128-fd23d134de7e
parent 97182371
No related branches found
No related tags found
No related merge requests found
...@@ -188,7 +188,8 @@ ...@@ -188,7 +188,8 @@
$rq1 .= " ORDER BY h.check_attempt ". $order.",h.name "; $rq1 .= " ORDER BY h.check_attempt ". $order.",h.name ";
break; break;
case 'ip' : case 'ip' :
$rq1 .= " ORDER BY inet_aton(h.address) ". $order.",h.name "; # Not SQL portable
$rq1 .= " ORDER BY IFNULL(inet_aton(h.address), h.address) ". $order.",h.name ";
break; break;
case 'plugin_output' : case 'plugin_output' :
$rq1 .= " ORDER BY h.output ". $order.",h.name "; $rq1 .= " ORDER BY h.output ". $order.",h.name ";
......
...@@ -191,7 +191,8 @@ ...@@ -191,7 +191,8 @@
$rq1 .= " order by nhs.current_check_attempt ". $order.",no.name1 "; $rq1 .= " order by nhs.current_check_attempt ". $order.",no.name1 ";
break; break;
case 'ip' : case 'ip' :
$rq1 .= " order by inet_aton(nh.address) ". $order.",no.name1 "; # Not SQL portable
$rq1 .= " order by IFNULL(inet_aton(nh.address), nh.address) ". $order.",no.name1 ";
break; break;
case 'plugin_output' : case 'plugin_output' :
$rq1 .= " order by nhs.output ". $order.",no.name1 "; $rq1 .= " order by nhs.output ". $order.",no.name1 ";
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment