select * from Table where (low>=300 and low<=400) or (high>=300 and hight<=400)
是不时要判断是否范围叠加呀 if exists(select 1 from Table where low<=300 and 300<=high ) if exists(select 2 from Table where low<=400 and 400<=high) if exists(select 3 from Table where 300<low and high<400) insert ..... 至于如何替换300和400及判断两变量的关系,请自己做吧
insert ....
if exists(select 1 from Table where low<=300 and 300<=high )
if exists(select 2 from Table where low<=400 and 400<=high)
if exists(select 3 from Table where 300<low and high<400)
insert .....
至于如何替换300和400及判断两变量的关系,请自己做吧