mysql - MySQL 条件排序
问题描述
假设我的users
表中有以下数据。
name | score
John | 2
Dave | 8
Joe | -3
Sally | -20
Rose | 0
如何按分数列对以下格式的用户进行排序?
John, Dave, Rose, Sally and Joe
换句话说,那些得分为正的用户应该首先升序,然后是 0,然后是负分的升序。
解决方案
推荐阅读
- python - 更新日志中的函数名称
- react-hooks - React admin authProvider.login not defined
- angularjs - Unable to write a pdf base64 encoded file into android and ios device using ionic-native/file plugin
- docker - 将文件从 GCP 复制到 docker 容器
- c# - 按嵌套列表对列表进行分组并删除与组不对应的元素
- java - “节点流”和“过滤流”有什么区别?
- c# - 问:在 wpf 中的窗口之间传递字符串
- javascript - 如何构建动态包含标题的语义用户界面下拉列表?
- reactjs - TypeError: eleves.map 不是函数 React/Spring-boot 无法显示 @ManyToOne 关系
- c# - 如何使用 .NET HttpClient 获取服务器证书无效的原因?