thomasnield / oreilly_getting_started_with_sql

Database files for the O'Reilly book "Getting Started with SQL: A hands on approach for beginners" http://goo.gl/z3zG54
411 stars 179 forks source link

Syntax doesn't work as expected #12

Open leoosalles opened 6 months ago

leoosalles commented 6 months ago

On page 51 the author introduces an example of COALESCE() function. But it doesn't work. I mean, there are still NULL fields. Here is the statement:

SELECT * FROM station_data WHERE coalesce(precipitation, 0) <= 0.5; coalesce