W wpw72 Unregistered / Unconfirmed GUEST, unregistred user! 2007-12-02 #2 在数据集中添加一个计算字段如起名为SN,然后在qry的oncalcfield事件中添加以下代码 DataSet.FieldByName('SN').Value := Abs(DataSet.RecNo);
在数据集中添加一个计算字段如起名为SN,然后在qry的oncalcfield事件中添加以下代码 DataSet.FieldByName('SN').Value := Abs(DataSet.RecNo);
W wabb Unregistered / Unconfirmed GUEST, unregistred user! 2007-12-02 #3 我说的是在一个Query中写一个SQL语句返回的数据中如何加
F fanybul Unregistered / Unconfirmed GUEST, unregistred user! 2007-12-02 #4 你可以把查询到的数据先放入一个临时表,然后再对临时表进行处理下就行了.
F fanybul Unregistered / Unconfirmed GUEST, unregistred user! 2007-12-02 #5 select identity(int,1,1) as id,* into #t from aa select * from #t drop table #t
A aerobull Unregistered / Unconfirmed GUEST, unregistred user! 2007-12-02 #6 下面的语句就可以解决了。 use northwind select (select count(CustomerID) from customers z where z.CustomerID<=y.CustomerID) as 序号,* from customers y
下面的语句就可以解决了。 use northwind select (select count(CustomerID) from customers z where z.CustomerID<=y.CustomerID) as 序号,* from customers y
L linuxping Unregistered / Unconfirmed GUEST, unregistred user! 2007-12-05 #8 select identity(int,1,1) as MyID ,* from xxxx
S shadowpj Unregistered / Unconfirmed GUEST, unregistred user! 2007-12-05 #9 fanybul为正解!不能直接select identity(int,1,1) 要 into 所以借用临时表