sql里 where和order by一起使用是怎样的顺序
where 列2 = ‘条件1’ 这个先执行
过滤后的数据 再order by ‘条件2’
最后取第一条数据
也就是先where 再order by 再limit
where 列2 = ‘条件1’ 这个先执行
过滤后的数据 再order by ‘条件2’
最后取第一条数据
也就是先where 再order by 再limit
Powered by:
博客园
Copyright © 2025 防空洞123
Powered by .NET 9.0 on Kubernetes