By using db<>fiddle, you agree to license everything you submit by Creative Commons CC0.
| version |
|---|
| PostgreSQL 14.5 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 8.5.0 20210514 (Red Hat 8.5.0-10), 64-bit |
5 rows affected
| id | num_a | num_b | suma | denom_b |
|---|---|---|---|---|
| 1 | 1 | 168 | 1 | 168 |
| 2 | 1 | 4 | 17 | 24 |
| 2 | 5 | 24 | 17 | 24 |
| 2 | 6 | 24 | 17 | 24 |
| 3 | 1 | 36 | 1 | 36 |