Null values
CoddyのSQLジャーニー「基礎」セクションの一部 — レッスン 12/72。
現実の世界では、値が存在しないフィールドが存在する場合があります。値を持たないフィールドは `NULL` と呼ばれます。
関連するデータを取得するために、IS NULL または IS NOT NULL を使用してクエリを操作できます
例えば、次のクエリは col1 に値がないすべてのレコードを返します:
SELECT *
FROM table1
WHERE col1 IS NULLチャレンジ
簡単利用可能なテーブルとカラム:
<strong>people</strong>:<strong>name</strong>
欠損値(`NULL`)を含まないユニークな名前(`name`)をすべて取得してください。
自分で試してみよう
このレッスンには短いクイズがあります。レッスンを始めて解答し、進捗を記録しましょう。
基礎のすべてのレッスン
4More Keywords
The IN keywordThe BETWEEN keywordThe LIKE keywordThe AS keywordRecap - Cellphone Models2Conditions
Conditions BasicsThe AND keywordThe OR keywordThe NOT keywordMultiple Conditions CombinedParenthesisBooleans5Arithmetic Operations
Mathematical OperatorsMathematical ColumnsThe Modulo OperationThe ROUND() Function3Specific Return Format
Null valuesSort Results Part 1Sort Results Part 2Recap - Cyber Security FirmLimit number of recordsRecap - Vehicle Factory6Intro Challenges
Recap - Parliamentary ElectionRecap - Police Criminal ArrestRecap - Bar Beverage ContainerRecap - Engineer new columns