MySql GetColumnInfo Scale

This commit is contained in:
sunkaixuna
2021-04-25 13:11:49 +08:00
parent c495df43eb
commit 9423b0db14

View File

@@ -31,7 +31,9 @@ namespace SqlSugar
THEN true ELSE false END AS `IsPrimaryKey`, THEN true ELSE false END AS `IsPrimaryKey`,
CASE WHEN EXTRA='auto_increment' THEN true ELSE false END as IsIdentity, CASE WHEN EXTRA='auto_increment' THEN true ELSE false END as IsIdentity,
CASE WHEN is_nullable = 'YES' CASE WHEN is_nullable = 'YES'
THEN true ELSE false END AS `IsNullable` THEN true ELSE false END AS `IsNullable`,
numeric_scale as Scale,
numeric_scale as DecimalDigits
FROM FROM
Information_schema.columns where TABLE_NAME='{0}' and TABLE_SCHEMA=(select database()) ORDER BY TABLE_NAME"; Information_schema.columns where TABLE_NAME='{0}' and TABLE_SCHEMA=(select database()) ORDER BY TABLE_NAME";
return sql; return sql;