none
C#语怎样对accdb文件中已有的查询做句子的修改? RRS feed

  • 问题

  • 现有一表“戈胶单”,重命名为“交割单”,手工即可。

    但是查询中多如牛毛,

    SELECT 
    (select top 1 code from 戈胶单 a where a.name=c.name and a.code not like'7*' and a.code not like '07*' and type not like '配号' and name not like '*转*') AS 代号, 
    (select top 1 name from 戈胶单 b where b.name=c.name and b.name not like '*[配,申][,号,购]' and type not like '配号' and name not like '*转*') AS 名称,
    abs(sum(c.[real e]))/sum(c.[real e])*log(abs(sum(c.[real e]))) as 挣对数 ,
    sum(c.[real e])/10000 AS 铋烷
    FROM 戈胶单 AS c
    WHERE [type] In('买入','卖出','中签扣款','送股','托管转入','红利','缴款') 
    And code Not Like '1[1,2,3]????'
    And code Not Like '204???' And name Not Like '*发[?|债]'
    And [name] Not Like '[0-9][0-9][0-9][0-9][0-9][0-9]' And [name] not like '*[a-y]*' GROUP BY name HAVING 3<>0 and sum(numer)=0 ORDER BY abs(sum(c.[real e]))/sum(c.[real e])*log(abs(sum(c.[real e]))) DESC UNION select null,'所有债', (select abs(sum(d.[real e]))/sum(d.[real e])*log(abs(sum(d.[real e]))) from 戈胶单 d where d.code like '1?????' and d.type not like '融券*' ), sum([real e])/10000 from 戈胶单 where code like '1?????' and type not like '融券*';

    用C#语怎么读取并修改?



    • 已编辑 czhch 2021年11月26日 23:37 强调
    2021年11月26日 23:34

全部回复