Fixing some potential problems with prefixes and object names.
This commit is contained in:
@@ -233,7 +233,7 @@ class XMLDBgenerator {
|
||||
|
||||
$index = 'CREATE' . $unique . ' INDEX ';
|
||||
$index .= $this->getNameForObject($xmldb_table->getName(), implode(', ', $xmldb_index->getFields()), $suffix);
|
||||
$index .= ' ON ' . $this->prefix . $this->getEncQuoted($xmldb_table->getName());
|
||||
$index .= ' ON ' . $this->getEncQuoted($this->prefix . $xmldb_table->getName());
|
||||
$index .= ' (' . implode(', ', $this->getEncQuoted($xmldb_index->getFields())) . ');';
|
||||
|
||||
return $index;
|
||||
|
||||
@@ -60,13 +60,6 @@ class XMLDBmssql extends XMLDBgenerator {
|
||||
$this->reserved_words = $this->getReservedWords();
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the prefix
|
||||
*/
|
||||
function setPrefix($prefix) {
|
||||
$this->prefix = $prefix;
|
||||
}
|
||||
|
||||
/**
|
||||
* Given one XMLDB Type, lenght and decimals, returns the DB proper SQL type
|
||||
*/
|
||||
|
||||
@@ -58,13 +58,6 @@ class XMLDBmysql extends XMLDBGenerator {
|
||||
$this->reserved_words = $this->getReservedWords();
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the prefix
|
||||
*/
|
||||
function setPrefix($prefix) {
|
||||
$this->prefix = $prefix;
|
||||
}
|
||||
|
||||
/**
|
||||
* Given one XMLDB Type, lenght and decimals, returns the DB proper SQL type
|
||||
*/
|
||||
|
||||
@@ -58,13 +58,6 @@ class XMLDBpostgres7 extends XMLDBgenerator {
|
||||
$this->reserved_words = $this->getReservedWords();
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the prefix
|
||||
*/
|
||||
function setPrefix($prefix) {
|
||||
$this->prefix = $prefix;
|
||||
}
|
||||
|
||||
/**
|
||||
* Given one XMLDB Type, lenght and decimals, returns the DB proper SQL type
|
||||
*/
|
||||
@@ -139,7 +132,7 @@ class XMLDBpostgres7 extends XMLDBgenerator {
|
||||
*/
|
||||
function getCommentSQL ($xmldb_table) {
|
||||
|
||||
$comment = ";\n\nCOMMENT ON TABLE " . $this->prefix . $this->getEncQuoted($xmldb_table->getName());
|
||||
$comment = ";\n\nCOMMENT ON TABLE " . $this->getEncQuoted($this->prefix . $xmldb_table->getName());
|
||||
$comment.= " IS '" . substr($xmldb_table->getComment(), 0, 250) . "'";
|
||||
|
||||
return $comment;
|
||||
|
||||
Reference in New Issue
Block a user