我以前用过:
设为空:FieldByName(字段名).Value := null;
判断:if FieldByName(字段名).IsNull then ...
设为空:FieldByName(字段名).Value := null;
判断:if FieldByName(字段名).IsNull then ...
解决方案 »
- delphi显示多张图片
- 怎么去学习Delphi?
- 关于FastReport动态更新数值的问题。
- 微软脚本语言解密源程序scrdec V1.7,哪位好心人帮忙译成DELPHI!!
- 怎样将一个表中的记录写到文本文件????追加写入,循环读出字段内容写,不转行
- 基本东西求救
- 嘿嘿,倒分进入倒计时~~~
- 我以前沒看幫助,一直以為topitem是tree的根節點,其實不是,那根節點怎樣得到呢
- 将C++代码转换成相应的Delphi代码
- 如何在windows me下安装windows 2000专业版?
- 怎么使用serverSocket多线程接收客户端发送过来的数据包啊
- 书中的.if length(s)=high(s) then dec(s[0]) 是怎么比较和截取的?谢谢。
showmessage('yes')
else
begin
table1.Edit ;
table1.Fields[4].Value :='';
table1.Post ;
end;
请高手门关注一下
Table1.Edit;
Table1Graphic.Clear;
Table1.Post;
isnull 还是=nil
begin
Table1.Edit;
Table1Graphic.Clear;
Table1.Post;
end;procedure TForm1.Button2Click(Sender: TObject);
begin
if Table1Graphic.IsNull then
ShowMessage('Hello, world!');
end;
还是不行啊,我试了n次了,我用的是adoquery
if OleContainer1.State = osEmpty then
begin
adoquery1.Edit;
ADOQuery1DSDesigner1.Clear; //经过调试,当olecontainerl为空的时候可以执行这一句
adoquery1.Post;
end
else begin
m := TMemoryStream.Create;
OleContainer1.SaveToStream(m);
m.Position := 0;
adoquery1.Insert;
TBlobField(adoquery1.fieldbyname('1')).LoadFromStream(m);
adoquery1.Post;
end;用这个清空ole控件
OleContainer1.DestroyObject;判断是这样
if ADOQuery1DSDesigner1.IsNull then
showmessage('null')
else
showmessage('blob') 除了第一次,后面每次都显示blob
设为空:FieldByName(字段名).Value := null;
判断:if FieldByName(字段名).IsNull then ...
在delphi5 + Access 2000环境中通过,没有问题。至于其他类型数据库是否可行我就不知道了。
我也怀疑是bug,所有想得到的方法都试过了,请问怎样得到pack?
to fengerfeifei(风儿飞飞)
只要一载入字段,根本没有办法清空字段的值,就是说长度永远不可能为0
to snjun
试过了:(
update table set blobfield=EMPTY_BLOB()
where 。
这样之后你的blob字段绝对是空的
我用的是access,没有EMPTY_BLOB()有没有办法用sql语句把一个字段置空?
update Table set Field = null where conditions