소스 검색

docs: 更新 readme.md

weijianghai 2 년 전
부모
커밋
33dd954f26
1개의 변경된 파일16개의 추가작업 그리고 10개의 파일을 삭제
  1. 16 10
      doc/readme.md

+ 16 - 10
doc/readme.md

@@ -19,13 +19,19 @@ Richr00t#
 ## 统计各小时数据
 
 ```sql
-select
-	rpt_time,
-	count(*)
-from
-	tsfx.dw_sa_omc_ci_h
-group by
-	rpt_time
-order by
-	rpt_time desc
-```
+select rpt_time,
+       count(1)
+from tsfx.dw_sa_omc_ci_h
+group by rpt_time
+order by rpt_time desc;
+```
+
+## 检查重复数据
+```sql
+select nci,
+       count(1)
+from tsfx.dw_sa_omc_ci_h
+where rpt_time = '2022-12-25 19:00:00'
+group by nci
+having count(1) > 1;
+```