示例#1
0
        public override void MigrateTable(TableStructure table, IMigrationProfile profile, IProgressInfo progress)
        {
            base.MigrateTable(table, profile, progress);

            MigrateTool.RemoveNonPk1AutoIncrements(table, progress);

            foreach (ColumnStructure col in table.Columns)
            {
                var    spec    = col.DefaultValue as SpecialConstantSqlExpression;
                string subtype = col.DataType.GetSpecificAttribute("mysql", "subtype");
                if (spec != null)
                {
                    if (subtype != "timestamp")
                    {
                        col.DefaultValue = null;
                        col.IsNullable   = true;
                        progress.Warning(String.Format("Default value for column {0}.{1} was removed, it is not valid on MySQL", table.FullName, col.ColumnName));
                    }
                }
            }
        }
示例#2
0
        public override void MigrateTable(TableStructure table, IMigrationProfile profile, IProgressInfo progress)
        {
            base.MigrateTable(table, profile, progress);

            MigrateTool.RemoveNonPk1AutoIncrements(table, progress);
        }