Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 42ab1db

Browse files
committed
백제완: [SQL] Tree Node_241212
1 parent 9e9b8e3 commit 42ab1db

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

‎SQL/14주차/Tree_Node.sql‎

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
SELECT
2+
id
3+
, CASE
4+
WHEN p_id IS NULL THEN 'Root'
5+
WHEN id IN (SELECT p_id FROM Tree) THEN 'Inner'
6+
ELSE 'Leaf'
7+
END `type`
8+
FROM
9+
Tree

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /