Re: behavior of GROUP BY with VOLATILE expressions

2024-07-19 Thread Paul George
David: >Only now just grasping that you are trying to group something that is definitionally random. That just doesn't make sense to me. Oh, sorry for the confusion. Yeah, totally. I didn't mean to draw specific attention to GROUP BY -- as you've pointed out elsewhere this issue also exists with

Re: behavior of GROUP BY with VOLATILE expressions

2024-07-19 Thread David G. Johnston
On Fri, Jul 19, 2024 at 2:21 PM Paul George wrote: > Great, thanks for the links and useful past discussions! I figured I > wasn't the first to stumble across this, and it's interesting to see the > issue arise with ORDER BY [VOLATILE FUNC] as well. > > My question was not so much about changing

Re: behavior of GROUP BY with VOLATILE expressions

2024-07-19 Thread Paul George
ed to surface a discussion in [1] regarding the expected behavior >> of GROUP BY with VOLATILE expressions. There seems to be a discrepancy >> between how volatile functions (RANDOM(), also confirmed with TIMEOFDAY()) >> and subqueries are evaluated in groups. In the examples belo

Re: behavior of GROUP BY with VOLATILE expressions

2024-07-19 Thread David G. Johnston
On Fri, Jul 19, 2024 at 7:20 AM Paul George wrote: > > I wanted to surface a discussion in [1] regarding the expected behavior of > GROUP BY with VOLATILE expressions. There seems to be a discrepancy between > how volatile functions (RANDOM(), also confirmed with TIMEOFDAY()) and

behavior of GROUP BY with VOLATILE expressions

2024-07-19 Thread Paul George
Hackers, I wanted to surface a discussion in [1] regarding the expected behavior of GROUP BY with VOLATILE expressions. There seems to be a discrepancy between how volatile functions (RANDOM(), also confirmed with TIMEOFDAY()) and subqueries are evaluated in groups. In the examples below