LinuxDoku / migratordotnet

Automatically exported from code.google.com/p/migratordotnet
0 stars 0 forks source link

Patch for wrong string format in SQLTransformationProvider #26

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Very minor Patch
Hi an exception in the SqlServerTransformationProvider had a wrong string 
format. I'm sending a patch or you may change it at the following 
function. (First throw has twice {0} while it should have {1} the second 
time

public override void RenameColumn(string tableName, string oldColumnName, 
string newColumnName)
        {
            if (ColumnExists(tableName, newColumnName))
                throw new MigrationException(String.Format("Table '{0}' 
has column named '{0}' already", tableName, newColumnName));

            if (ColumnExists(tableName, oldColumnName)) 
                ExecuteNonQuery(String.Format("EXEC sp_rename '{0}.
{1}', '{2}', 'COLUMN'", tableName, oldColumnName, newColumnName));
        }

Original issue reported on code.google.com by gustavo.ringel@gmail.com on 9 Jun 2008 at 8:23

Attachments:

GoogleCodeExporter commented 8 years ago
The patch has been applied. Thank you!

Original comment by dko...@gmail.com on 9 Jun 2008 at 12:52