Home | 简体中文 | 繁体中文 | 杂文 | Search | ITEYE 博客 | OSChina 博客 | Facebook | Linkedin | 作品与服务 | Email

第 7 章 Functions and Operators

目录

7.1. COUNT
7.2. UUID()
7.3. String
7.3.1. LEFT/RIGHT
7.3.2. RPAD/LPAD
7.3.3. CONCAT
7.3.4. GROUP_CONCAT
7.3.5. replace
7.3.6. SUBSTRING
7.3.7. SUBSTRING_INDEX
7.3.8. AES_ENCRYPT / AES_DECRYPT
7.4. Date and Time
7.4.1. year/month/day hour:minite:second
7.4.2. Unix time
7.4.3. DATE_FORMAT
7.4.4. DATE_SUB/DATE_ADD
7.4.4.1. DATE_ADD
7.4.5. datediff / timediff
7.5. 数值函数
7.5.1. cast 类型转换
7.5.2. truncate 保留小数位数
7.5.3. MOD 求余
7.6. Control Flow Functions

7.1. COUNT

count()

SELECT (SELECT count(1) FROM ecs_category) as 'Export category count',
	(SELECT count(1) FROM ecs_goods) as 'Goods count',
	(SELECT count(1) FROM ecs_goods_attr) as 'Attr count';
		
comments powered by Disqus