Sample Header Ad - 728x90

Why is there no max(uuid)/min(uuid) function?

9 votes
3 answers
14085 views
Why can I use a UUID to sort rows: SELECT uuid_nil() ORDER BY 1; But I cannot compute the maximum value: SELECT max(uuid_nil()); > ERROR: function max(uuid) does not exist
Hint: No function matches the given name and argument types. You might need to add explicit type casts. I know that I can cast to a character type or ORDER BY and LIMIT 1. I'm just curious as to why I have to use a workaround.
Asked by xehpuk (327 rep)
Sep 9, 2020, 05:51 PM
Last activity: Oct 24, 2023, 02:13 AM