本文介绍了将sqlServer转换为Sqlite ConvertSqlServerToSQLiteDatabase的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我使用ConvertSqlServerToSQLiteDatabase并向我显示错误数据类型[日期]验证失败。
i use ConvertSqlServerToSQLiteDatabase and show me a error "validation failed for data type[date]".
推荐答案
private static void ValidateDataType(string dataType)
{
if (dataType == "int" || dataType == "smallint" ||
dataType == "bit" || dataType == "float" ||
dataType == "real" || dataType == "nvarchar" ||
dataType == "varchar" || dataType == "timestamp" ||
dataType == "varbinary" || dataType == "image" ||
dataType == "text" || dataType == "ntext" ||
dataType == "bigint" ||
dataType == "char" || dataType == "numeric" ||
dataType == "binary" || dataType == "smalldatetime" ||
dataType == "smallmoney" || dataType == "money" ||
dataType == "tinyint" || dataType == "uniqueidentifier" ||
dataType == "xml" || dataType == "sql_variant" ||
dataType == "decimal" || dataType == "nchar" || dataType == "datetime")
return;
throw new ApplicationException("Validation failed for data type [" + dataType + "]");
}
这篇关于将sqlServer转换为Sqlite ConvertSqlServerToSQLiteDatabase的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!