diff --git a/lib/Doctrine/Export.php b/lib/Doctrine/Export.php index 82550d5ae..4847bc5de 100644 --- a/lib/Doctrine/Export.php +++ b/lib/Doctrine/Export.php @@ -593,6 +593,24 @@ class Doctrine_Export extends Doctrine_Connection_Module } return implode(', ', $ret); } + /** + * A method to return the required SQL string that fits between CREATE ... TABLE + * to create the table as a temporary table. + * + * Should be overridden in driver classes to return the correct string for the + * specific database type. + * + * The default is to return the string "TEMPORARY" - this will result in a + * SQL error for any database that does not support temporary tables, or that + * requires a different SQL command from "CREATE TEMPORARY TABLE". + * + * @return string The string required to be placed between "CREATE" and "TABLE" + * to generate a temporary table, if possible. + */ + public function getTemporaryTableQuery() + { + return 'TEMPORARY'; + } /** * getForeignKeyDeclaration * Obtain DBMS specific SQL code portion needed to set the FOREIGN KEY constraint