phoenix-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jon Strayer <>
Subject Race condition around first/last value or group by?
Date Tue, 19 Sep 2017 14:52:22 GMT
I have a SQL query that looks in part like this:

         within GROUP (ORDER BY si.source DESC) AS srcIp,
         within GROUP (ORDER BY si.source DESC) AS srcPort,
         within GROUP (ORDER BY si.source DESC) AS destIp,
         within GROUP (ORDER BY si.source DESC) AS destPort

Sometimes it returns the port values in the ip column and the ip values in the port column.
 If I delete the group by and the first/last sections it seems to work fine.

If I run the query with 2-7 cores it runs fine (1 and 8 fail).

The part about the number of cores effecting the bug makes me pretty sure it’s a race condition
(along with the fact that printing out values changes the bug too).  I’ve looked at the
client code and haven’t seen anything obvious.  And it just occurred to me that I suppose
it could be the server code too.

Has anyone else seen anything like this?

Version numbers:
                sqlline version 1.1.8

Jon Strayer l Sr. Software Engineer
Proofpoint, Inc.
M: 317-440-7938
E: <><>
threat protection l compliance l archiving & governance l secure communication
View raw message