摘要:
import java.util.*; public class Main{ public static void main(String[] args){ Scanner sc = new Scanner(System.in); while(sc.hasNext()){ String num = sc.nextLine(); ... 阅读全文
摘要:
编写顺序: select → form → where → group by → having → order by → limit 执行顺序: from → on → join → where → group by → 聚合函数 →with rollup → having → select → d 阅读全文
摘要:
实际应用中,会遇到需要把表的某些行转换成列,或者把列转换成行的情况。比如一张表在数据库中是这样的: 图1 但是,需要的结果可能是这样: 图2 这个时候就得行列转换了。 1.行转列的几种方法 1.1 case ... when ... then ... else ... end 另一种写法: 另外若省 阅读全文