E
edns
Unregistered / Unconfirmed
GUEST, unregistred user!
创建临时表代码---
with Table1 do
begin
Active:=false;
TableName:='temp';
FieldDefs.Clear;
FieldDefs.Add('a',ftString,18,false);
FieldDefs.Add('b',ftString,18,false);
FieldDefs.Add('c',ftCurrency,0,True);
IndexDefs.Clear;
CreateTable;
Active:=True;
end;
-----
我已经把一excel资料写入该临时表,
a b c
0001 a0001 2000.00
0002 a0002 1850.00
0003 a0003 1000.00
0003 a0003 1500.00
先要对该临时表进行分组(按字段a分组)求和,结果如下:
a b c
0001 a0001 2000.00
0002 a0002 1850.00
0003 a0003 2500.00
该如何是好???请大家帮忙!!! 先谢谢了!!!
with Table1 do
begin
Active:=false;
TableName:='temp';
FieldDefs.Clear;
FieldDefs.Add('a',ftString,18,false);
FieldDefs.Add('b',ftString,18,false);
FieldDefs.Add('c',ftCurrency,0,True);
IndexDefs.Clear;
CreateTable;
Active:=True;
end;
-----
我已经把一excel资料写入该临时表,
a b c
0001 a0001 2000.00
0002 a0002 1850.00
0003 a0003 1000.00
0003 a0003 1500.00
先要对该临时表进行分组(按字段a分组)求和,结果如下:
a b c
0001 a0001 2000.00
0002 a0002 1850.00
0003 a0003 2500.00
该如何是好???请大家帮忙!!! 先谢谢了!!!