We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3133219 commit c687c0fCopy full SHA for c687c0f
conditional case.sql
@@ -0,0 +1,13 @@
1
+case - start the condition
2
+when (constraint)
3
+then -> execution
4
+else -> if not above all condition
5
+end -
6
+
7
+select username, case
8
+when rating between 1000 and 1199 then '4 star rated'
9
+when rating betweem 1200 and 1399 then '5 star rated'
10
+when rating between 1400 and 1599 then '6 star rated'
11
+else 'Not a coder.'
12
+end as category
13
+from CODECHEF;
0 commit comments