Commit c2590fb
committed
[FIX] util/records: avoid row-based
While using row-based `IS {,NOT} NULL`, especially after doing
LEFT JOIN we need to be very carefull as:
1. IS NULL = true if the `row is NULL OR all columns are NULL`[^1]
2. IS NOT NULL = true if the `row is NOT NULL AND all columns are NOT
NULL`[^1]
So for making it safe, we used `t2.<column> IS NOT NULL` instead
of `t2 IS NOT NULL` when the <column> was used while joining
ref: odoo/upgrade#8957
[^1]: https://www.postgresql.org/docs/12/functions-comparison.html
closes #361
Signed-off-by: Christophe Simonis (chs) <[email protected]>IS NOT NULL
1 parent 6fbf957 commit c2590fb
1 file changed
+2
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1744 | 1744 | | |
1745 | 1745 | | |
1746 | 1746 | | |
1747 | | - | |
| 1747 | + | |
1748 | 1748 | | |
1749 | 1749 | | |
1750 | 1750 | | |
1751 | 1751 | | |
| 1752 | + | |
1752 | 1753 | | |
1753 | 1754 | | |
1754 | 1755 | | |
| |||
0 commit comments