建立一个表test(id,content)id和content都为varchar2()类型,id为主键
然后添加几条数据
insert into test ('1',null);
insert into test ('2',null);
insert into test ('3',null);
insert into test ('4',null);
insert into test ('5',null);
然后查询
select * from test 的结果(1,2,3,4,5)和
select * from test t order by t.content 的结果(1,2,5,4,3)
竟然是不一样的.
但,我在生产库中也是按一个null值排序的查询就能正常顺序,为什么呢?
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/25941136/viewspace-701320/
,如需转载,请注明出处,否则将追究法律责任。