Merge branch 'master' of github.com:phpmyadmin/phpmyadmin
This commit is contained in:
commit
beda4577c7
@ -23,6 +23,7 @@ phpMyAdmin - ChangeLog
|
||||
4.0.5.0 (not yet released)
|
||||
- bug #3977 Not detected configuration storage
|
||||
- bug #3970 Pressing enter in the filter field reloads page
|
||||
- bug #3984 Cannot insert in this table (PHP < 5.4)
|
||||
|
||||
4.0.4.0 (not yet released)
|
||||
- bug #3959 Using DefaultTabDatabase in NavigationTree for Database Click
|
||||
|
||||
@ -16,20 +16,6 @@ if (! PMA_DRIZZLE) {
|
||||
}
|
||||
require 'libraries/build_html_for_db.lib.php';
|
||||
|
||||
/**
|
||||
* Sets globals from $_POST
|
||||
*/
|
||||
$post_params = array(
|
||||
'new_db'
|
||||
);
|
||||
foreach ($post_params as $one_post_param) {
|
||||
if (isset($_POST[$one_post_param])) {
|
||||
$GLOBALS[$one_post_param] = $_POST[$one_post_param];
|
||||
}
|
||||
}
|
||||
|
||||
PMA_Util::checkParameters(array('new_db'));
|
||||
|
||||
/**
|
||||
* Defines the url to return to in case of error in a sql statement
|
||||
*/
|
||||
@ -38,7 +24,7 @@ $err_url = 'index.php?' . PMA_generate_common_url();
|
||||
/**
|
||||
* Builds and executes the db creation sql query
|
||||
*/
|
||||
$sql_query = 'CREATE DATABASE ' . PMA_Util::backquote($new_db);
|
||||
$sql_query = 'CREATE DATABASE ' . PMA_Util::backquote($_POST['new_db']);
|
||||
if (! empty($_POST['db_collation'])) {
|
||||
list($db_charset) = explode('_', $_POST['db_collation']);
|
||||
if (in_array($db_charset, $mysql_charsets)
|
||||
@ -72,8 +58,8 @@ if (! $result) {
|
||||
}
|
||||
} else {
|
||||
$message = PMA_Message::success(__('Database %1$s has been created.'));
|
||||
$message->addParam($new_db);
|
||||
$GLOBALS['db'] = $new_db;
|
||||
$message->addParam($_POST['new_db']);
|
||||
$GLOBALS['db'] = $_POST['new_db'];
|
||||
|
||||
/**
|
||||
* If in an Ajax request, build the output and send it
|
||||
@ -89,11 +75,11 @@ if (! $result) {
|
||||
* @global array $GLOBALS['db_url_params']
|
||||
* @name $db_url_params
|
||||
*/
|
||||
$db_url_params['db'] = $new_db;
|
||||
$db_url_params['db'] = $_POST['new_db'];
|
||||
|
||||
$is_superuser = $GLOBALS['dbi']->isSuperuser();
|
||||
$column_order = PMA_getColumnOrder();
|
||||
$url_query = PMA_generate_common_url($new_db);
|
||||
$url_query = PMA_generate_common_url($_POST['new_db']);
|
||||
|
||||
/**
|
||||
* String that will contain the output HTML
|
||||
@ -108,7 +94,7 @@ if (! $result) {
|
||||
// $dbstats comes from the create table dialog
|
||||
if (! empty($dbstats)) {
|
||||
$current = array(
|
||||
'SCHEMA_NAME' => $new_db,
|
||||
'SCHEMA_NAME' => $_POST['new_db'],
|
||||
'DEFAULT_COLLATION_NAME' => $db_collation_for_ajax,
|
||||
'SCHEMA_TABLES' => '0',
|
||||
'SCHEMA_TABLE_ROWS' => '0',
|
||||
@ -120,7 +106,7 @@ if (! $result) {
|
||||
);
|
||||
} else {
|
||||
$current = array(
|
||||
'SCHEMA_NAME' => $new_db
|
||||
'SCHEMA_NAME' => $_POST['new_db']
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@ -421,9 +421,9 @@ if ($onfly_compression) {
|
||||
$memory_limit = (int)$memory_limit;
|
||||
}
|
||||
|
||||
// Some of memory is needed for other thins and as treshold.
|
||||
// Nijel: During export I had allocated (see memory_get_usage function)
|
||||
// approx 1.2MB so this comes from that.
|
||||
// Some of memory is needed for other things and as threshold.
|
||||
// During export I had allocated (see memory_get_usage function)
|
||||
// approx 1.2MB so this comes from that.
|
||||
if ($memory_limit > 1500000) {
|
||||
$memory_limit -= 1500000;
|
||||
}
|
||||
|
||||
@ -571,7 +571,7 @@ if (isset($message)) {
|
||||
// (but if the query is too large, in case of an imported file, the parser
|
||||
// can choke on it so avoid parsing)
|
||||
if (strlen($sql_query) <= $GLOBALS['cfg']['MaxCharactersInDisplayedSQL']) {
|
||||
include_once 'libraries/parse_analyze.lib.php';
|
||||
include_once 'libraries/parse_analyze.inc.php';
|
||||
}
|
||||
|
||||
// There was an error?
|
||||
|
||||
@ -405,7 +405,7 @@ if ($server != 0
|
||||
}
|
||||
|
||||
/**
|
||||
* Nijel: As we try to handle charsets by ourself, mbstring overloads just
|
||||
* As we try to handle charsets by ourself, mbstring overloads just
|
||||
* break it, see bug 1063821.
|
||||
*/
|
||||
if (@extension_loaded('mbstring') && @ini_get('mbstring.func_overload') > 1) {
|
||||
@ -420,7 +420,7 @@ if (@extension_loaded('mbstring') && @ini_get('mbstring.func_overload') > 1) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Nijel: mbstring is used for handling multibyte inside parser, so it is good
|
||||
* mbstring is used for handling multibyte inside parser, so it is good
|
||||
* to tell user something might be broken without it, see bug #1063149.
|
||||
*/
|
||||
if (! @extension_loaded('mbstring')) {
|
||||
|
||||
@ -4037,7 +4037,7 @@ class PMA_Util
|
||||
|
||||
if (! $escapeHtml) {
|
||||
foreach ($values as $key => $value) {
|
||||
$values[$key] = html_entity_decode($value, ENT_QUOTES);
|
||||
$values[$key] = html_entity_decode($value, ENT_QUOTES, 'UTF-8');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -27,12 +27,49 @@ $analyzed_sql = PMA_SQP_analyze($parsed_sql);
|
||||
// PRIMARY KEY (`id`)
|
||||
// )
|
||||
|
||||
// Fills some variables from the analysed SQL
|
||||
// A table has to be created, renamed, dropped -> navi frame should be reloaded
|
||||
$reload = isset($analyzed_sql[0]['queryflags']['reload']);
|
||||
|
||||
// check for drop database
|
||||
$drop_database = isset($analyzed_sql[0]['queryflags']['drop_database']);
|
||||
|
||||
// for the presence of EXPLAIN
|
||||
$is_explain = isset($analyzed_sql[0]['queryflags']['is_explain']);
|
||||
|
||||
// for the presence of DELETE
|
||||
$is_delete = isset($analyzed_sql[0]['queryflags']['is_delete']);
|
||||
|
||||
// for the presence of UPDATE, DELETE or INSERT|LOAD DATA|REPLACE
|
||||
$is_affected = isset($analyzed_sql[0]['queryflags']['is_affected']);
|
||||
|
||||
// for the presence of REPLACE
|
||||
$is_replace = isset($analyzed_sql[0]['queryflags']['is_replace']);
|
||||
|
||||
// for the presence of INSERT
|
||||
$is_insert = isset($analyzed_sql[0]['queryflags']['is_insert']);
|
||||
|
||||
// for the presence of CHECK|ANALYZE|REPAIR|OPTIMIZE TABLE
|
||||
$is_maint = isset($analyzed_sql[0]['queryflags']['is_maint']);
|
||||
|
||||
// for the presence of SHOW
|
||||
$is_show = isset($analyzed_sql[0]['queryflags']['is_show']);
|
||||
|
||||
// for the presence of PRRCEDURE ANALYSE
|
||||
$is_analyse = isset($analyzed_sql[0]['queryflags']['is_analyse']);
|
||||
|
||||
// for the presence of INTO OUTFILE
|
||||
$is_export = isset($analyzed_sql[0]['queryflags']['is_export']);
|
||||
|
||||
// for the presence of GROUP BY|HAVING|SELECT DISTINCT
|
||||
$is_group = isset($analyzed_sql[0]['queryflags']['is_group']);
|
||||
|
||||
// for the presence of SUM|AVG|STD|STDDEV|MIN|MAX|BIT_OR|BIT_AND
|
||||
$is_func = isset($analyzed_sql[0]['queryflags']['is_func']);
|
||||
|
||||
// for the presence of SELECT COUNT
|
||||
$is_count = isset($analyzed_sql[0]['queryflags']['is_count']);
|
||||
|
||||
// check for a real SELECT ... FROM
|
||||
$is_select = isset($analyzed_sql[0]['queryflags']['select_from']);
|
||||
|
||||
@ -59,7 +96,7 @@ if ($is_select) {
|
||||
} else {
|
||||
$db = $prev_db;
|
||||
}
|
||||
// Nijel: don't change reload, if we already decided to reload in import
|
||||
// Don't change reload, if we already decided to reload in import
|
||||
if (empty($reload) && empty($GLOBALS['is_ajax_request'])) {
|
||||
$reload = ($db == $prev_db) ? 0 : 1;
|
||||
}
|
||||
@ -9,51 +9,6 @@ if (!defined('PHPMYADMIN')) {
|
||||
exit;
|
||||
}
|
||||
|
||||
/**
|
||||
* Initialize some parameters needed to display results
|
||||
*
|
||||
* @param string $sql_query SQL statement
|
||||
* @param boolean $is_select select query or not
|
||||
*
|
||||
* @return array set of parameters
|
||||
*
|
||||
* @access public
|
||||
*/
|
||||
function PMA_getDisplayPropertyParams($sql_query, $is_select)
|
||||
{
|
||||
$is_explain = $is_count = $is_export = $is_delete = $is_insert = $is_affected = $is_show = $is_maint = $is_analyse = $is_group = $is_func = $is_replace = false;
|
||||
|
||||
if ($is_select) {
|
||||
$is_group = preg_match('@(GROUP[[:space:]]+BY|HAVING|SELECT[[:space:]]+DISTINCT)[[:space:]]+@i', $sql_query);
|
||||
$is_func = ! $is_group && (preg_match('@[[:space:]]+(SUM|AVG|STD|STDDEV|MIN|MAX|BIT_OR|BIT_AND)\s*\(@i', $sql_query));
|
||||
$is_count = ! $is_group && (preg_match('@^SELECT[[:space:]]+COUNT\((.*\.+)?.*\)@i', $sql_query));
|
||||
$is_export = preg_match('@[[:space:]]+INTO[[:space:]]+OUTFILE[[:space:]]+@i', $sql_query);
|
||||
$is_analyse = preg_match('@[[:space:]]+PROCEDURE[[:space:]]+ANALYSE@i', $sql_query);
|
||||
} elseif (preg_match('@^EXPLAIN[[:space:]]+@i', $sql_query)) {
|
||||
$is_explain = true;
|
||||
} elseif (preg_match('@^DELETE[[:space:]]+@i', $sql_query)) {
|
||||
$is_delete = true;
|
||||
$is_affected = true;
|
||||
} elseif (preg_match('@^(INSERT|LOAD[[:space:]]+DATA|REPLACE)[[:space:]]+@i', $sql_query)) {
|
||||
$is_insert = true;
|
||||
$is_affected = true;
|
||||
if (preg_match('@^(REPLACE)[[:space:]]+@i', $sql_query)) {
|
||||
$is_replace = true;
|
||||
}
|
||||
} elseif (preg_match('@^UPDATE[[:space:]]+@i', $sql_query)) {
|
||||
$is_affected = true;
|
||||
} elseif (preg_match('@^[[:space:]]*SHOW[[:space:]]+@i', $sql_query)) {
|
||||
$is_show = true;
|
||||
} elseif (preg_match('@^(CHECK|ANALYZE|REPAIR|OPTIMIZE)[[:space:]]+TABLE[[:space:]]+@i', $sql_query)) {
|
||||
$is_maint = true;
|
||||
}
|
||||
|
||||
return array(
|
||||
$is_group, $is_func, $is_count, $is_export, $is_analyse, $is_explain,
|
||||
$is_delete, $is_affected, $is_insert, $is_replace,$is_show, $is_maint
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the database name inside a USE query
|
||||
*
|
||||
@ -136,7 +91,7 @@ function getTableHtmlForMultipleQueries(
|
||||
$querytime_before = array_sum(explode(' ', microtime()));
|
||||
|
||||
// Assignment for variable is not needed since the results are
|
||||
// looiping using the connection
|
||||
// looping using the connection
|
||||
@$GLOBALS['dbi']->tryMultiQuery($multi_sql);
|
||||
|
||||
$querytime_after = array_sum(explode(' ', microtime()));
|
||||
@ -162,25 +117,22 @@ function getTableHtmlForMultipleQueries(
|
||||
$databases_array
|
||||
);
|
||||
}
|
||||
$parsed_sql = PMA_SQP_parse($sql_data['valid_sql'][$sql_no]);
|
||||
|
||||
$table = PMA_getTableNameBySQL(
|
||||
$sql_data['valid_sql'][$sql_no],
|
||||
$tables_array
|
||||
);
|
||||
|
||||
$analyzed_sql = PMA_SQP_analyze($parsed_sql);
|
||||
$is_select = isset($analyzed_sql[0]['queryflags']['select_from']);
|
||||
// for the use of the parse_analyze.inc.php
|
||||
$sql_query = $sql_data['valid_sql'][$sql_no];
|
||||
|
||||
// Parse and analyze the query
|
||||
require 'libraries/parse_analyze.inc.php';
|
||||
|
||||
$unlim_num_rows = PMA_Table::countRecords($db, $table, true);
|
||||
$showtable = PMA_Table::sGetStatusInfo($db, $table, null, true);
|
||||
$url_query = PMA_generate_common_url($db, $table);
|
||||
|
||||
list($is_group, $is_func, $is_count, $is_export, $is_analyse,
|
||||
$is_explain, $is_delete, $is_affected, $is_insert, $is_replace,
|
||||
$is_show, $is_maint)
|
||||
= PMA_getDisplayPropertyParams(
|
||||
$sql_data['valid_sql'][$sql_no], $is_select
|
||||
);
|
||||
|
||||
|
||||
// Handle remembered sorting order, only for single table query
|
||||
if ($GLOBALS['cfg']['RememberSorting']
|
||||
&& ! ($is_count || $is_export || $is_func || $is_analyse)
|
||||
|
||||
@ -982,6 +982,22 @@ function PMA_SQP_analyze($arr)
|
||||
* ['queryflags']['join'] = 1; for a JOIN
|
||||
* ['queryflags']['offset'] = 1; for the presence of OFFSET
|
||||
* ['queryflags']['procedure'] = 1; for the presence of PROCEDURE
|
||||
* ['queryflags']['is_explain'] = 1; for the presence of EXPLAIN
|
||||
* ['queryflags']['is_delete'] = 1; for the presence of DELETE
|
||||
* ['queryflags']['is_affected'] = 1; for the presence of UPDATE, DELETE
|
||||
* or INSERT|LOAD DATA|REPLACE
|
||||
* ['queryflags']['is_replace'] = 1; for the presence of REPLACE
|
||||
* ['queryflags']['is_insert'] = 1; for the presence of INSERT
|
||||
* ['queryflags']['is_maint'] = 1; for the presence of CHECK|ANALYZE
|
||||
* |REPAIR|OPTIMIZE TABLE
|
||||
* ['queryflags']['is_show'] = 1; for the presence of SHOW
|
||||
* ['queryflags']['is_analyse'] = 1; for the presence of PRRCEDURE ANALYSE
|
||||
* ['queryflags']['is_export'] = 1; for the presence of INTO OUTFILE
|
||||
* ['queryflags']['is_group'] = 1; for the presence of GROUP BY|HAVING|
|
||||
* SELECT DISTINCT
|
||||
* ['queryflags']['is_func'] = 1; for the presence of SUM|AVG|STD|STDDEV
|
||||
* |MIN|MAX|BIT_OR|BIT_AND
|
||||
* ['queryflags']['is_count'] = 1; for the presence of SELECT COUNT
|
||||
*
|
||||
* query clauses
|
||||
* -------------
|
||||
@ -1587,10 +1603,33 @@ function PMA_SQP_analyze($arr)
|
||||
$subresult['querytype'] = $upper_data;
|
||||
$seen_reserved_word = true;
|
||||
|
||||
if ($first_reserved_word=='SELECT') {
|
||||
if ($first_reserved_word == 'SELECT') {
|
||||
$position_of_first_select = $i;
|
||||
}
|
||||
}
|
||||
|
||||
if ($first_reserved_word == 'EXPLAIN') {
|
||||
$subresult['queryflags']['is_explain'] = 1;
|
||||
}
|
||||
|
||||
if ($first_reserved_word == 'DELETE') {
|
||||
$subresult['queryflags']['is_delete'] = 1;
|
||||
$subresult['queryflags']['is_affected'] = 1;
|
||||
}
|
||||
|
||||
if ($first_reserved_word == 'UPDATE') {
|
||||
$subresult['queryflags']['is_affected'] = 1;
|
||||
}
|
||||
|
||||
if ($first_reserved_word == 'REPLACE') {
|
||||
$subresult['queryflags']['is_replace'] = 1;
|
||||
}
|
||||
|
||||
if ($first_reserved_word == 'SHOW') {
|
||||
$subresult['queryflags']['is_show'] = 1;
|
||||
}
|
||||
|
||||
} else {
|
||||
// for the presence of DROP DATABASE
|
||||
if ($first_reserved_word == 'DROP' && $upper_data == 'DATABASE') {
|
||||
$subresult['queryflags']['drop_database'] = 1;
|
||||
}
|
||||
@ -1602,6 +1641,21 @@ function PMA_SQP_analyze($arr)
|
||||
) {
|
||||
$subresult['queryflags']['reload'] = 1;
|
||||
}
|
||||
|
||||
// for the presence of INSERT|LOAD DATA
|
||||
if (in_array($first_reserved_word, array("INSERT", "LOAD"))
|
||||
&& $upper_data == 'REPLACE'
|
||||
) {
|
||||
$subresult['queryflags']['is_insert'] = 1;
|
||||
$subresult['queryflags']['is_affected'] = 1;
|
||||
}
|
||||
|
||||
// for the presence of CHECK|ANALYZE|REPAIR|OPTIMIZE TABLE
|
||||
if (in_array($first_reserved_word, array("CHECK","ANALYZE","REPAIR","OPTIMIZE"))
|
||||
&& $upper_data == 'TABLE'
|
||||
) {
|
||||
$subresult['queryflags']['is_maint'] = 1;
|
||||
}
|
||||
}
|
||||
|
||||
if ($upper_data == 'LIMIT' && ! $in_subquery) {
|
||||
@ -1616,6 +1670,27 @@ function PMA_SQP_analyze($arr)
|
||||
$subresult['queryflags']['procedure'] = 1;
|
||||
$in_limit = false;
|
||||
$after_limit = true;
|
||||
|
||||
// for the presnece of PROCEDURE ANALYSE
|
||||
if (isset($subresult['queryflags']['select_from'])
|
||||
&& $subresult['queryflags']['select_from'] == 1
|
||||
&& ($i + 1) < $size
|
||||
&& $arr[$i + 1]['type'] == 'alpha_reservedWord'
|
||||
&& strtoupper($arr[$i + 1]['data']) == 'ANALYSE'
|
||||
) {
|
||||
$subresult['queryflags']['is_analyse'] = 1;
|
||||
}
|
||||
}
|
||||
|
||||
// for the presnece of INTO OUTFILE
|
||||
if ($upper_data == 'INTO'
|
||||
&& isset($subresult['queryflags']['select_from'])
|
||||
&& $subresult['queryflags']['select_from'] == 1
|
||||
&& ($i + 1) < $size
|
||||
&& $arr[$i + 1]['type'] == 'alpha_reservedWord'
|
||||
&& strtoupper($arr[$i + 1]['data']) == 'OUTFILE'
|
||||
) {
|
||||
$subresult['queryflags']['is_export'] = 1;
|
||||
}
|
||||
/**
|
||||
* @todo set also to false if we find FOR UPDATE or LOCK IN SHARE MODE
|
||||
@ -1623,7 +1698,19 @@ function PMA_SQP_analyze($arr)
|
||||
if ($upper_data == 'SELECT') {
|
||||
$in_select_expr = true;
|
||||
$select_expr_clause = '';
|
||||
|
||||
// for the presence of SELECT COUNT
|
||||
if (isset($subresult['queryflags']['select_from'])
|
||||
&& $subresult['queryflags']['select_from'] == 1
|
||||
&& !isset($subresult['queryflags']['is_group'])
|
||||
&& ($i + 1) < $size
|
||||
&& $arr[$i + 1]['type'] == 'alpha_functionName'
|
||||
&& strtoupper($arr[$i + 1]['data']) == 'COUNT'
|
||||
) {
|
||||
$subresult['queryflags']['is_count'] = 1;
|
||||
}
|
||||
}
|
||||
|
||||
if ($upper_data == 'DISTINCT' && !$in_group_concat) {
|
||||
$subresult['queryflags']['distinct'] = 1;
|
||||
}
|
||||
@ -1665,6 +1752,19 @@ function PMA_SQP_analyze($arr)
|
||||
$in_where = false;
|
||||
$in_select_expr = false;
|
||||
$in_from = false;
|
||||
|
||||
// for the presence of GROUP BY|HAVING|SELECT DISTINCT
|
||||
if (isset($subresult['queryflags']['select_from'])
|
||||
&& $subresult['queryflags']['select_from'] == 1
|
||||
&& ($i + 1) < $size
|
||||
&& $arr[$i + 1]['type'] == 'alpha_reservedWord'
|
||||
&& in_array(strtoupper($arr[$i + 1]['data']), array("BY", "HAVING", "SELECT"))
|
||||
&& ($i + 2) < $size
|
||||
&& $arr[$i + 2]['type'] == 'alpha_reservedWord'
|
||||
&& strtoupper($arr[$i + 2]['data']) == 'DISTINCT'
|
||||
) {
|
||||
$subresult['queryflags']['is_group'] = 1;
|
||||
}
|
||||
}
|
||||
if ($upper_data == 'ORDER' && !$in_group_concat) {
|
||||
$seen_order = true;
|
||||
@ -1733,7 +1833,6 @@ function PMA_SQP_analyze($arr)
|
||||
|
||||
} // endif (reservedWord)
|
||||
|
||||
|
||||
// do not add a space after a function name
|
||||
/**
|
||||
* @todo can we combine loop 2 and loop 1? some code is repeated here...
|
||||
@ -1763,6 +1862,7 @@ function PMA_SQP_analyze($arr)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// do not add a space after an identifier if followed by a dot
|
||||
if ($arr[$i]['type'] == 'alpha_identifier'
|
||||
&& $i < $size - 1 && $arr[$i + 1]['data'] == '.'
|
||||
@ -1777,6 +1877,28 @@ function PMA_SQP_analyze($arr)
|
||||
$sep = '';
|
||||
}
|
||||
|
||||
// for the presence of INSERT|LOAD DATA
|
||||
if ($arr[$i]['type'] == 'alpha_identifier'
|
||||
&& strtoupper($arr[$i]['data']) == 'DATA'
|
||||
&& ($i - 1) >= 0
|
||||
&& $arr[$i - 1]['type'] == 'alpha_reservedWord'
|
||||
&& in_array(strtoupper($arr[$i - 1]['data']), array("INSERT", "LOAD"))
|
||||
) {
|
||||
$subresult['queryflags']['is_insert'] = 1;
|
||||
$subresult['queryflags']['is_affected'] = 1;
|
||||
}
|
||||
|
||||
// for the presence of SUM|AVG|STD|STDDEV|MIN|MAX|BIT_OR|BIT_AND
|
||||
if ($arr[$i]['type'] == 'alpha_functionName'
|
||||
&& in_array(strtoupper($arr[$i]['data']), array(
|
||||
"SUM","AVG","STD","STDDEV","MIN","MAX","BIT_OR","BIT_AND"))
|
||||
&& isset($subresult['queryflags']['select_from'])
|
||||
&& $subresult['queryflags']['select_from'] == 1
|
||||
&& !isset($subresult['queryflags']['is_group'])
|
||||
) {
|
||||
$subresult['queryflags']['is_func'] = 1;
|
||||
}
|
||||
|
||||
if ($in_select_expr && $upper_data != 'SELECT'
|
||||
&& $upper_data != 'DISTINCT'
|
||||
) {
|
||||
|
||||
49
po/bs.po
49
po/bs.po
@ -4,17 +4,17 @@ msgstr ""
|
||||
"Project-Id-Version: phpMyAdmin 4.1-dev\n"
|
||||
"Report-Msgid-Bugs-To: phpmyadmin-devel@lists.sourceforge.net\n"
|
||||
"POT-Creation-Date: 2013-06-12 09:39+0200\n"
|
||||
"PO-Revision-Date: 2013-04-05 12:08+0200\n"
|
||||
"Last-Translator: Michal Čihař <michal@cihar.com>\n"
|
||||
"Language-Team: Bosnian <http://l10n.cihar.com/projects/phpmyadmin/master/bs/"
|
||||
">\n"
|
||||
"PO-Revision-Date: 2013-06-16 03:22+0200\n"
|
||||
"Last-Translator: Bilal Ćatić <bilal.the.best@hotmail.com>\n"
|
||||
"Language-Team: Bosnian "
|
||||
"<http://l10n.cihar.com/projects/phpmyadmin/master/bs/>\n"
|
||||
"Language: bs\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
|
||||
"%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
|
||||
"X-Generator: Weblate 1.5-dev\n"
|
||||
"Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%"
|
||||
"10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
|
||||
"X-Generator: Weblate 1.6-dev\n"
|
||||
|
||||
#: browse_foreigners.php:51 browse_foreigners.php:75 js/messages.php:335
|
||||
#: libraries/DisplayResults.class.php:809
|
||||
@ -286,31 +286,28 @@ msgid "Unselect All"
|
||||
msgstr "ništa"
|
||||
|
||||
#: db_operations.php:45 tbl_create.php:24
|
||||
#, fuzzy
|
||||
msgid "The database name is empty!"
|
||||
msgstr "Ima tabele je prazno!"
|
||||
msgstr "Naziv baze je prazan!"
|
||||
|
||||
#: db_operations.php:129
|
||||
#, fuzzy, php-format
|
||||
#, php-format
|
||||
msgid "Database %1$s has been renamed to %2$s"
|
||||
msgstr "Tabeli %s promjenjeno ime u %s"
|
||||
msgstr "Baza %1$s je preimenovana u %2$s"
|
||||
|
||||
#: db_operations.php:133
|
||||
#, fuzzy, php-format
|
||||
#, php-format
|
||||
msgid "Database %1$s has been copied to %2$s"
|
||||
msgstr "Tabela %s je kopirana u %s."
|
||||
msgstr "Baza %1$s je kopirana u %2$s"
|
||||
|
||||
#: db_operations.php:261
|
||||
#, fuzzy, php-format
|
||||
#, php-format
|
||||
#| msgid ""
|
||||
#| " additional features for working with linked tables have been ctivated. "
|
||||
#| "To find out why click %shere%s."
|
||||
msgid ""
|
||||
"The phpMyAdmin configuration storage has been deactivated. To find out why "
|
||||
"click %shere%s."
|
||||
msgstr ""
|
||||
"Dodatne mogućnosti za rad sa povezanim tabelama su isključene. Da biste "
|
||||
"saznali zašto, kliknite %sovde%s."
|
||||
msgstr "phpMyAdmin konfiguracijski spremnik je isključen. %sSaznaj više%s."
|
||||
|
||||
#: db_printview.php:47 db_tracking.php:79 db_tracking.php:198
|
||||
#: libraries/Menu.class.php:190 libraries/config/messages.inc.php:510
|
||||
@ -363,22 +360,23 @@ msgid "Last check:"
|
||||
msgstr "Posljednja provjera"
|
||||
|
||||
#: db_printview.php:149 libraries/structure.lib.php:176
|
||||
#, fuzzy, php-format
|
||||
#, php-format
|
||||
#| msgid "%s table(s)"
|
||||
msgid "%s table"
|
||||
msgid_plural "%s tables"
|
||||
msgstr[0] "%s tabela"
|
||||
msgstr[1] "%s tabela"
|
||||
msgstr[2] ""
|
||||
|
||||
#: db_qbe.php:40
|
||||
msgid "You have to choose at least one column to display"
|
||||
msgstr "Morate izabrati bar jednu kolonu za prikaz"
|
||||
|
||||
#: db_qbe.php:60
|
||||
#, fuzzy, php-format
|
||||
#, php-format
|
||||
#| msgid "Switch to copied table"
|
||||
msgid "Switch to %svisual builder%s"
|
||||
msgstr "Pređi na kopiranu tabelu"
|
||||
msgstr "Pređi na %svizualni graditelj%s"
|
||||
|
||||
#: db_search.php:30 libraries/plugins/auth/AuthenticationConfig.class.php:81
|
||||
#: libraries/plugins/auth/AuthenticationConfig.class.php:96
|
||||
@ -389,10 +387,9 @@ msgid "Access denied"
|
||||
msgstr "Ulaz nije dozvoljen"
|
||||
|
||||
#: db_structure.php:86
|
||||
#, fuzzy
|
||||
#| msgid "No tables found in database."
|
||||
msgid "No tables found in database"
|
||||
msgstr "Tabele nisu pronađene u bazi."
|
||||
msgstr "Nema pronađenih tabela u bazi"
|
||||
|
||||
#: db_tracking.php:73
|
||||
msgid "Tracked tables"
|
||||
@ -415,9 +412,8 @@ msgid "Last version"
|
||||
msgstr ""
|
||||
|
||||
#: db_tracking.php:81 tbl_tracking.php:765
|
||||
#, fuzzy
|
||||
msgid "Created"
|
||||
msgstr "Napravi"
|
||||
msgstr "Kreirano"
|
||||
|
||||
#: db_tracking.php:82 tbl_tracking.php:766
|
||||
msgid "Updated"
|
||||
@ -463,9 +459,8 @@ msgid "not active"
|
||||
msgstr ""
|
||||
|
||||
#: db_tracking.php:138
|
||||
#, fuzzy
|
||||
msgid "Versions"
|
||||
msgstr "Operacije"
|
||||
msgstr "Verzije"
|
||||
|
||||
#: db_tracking.php:139 tbl_tracking.php:489 tbl_tracking.php:799
|
||||
msgid "Tracking report"
|
||||
@ -9528,7 +9523,7 @@ msgstr "Prikaži dimenzije tabele"
|
||||
|
||||
#: libraries/schema/User_Schema.class.php:457
|
||||
msgid "Display all tables with the same width"
|
||||
msgstr "prikaz svih tabela iste širine?"
|
||||
msgstr "Prikaži sve tabele u jednakoj širini"
|
||||
|
||||
#: libraries/schema/User_Schema.class.php:460 libraries/structure.lib.php:379
|
||||
msgid "Data Dictionary"
|
||||
|
||||
52
po/hu.po
52
po/hu.po
@ -4,16 +4,16 @@ msgstr ""
|
||||
"Project-Id-Version: phpMyAdmin 4.1-dev\n"
|
||||
"Report-Msgid-Bugs-To: phpmyadmin-devel@lists.sourceforge.net\n"
|
||||
"POT-Creation-Date: 2013-06-12 09:39+0200\n"
|
||||
"PO-Revision-Date: 2013-04-03 09:47+0200\n"
|
||||
"Last-Translator: Michal Čihař <michal@cihar.com>\n"
|
||||
"Language-Team: Hungarian <http://l10n.cihar.com/projects/phpmyadmin/master/"
|
||||
"hu/>\n"
|
||||
"PO-Revision-Date: 2013-06-16 14:07+0200\n"
|
||||
"Last-Translator: Ádám Papp-Kuster <pkadam@kuster.hu>\n"
|
||||
"Language-Team: Hungarian "
|
||||
"<http://l10n.cihar.com/projects/phpmyadmin/master/hu/>\n"
|
||||
"Language: hu\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
||||
"X-Generator: Weblate 1.5-dev\n"
|
||||
"X-Generator: Weblate 1.6-dev\n"
|
||||
|
||||
#: browse_foreigners.php:51 browse_foreigners.php:75 js/messages.php:335
|
||||
#: libraries/DisplayResults.class.php:809
|
||||
@ -902,7 +902,7 @@ msgstr ""
|
||||
"phpMyAdmin könyvtárában. Távolítsa el a phpMyAdmin beállítása után."
|
||||
|
||||
#: index.php:489
|
||||
#, fuzzy, php-format
|
||||
#, php-format
|
||||
#| msgid ""
|
||||
#| "ditional features for working with linked tables have been ctivated. To d "
|
||||
#| "out why click %shere%s."
|
||||
@ -910,8 +910,9 @@ msgid ""
|
||||
"The phpMyAdmin configuration storage is not completely configured, some "
|
||||
"extended features have been deactivated. To find out why click %shere%s."
|
||||
msgstr ""
|
||||
"A hivatkozott táblákkal történő munka kiegészítő funkciói inaktiválásra "
|
||||
"kerültek. Ha szeretné megtudni, hogy miért, kattintson %side%s."
|
||||
"A phpMyAdmin konfigurációs tárolója nincs megfelelően beállítva, néhány "
|
||||
"kibővített funkció inaktiválásra került. Ha szeretné megtudni, hogy miért, "
|
||||
"kattintson %side%s."
|
||||
|
||||
#: index.php:521
|
||||
#, php-format
|
||||
@ -982,10 +983,10 @@ msgstr "Index szerkesztése"
|
||||
|
||||
#: js/messages.php:44 libraries/display_indexes.lib.php:199
|
||||
#: libraries/display_indexes.lib.php:205
|
||||
#, fuzzy, php-format
|
||||
#, php-format
|
||||
#| msgid "Add %d column(s) to index"
|
||||
msgid "Add %s column(s) to index"
|
||||
msgstr "%d oszlop hozzáadása az indexhez"
|
||||
msgstr "%s oszlop hozzáadása az indexhez"
|
||||
|
||||
#. l10n: Default label for the y-Axis of Charts
|
||||
#: js/messages.php:48 tbl_chart.php:236
|
||||
@ -1051,10 +1052,9 @@ msgid "Connections / Processes"
|
||||
msgstr "Kapcsolatok / Folyamatok"
|
||||
|
||||
#: js/messages.php:70
|
||||
#, fuzzy
|
||||
#| msgid "Cannot load or save configuration"
|
||||
msgid "Local monitor configuration incompatible"
|
||||
msgstr "A beállítások nem tölthetők be vagy menthetők"
|
||||
msgstr "A helyi megfigyelés beállításai nem kompatibilisek"
|
||||
|
||||
#: js/messages.php:71
|
||||
msgid ""
|
||||
@ -1327,7 +1327,7 @@ msgstr "Diagramcím"
|
||||
#. l10n: As in differential values
|
||||
#: js/messages.php:144
|
||||
msgid "Differential"
|
||||
msgstr ""
|
||||
msgstr "Megkülönböztető"
|
||||
|
||||
#: js/messages.php:145
|
||||
#, php-format
|
||||
@ -1374,7 +1374,7 @@ msgstr ""
|
||||
|
||||
#: js/messages.php:155
|
||||
msgid "Log data loaded. Queries executed in this time span:"
|
||||
msgstr ""
|
||||
msgstr "A naplóadatok betöltve. Végrehajtott lekérdezések ebben az időszakban:"
|
||||
|
||||
#: js/messages.php:157
|
||||
msgid "Jump to Log table"
|
||||
@ -1386,7 +1386,7 @@ msgstr "Nincs adat"
|
||||
|
||||
#: js/messages.php:159
|
||||
msgid "Log analysed, but no data found in this time span."
|
||||
msgstr ""
|
||||
msgstr "A napló megvizsgálva, de nincs adat az adott időszakban."
|
||||
|
||||
#: js/messages.php:161
|
||||
msgid "Analyzing…"
|
||||
@ -1410,10 +1410,9 @@ msgid "Total time:"
|
||||
msgstr "Teljes idő:"
|
||||
|
||||
#: js/messages.php:166
|
||||
#, fuzzy
|
||||
#| msgid "Profiling"
|
||||
msgid "Profiling results"
|
||||
msgstr "Adatgyűjtés"
|
||||
msgstr "Eredmények elemzése"
|
||||
|
||||
#: js/messages.php:167
|
||||
msgctxt "Display format"
|
||||
@ -1466,7 +1465,7 @@ msgstr "Naplók betöltése"
|
||||
|
||||
#: js/messages.php:182
|
||||
msgid "Monitor refresh failed"
|
||||
msgstr ""
|
||||
msgstr "A megfigyelés frissítése sikertelen"
|
||||
|
||||
#: js/messages.php:183
|
||||
msgid ""
|
||||
@ -1474,6 +1473,9 @@ msgid ""
|
||||
"This is most likely because your session expired. Reloading the page and "
|
||||
"reentering your credentials should help."
|
||||
msgstr ""
|
||||
"Az új diagram adatainak lekérésekor a szerver érvénytelen választ adott. "
|
||||
"Valószínűleg a munkamenet lejárt. Az oldal újratöltése, és a belépési adatok "
|
||||
"újbóli megadása segíthet."
|
||||
|
||||
#: js/messages.php:184
|
||||
msgid "Reload page"
|
||||
@ -1492,6 +1494,8 @@ msgstr ""
|
||||
msgid ""
|
||||
"Failed building chart grid with imported config. Resetting to default config…"
|
||||
msgstr ""
|
||||
"A grafikon felépítése az importált beállításokkal sikertelen. Eredet "
|
||||
"beállítások visszaállítása…"
|
||||
|
||||
#: js/messages.php:190 libraries/Menu.class.php:288
|
||||
#: libraries/Menu.class.php:371 libraries/Menu.class.php:482
|
||||
@ -1502,10 +1506,9 @@ msgid "Import"
|
||||
msgstr "Importálás"
|
||||
|
||||
#: js/messages.php:191
|
||||
#, fuzzy
|
||||
#| msgid "Could not import configuration"
|
||||
msgid "Import monitor configuration"
|
||||
msgstr "Nem importálhatók a beállítások"
|
||||
msgstr "Megfigyelési beállítások importálása"
|
||||
|
||||
#: js/messages.php:192
|
||||
msgid "Please select the file you want to import"
|
||||
@ -1570,7 +1573,7 @@ msgstr "Hiba a kérés feldolgozásában"
|
||||
#: js/messages.php:216
|
||||
#, php-format
|
||||
msgid "Error code: %s"
|
||||
msgstr ""
|
||||
msgstr "Hibakód: %s"
|
||||
|
||||
#: js/messages.php:217
|
||||
#, php-format
|
||||
@ -1703,7 +1706,7 @@ msgstr "SQL-lekérdezési panelek elrejtése"
|
||||
|
||||
#: js/messages.php:263
|
||||
msgid "Show query box"
|
||||
msgstr "Lekérdezési dobox megjelenítése"
|
||||
msgstr "Lekérdezési doboz megjelenítése"
|
||||
|
||||
#: js/messages.php:264 libraries/DisplayResults.class.php:3314
|
||||
#: libraries/Index.class.php:591 libraries/Util.class.php:699
|
||||
@ -1813,10 +1816,9 @@ msgid "Point"
|
||||
msgstr "Pont"
|
||||
|
||||
#: js/messages.php:304
|
||||
#, fuzzy
|
||||
#| msgid "Lines terminated by"
|
||||
msgid "Linestring"
|
||||
msgstr "Sorok vége"
|
||||
msgstr "Sorvég-karakter"
|
||||
|
||||
#: js/messages.php:305
|
||||
msgid "Polygon"
|
||||
@ -6176,7 +6178,7 @@ msgstr ""
|
||||
|
||||
#: libraries/config/messages.inc.php:480 libraries/sql_query_form.lib.php:373
|
||||
msgid "Retain query box"
|
||||
msgstr "Lekérdezési dobox megőrzése"
|
||||
msgstr "Lekérdezési doboz megőrzése"
|
||||
|
||||
#: libraries/config/messages.inc.php:481
|
||||
msgid "Allow to display database and table statistics (eg. space usage)"
|
||||
|
||||
17
sql.php
17
sql.php
@ -202,7 +202,7 @@ if (empty($sql_query) && strlen($table) && strlen($db)) {
|
||||
/**
|
||||
* Parse and analyze the query
|
||||
*/
|
||||
require_once 'libraries/parse_analyze.lib.php';
|
||||
require_once 'libraries/parse_analyze.inc.php';
|
||||
|
||||
|
||||
/**
|
||||
@ -308,21 +308,6 @@ if (isset($_REQUEST['btnDrop']) && $_REQUEST['btnDrop'] == __('No')) {
|
||||
exit();
|
||||
} // end if
|
||||
|
||||
// Defines some variables
|
||||
// $is_group added for use in calculation of total number of rows.
|
||||
// $is_count is changed for more correct "LIMIT" clause
|
||||
// appending in queries like
|
||||
// "SELECT COUNT(...) FROM ... GROUP BY ..."
|
||||
|
||||
/**
|
||||
* @todo detect all this with the parser, to avoid problems finding
|
||||
* those strings in comments or backquoted identifiers
|
||||
*/
|
||||
list($is_group, $is_func, $is_count, $is_export, $is_analyse, $is_explain,
|
||||
$is_delete, $is_affected, $is_insert, $is_replace, $is_show, $is_maint)
|
||||
= PMA_getDisplayPropertyParams(
|
||||
$sql_query, $is_select
|
||||
);
|
||||
|
||||
// assign default full_sql_query
|
||||
$full_sql_query = $sql_query;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user