本人在测试过程中,发现 CnDHibernate 不支持 Boolean 类型数据, 我想Boolean类型在Delphi中应该人人都用到吧.相关代码部分:
if tk <> tkMethod then
begin
// set the Enum properties ////本人修改加入, 不知会不会产生问题
if tk = tkEnumeration then
begin
SetEnumProp((obj as clazz), pplst^.Name,FieldByName(pplst^.Name).AsString);
end; ////end
// set the string properties
if (tk = tkString) or (tk = tkLString) or (tk = tkWString) or (tk=tkUString) then
begin
SetStrProp((obj as clazz), pplst^.Name, FieldByName(pplst^.Name).AsString);
end;
// set the integer properties
if tk = tkInteger then
begin
try
SetInt64Prop((obj as clazz), pplst^.Name,FieldByName(pplst^.Name).AsInteger);
except
SetInt64Prop((obj as clazz), pplst^.Name, 0);
end;
end;
// set the float properties
if tk = tkFloat then
begin
try
SetFloatProp((obj as clazz), pplst^.Name,
FieldByName(pplst^.Name).AsFloat);
except
SetFloatProp((obj as clazz), pplst^.Name, 0);
end;
end;
// set the variant properties
if tk = tkVariant then
begin
SetVariantProp((obj as clazz), pplst^.Name,
FieldByName(pplst^.Name).Value);
end;Author:
rarnu Time: 2008-10-5 21:00
用sql2005试过?
sql2000本身就没有boolean的Author:
bincom Time: 2008-10-6 09:33 Subject: MS SQL里的BIT类型是->Boolean(Delphi )