以下是引用fdqzy在2020-9-16 14:34:51的发言:
再请教关于行统计的问题:
我的常规处理办法是
create cursor b1 (c1 N(3),c2 N(3),m c(3))
insert into b1 values (70,54,"")
insert into b1 values (58,54,"")
insert into b1 values (49,86,"")
insert into b1 values (66,86,"")
insert into b1 values (75,96,"")
FOR i=1 TO RECCOUNT()
GO i
kk=''
IF c1>=60
kk=kk+'1'
ENDIF
IF c1<60
kk=kk+'0'
ENDIF
IF c2>=60
kk=kk+'1'
ENDIF
IF c2<60
kk=kk+'0'
ENDIF
GO i
REPLACE m WITH ALLTRIM(kk)
endfor
求简捷的处理方法!
再请教关于行统计的问题:
我的常规处理办法是
create cursor b1 (c1 N(3),c2 N(3),m c(3))
insert into b1 values (70,54,"")
insert into b1 values (58,54,"")
insert into b1 values (49,86,"")
insert into b1 values (66,86,"")
insert into b1 values (75,96,"")
FOR i=1 TO RECCOUNT()
GO i
kk=''
IF c1>=60
kk=kk+'1'
ENDIF
IF c1<60
kk=kk+'0'
ENDIF
IF c2>=60
kk=kk+'1'
ENDIF
IF c2<60
kk=kk+'0'
ENDIF
GO i
REPLACE m WITH ALLTRIM(kk)
endfor
求简捷的处理方法!
一句
REPLACE ALL m WITH IIF(c1<60,"0","1") + IIF(c2<60,"0","1")