Merged from MOODLE_18_STABLE
if ($xmldb_table->getComment()) {
$comment .= 'ALTER TABLE ' . $this->getTableName($xmldb_table);
- $comment .= " COMMENT='" . substr($xmldb_table->getComment(), 0, 60) . "'";
+ $comment .= " COMMENT='" . addslashes(substr($xmldb_table->getComment(), 0, 60)) . "'";
}
return array($comment);
}
function getCommentSQL ($xmldb_table) {
$comment = "COMMENT ON TABLE " . $this->getTableName($xmldb_table);
- $comment.= " IS '" . substr($xmldb_table->getComment(), 0, 250) . "'";
+ $comment.= " IS '" . addslashes(substr($xmldb_table->getComment(), 0, 250)) . "'";
return array($comment);
}
function getCommentSQL ($xmldb_table) {
$comment = "COMMENT ON TABLE " . $this->getTableName($xmldb_table);
- $comment.= " IS '" . substr($xmldb_table->getComment(), 0, 250) . "'";
+ $comment.= " IS '" . addslashes(substr($xmldb_table->getComment(), 0, 250)) . "'";
return array($comment);
}