PMA_getTableDef() is also called from Table.class.php

This commit is contained in:
Marc Delisle
2008-06-27 14:27:18 +00:00
parent 42d36c90e6
commit e4f84a9bbb
2 changed files with 4 additions and 3 deletions

View File

@@ -432,6 +432,7 @@ function PMA_getTableDefStandIn($db, $view, $crlf) {
* @param string the end of line sequence
* @param string the url to go back in case of error
* @param boolean whether to include creation/update/check dates
* @param boolean whether to add semicolon and end-of-line at the end
*
* @return string resulting schema
*
@@ -441,7 +442,7 @@ function PMA_getTableDefStandIn($db, $view, $crlf) {
*
* @access public
*/
function PMA_getTableDef($db, $table, $crlf, $error_url, $show_dates = false)
function PMA_getTableDef($db, $table, $crlf, $error_url, $show_dates = false, $add_semicolon = true)
{
global $sql_drop_table;
global $sql_backquotes;
@@ -613,7 +614,7 @@ function PMA_getTableDef($db, $table, $crlf, $error_url, $show_dates = false)
$schema_create .= $auto_increment;
PMA_DBI_free_result($result);
return $schema_create . ';' . $crlf;
return $schema_create . ($add_semicolon ? ';' . $crlf : '');
} // end of the 'PMA_getTableDef()' function