主题:[讨论]求助高手
各位大虾们:
小弟有个数据库:结构如下
NO Chass_no slot_no ........
1 Chass_no1 slot1 .....
2 Chass_no2 slot2 .......
3 Chass_no3 slot3 ......
4 Chass_no4 slot2 ......
5 Chass_no2 slot3 ......
. Chass_no1 slot5 ..............
. . .........
第二列和第三列都有重复,我需要查询我需要的Chassis_no的不同slot_no的重复次数,并且要按顺序排列.(slot_no是字符型的)
小弟要做个查询,select cast(kk as int),ww,qq
from(select subspring(slot_no 6,2) as kk,count(slot_no)as ww,slot_no as qq
from Database
where Chassis_no='Chassis1'
group by slot_no)debro
order by kk
怎么转换成vb.net程式.....谢谢
小弟有个数据库:结构如下
NO Chass_no slot_no ........
1 Chass_no1 slot1 .....
2 Chass_no2 slot2 .......
3 Chass_no3 slot3 ......
4 Chass_no4 slot2 ......
5 Chass_no2 slot3 ......
. Chass_no1 slot5 ..............
. . .........
第二列和第三列都有重复,我需要查询我需要的Chassis_no的不同slot_no的重复次数,并且要按顺序排列.(slot_no是字符型的)
小弟要做个查询,select cast(kk as int),ww,qq
from(select subspring(slot_no 6,2) as kk,count(slot_no)as ww,slot_no as qq
from Database
where Chassis_no='Chassis1'
group by slot_no)debro
order by kk
怎么转换成vb.net程式.....谢谢