我有一个SQL查询的示例 请给我电子邮件,[email protected]
解决方案 »
- 菜鸟问:怎样使combobox变得完全不可用?
- 分割成BPL后,为何主程序(EXE)大小没变少?
- 怎样制作个性化窗体模板?(于“金山毒霸”类似)
- 关于MessageBox的问题
- ToolButton1问题,帮忙.
- 大家能不能介绍几个国外的比较好的编程论坛?
- 请问我在WIN2000和dephi 6.0 开发的 基于ADO连接的小型程序,移到WIN98下怎么就不能运行了呀,
- 请教:文件处理的速度
- 可以用例子说明一下ORACLE的外连接的SQL语句吗?
- 关于Calculated字段的计算问题。
- 我用BDE Administrator 配置完一个.mdb的数据库,当我改table.active为true时
- 今天谁还在工作散分了
0:str:='select * form ..'
0:str:='select * form ..'
0:str:='select * form ..'
0:str:='select * form ..'
end
query add(str)...
此法如何??
str:string;
begin
str:='';
FrmPopedFind:=TFrmPopedFind.Create(self);
if FrmPopedFind.ShowModal=mrOk then
begin
//ModalResult
if FrmPopedFind.edit1.Text<>'' then
str:=str+'a.UserId like '+'''%'+FrmPopedFind.edit1.Text+'%'''+' and ';
if FrmPopedFind.edit2.Text<>'' then
str:=str+'a.dept like '+'''%'+FrmPopedFind.edit2.Text+'%'''+' and ';
if FrmPopedFind.edit3.Text<>'' then
str:=str+'a.name like '+'''%'+FrmPopedFind.edit3.Text+'%'''+' and ';
if str='' then
exit
else
str:=(copy(str,1,length(str)-5)); with AQuery1 do
begin
close;
sql.Clear;
sql.Add('select *'+
' from login a,popedom b'+
' where '+str+' and a.pGroup=b.pGroup');
open;
end;
end;
FrmPopedFind.Free;
end;