]> git.joonet.de Git - adminer.git/commitdiff
Move apply_sql_function
authorjakubvrana <jakubvrana@7c3ca157-0c34-0410-bff1-cbf682f78f5c>
Tue, 18 Aug 2009 09:19:54 +0000 (09:19 +0000)
committerjakubvrana <jakubvrana@7c3ca157-0c34-0410-bff1-cbf682f78f5c>
Tue, 18 Aug 2009 09:19:54 +0000 (09:19 +0000)
git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@976 7c3ca157-0c34-0410-bff1-cbf682f78f5c

adminer/include/functions.inc.php
adminer/select.inc.php

index fd4998349a73d4fd4494faeaa56336de308bd485..a0e297bdcb494329e8a7c681366fb1423af786cc 100644 (file)
@@ -359,6 +359,10 @@ function dump_csv($row) {
        echo implode(",", $row) . "\n";
 }
 
+function apply_sql_function($function, $column) {
+       return ($function ? ($function == "count distinct" ? "COUNT(DISTINCT " : strtoupper("$function(")) . "$column)" : $column);
+}
+
 function is_email($email) {
        $atom = '[-a-z0-9!#$%&\'*+/=?^_`{|}~]'; // characters of local-name
        $domain = '[a-z0-9]([-a-z0-9]{0,61}[a-z0-9])'; // one domain component
index d112766483d5865fbbe3774a93124b7de30a4b79..2f2eacbe45e251db5b559e591b798223522fab96 100644 (file)
@@ -16,13 +16,6 @@ foreach ($fields as $key => $field) {
        $rights += $field["privileges"];
 }
 
-function apply_sql_function($function, $column) {
-       return ($function
-               ? ($function == "count distinct" ? "COUNT(DISTINCT " : strtoupper("$function(")) . "$column)"
-               : $column
-       );
-}
-
 list($select, $group) = $adminer->selectColumnsProcess($columns, $indexes);
 $where = $adminer->selectSearchProcess($fields, $indexes);
 $order = $adminer->selectOrderProcess($fields, $indexes);