728x90
์ด๋ฆ์ด ์๋ ๋๋ฌผ์ ์์ด๋
์ ๋ต
SELECT ANIMAL_ID
FROM ANIMAL_INS
WHERE NAME is null
ORDER BY ANIMAL_ID
๊ด๋ จ ๋ด์ฉ
SKIP
์ด๋ฆ์ด ์๋ ๋๋ฌผ์ ์์ด๋
์ ๋ต
SELECT ANIMAL_ID
FROM ANIMAL_INS
WHERE NAME is not null
ORDER BY ANIMAL_ID
๊ด๋ จ ๋ด์ฉ
SKIP
NULL ์ฒ๋ฆฌํ๊ธฐ
์ ๋ต
SELECT ANIMAL_TYPE, IFNULL(NAME, "No name"), SEX_UPON_INTAKE
FROM ANIMAL_INS
ORDER BY ANIMAL_ID
๊ด๋ จ ๋ด์ฉ
https://velog.io/@gillog/DB-MySQL-NULL-%EC%B2%98%EB%A6%ACIFNULL-CASE-COALESCE
728x90