From b77bed70172ae336c5a41e3ea3ece03c4e274bc2 Mon Sep 17 00:00:00 2001 From: rettenbe Date: Mon, 7 Apr 2008 08:10:41 +0000 Subject: [PATCH] like operator for db queries, closes 392 git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@10220 594d385d-05f5-0310-b6e9-bd551577e9d8 --- gosa-si/modules/GosaSupportDaemon.pm | 3 ++- gosa-si/tests/client.php | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/gosa-si/modules/GosaSupportDaemon.pm b/gosa-si/modules/GosaSupportDaemon.pm index de26b59b5..fe027fe17 100644 --- a/gosa-si/modules/GosaSupportDaemon.pm +++ b/gosa-si/modules/GosaSupportDaemon.pm @@ -36,6 +36,7 @@ my $op_hash = { 'gt' => '>', 'le' => '<=', 'lt' => '<', + 'like' => ' LIKE ', }; @@ -249,7 +250,7 @@ sub get_where_statement { if( exists $phrase->{'operator'} ) { my $op = $op_hash->{$phrase->{'operator'}[0]}; if( not defined $op ) { - &main::daemon_log("ERROR: Can not translate operator '$operator' in where ". + &main::daemon_log("ERROR: Can not translate operator '$operator' in where-". "statement to sql valid syntax. Please use 'eq', ". "'ne', 'ge', 'gt', 'le', 'lt' in xml message\n", 1); &main::daemon_log($msg, 8); diff --git a/gosa-si/tests/client.php b/gosa-si/tests/client.php index e3d7a1d7d..07b6af72c 100755 --- a/gosa-si/tests/client.php +++ b/gosa-si/tests/client.php @@ -17,7 +17,7 @@ if($sock->connected()){ # jobdb add #$data = "
gosa_network_completition
GOSAGOSAws-muc-2
"; -#$data = "
job_sayHello
10.89.1.155:2008300:1B:77:04:8A:6C 20130102133900
"; +#$data = "
job_sayHello
10.89.1.155:2008300:01:6c:9d:b9:fa00:1B:77:04:8A:6C 20130102133900
"; #$data = "
job_ping
GOSA 00:01:6c:9d:b9:fa 00:01:6c:9d:b9:fa19700101000000
"; @@ -36,6 +36,7 @@ if($sock->connected()){ # jobdb query #$data = "
gosa_query_jobdb
GOSA GOSAandgt0le5
"; +#$data = "
gosa_query_jobdb
GOSA GOSA like %0102%
"; #$data= "
gosa_query_jobdb
GOSA GOSAping03
"; #$data= "
gosa_query_jobdb
GOSA GOSAtrigger_action_reinstall025timestamp DESC
"; #$data= "
gosa_query_jobdb
GOSA GOSA
"; @@ -80,7 +81,7 @@ if($sock->connected()){ ################ # logHandling.pm -$data = "
gosa_show_log_by_mac
GOSA GOSA 00:01:6c:9d:b9:fa
"; +#$data = "
gosa_show_log_by_mac
GOSA GOSA 00:01:6c:9d:b9:fa
"; -- 2.30.2