3 | | The hash of an expression indeed is take more time than the one of an `int`, but the idea is that this often will still pay off, since the cascade of Case`-`When` essentially forces the database into linear search, while it *might* be possible that a certain database finds a way, if that is not the case, it will first look at the first `When`, if that fails, the next one, etc. so for ~1000 `When`s, it will on average take 500 items per row. |
| 3 | The hash of an expression indeed is take more time than the one of an `int`, but the idea is that this often will still pay off, since the cascade of `Case` - `When` essentially forces the database into linear search, while it *might* be possible that a certain database finds a way, if that is not the case, it will first look at the first `When`, if that fails, the next one, etc. so for ~1000 `When`s, it will on average take 500 items per row. |