CreateIndex: remove length limits from column names, if DB type is NOT MySQL

This commit is contained in:
Ralf Becker 2010-09-16 10:23:18 +00:00
parent 67812b8c82
commit e89850c067

View File

@ -517,6 +517,11 @@ class schema_proc
*/
function CreateIndex($sTableName,$aColumnNames,$bUnique=false,$options='',$sIdxName='')
{
// remove length limits from column names, if DB type is NOT MySQL
if ($this->sType != 'mysql')
{
$aColumnNames = preg_replace('/ *\(\d+\)$/','',$aColumnNames);
}
if (!$sIdxName || is_numeric($sIdxName))
{
$sIdxName = $this->_index_name($sTableName,$aColumnNames);