- 更新 达梦 nullable 判断

This commit is contained in:
28810 2019-12-13 12:38:57 +08:00
parent 18176f3789
commit 2b85e2e22d
3 changed files with 11 additions and 4 deletions

View File

@ -110,6 +110,13 @@
清空状态数据
</summary>
</member>
<member name="M:FreeSql.DbSet`1.RemoveAsync(System.Linq.Expressions.Expression{System.Func{`0,System.Boolean}})">
<summary>
根据 lambda 条件删除数据
</summary>
<param name="predicate"></param>
<returns></returns>
</member>
<member name="M:FreeSql.DbSet`1.Add(`0)">
<summary>
添加

View File

@ -182,7 +182,7 @@ a.data_length,
a.data_precision,
a.data_scale,
a.char_used,
case when a.nullable = 'Y' then 1 else 0 end,
case when a.nullable = 'N' then 0 else 1 end,
nvl((select 1 from user_sequences where sequence_name='{Utils.GetCsName((tboldname ?? tbname).Last())}_seq_'||a.column_name), 0),
nvl((select 1 from user_triggers where trigger_name='{Utils.GetCsName((tboldname ?? tbname).Last())}_seq_'||a.column_name||'TI'), 0),
b.comments

View File

@ -258,7 +258,7 @@ a.data_length,
a.data_precision,
a.data_scale,
a.char_used,
case when a.nullable = 'Y' then 1 else 0 end,
case when a.nullable = 'N' then 0 else 1 end,
nvl((select 1 from user_sequences where upper(sequence_name)=upper(a.table_name||'_seq_'||a.column_name)), 0),
b.comments
from all_tab_cols a
@ -320,7 +320,7 @@ a.table_owner || '.' || a.table_name,
c.column_name,
c.index_name,
case when a.uniqueness = 'UNIQUE' then 1 else 0 end,
0,
case when exists(select 1 from all_constraints where constraint_name = a.index_name and constraint_type = 'P') then 1 else 0 end,
0,
case when c.descend = 'DESC' then 1 else 0 end,
c.column_position
@ -330,7 +330,6 @@ where a.index_name = c.index_name
and a.table_owner = c.table_owner
and a.table_name = c.table_name
and a.table_owner in ({1}) and {0}
and not exists(select 1 from all_constraints where index_name = a.index_name and constraint_type = 'P')
", loc8, databaseIn);
ds = _orm.Ado.ExecuteArray(CommandType.Text, sql);
if (ds == null) return loc1;
@ -351,6 +350,7 @@ and not exists(select 1 from all_constraints where index_name = a.index_name and
if (loc3.ContainsKey(table_id) == false || loc3[table_id].ContainsKey(column) == false) continue;
var loc9 = loc3[table_id][column];
if (loc9.IsPrimary == false && is_primary_key) loc9.IsPrimary = is_primary_key;
if (is_primary_key) continue;
Dictionary<string, DbIndexInfo> loc10 = null;
DbIndexInfo loc11 = null;