Rucha Deodhar
6c56c92a6c
MDEV-36809: json_array_intersect crashs when unused table ref provided
...
Analysis:
So, there were two problems that needed to be fixed.
1) To fix the crash.
2) After fixing the crash, the result was wrong.
Reason for crash: When we pass the hash to get_intersect_between_arrays(),
We were initialially not passing it value, so the operations were not
performed correctly.
Reason for wrong result: The number of rows that it was returning were same
as that in the table, but, only the first row had correct ouput, rest of
them were NULL (it should also be the result of interection). This was
because we modified the "items" HASH by deleting the "seen" elements.
So for next rows, it did not have the elements it should have in the hash.
Fix:
1) To fix the crash: pass the HASH by reference
2) To fix incorrect result: Maintain a separate "seen" hash, if an item
is found the the "items" hash, delete it ony temporarily and put it in the
seen hash. At then end, put the items from "seen" back into "items" and
reset "seen".
2025-10-14 15:38:17 +11:00
..
2025-09-15 16:17:33 +02:00
2025-05-21 07:36:35 +03:00
2024-11-23 08:14:22 -07:00
2023-09-04 09:36:44 +04:00
2023-07-17 14:56:17 +04:00
2023-07-17 14:56:17 +04:00
2023-11-23 11:52:38 +11:00
2025-09-03 10:32:56 +03:00
2024-08-12 09:32:30 +01:00
2024-10-29 15:24:38 +01:00
2024-10-29 15:24:38 +01:00
2023-10-19 17:24:30 +03:00
2023-10-19 17:24:30 +03:00
2025-06-18 16:46:21 +10:00
2025-09-15 16:17:33 +02:00
2025-09-04 18:08:39 +03:00
2024-01-19 09:07:48 +02:00
2023-12-21 02:14:59 +01:00
2023-07-07 15:15:24 +07:00
2024-04-30 23:09:02 +10:00
2024-04-30 23:09:02 +10:00
2025-06-18 16:46:21 +10:00
2024-12-02 11:35:34 +02:00
2024-06-24 13:09:47 +03:00
2024-06-20 11:32:13 -04:00
2023-06-27 17:43:31 +03:00
2024-11-29 12:37:46 +02:00
2024-11-29 12:37:46 +02:00
2025-09-04 18:08:39 +03:00
2024-10-30 15:11:17 +01:00
2023-08-22 13:42:42 +04:00
2025-01-30 12:01:11 +01:00
2025-09-15 16:17:33 +02:00
2025-09-03 10:32:56 +03:00
2024-12-02 11:35:34 +02:00
2025-09-15 16:17:33 +02:00
2023-12-21 02:14:59 +01:00
2024-05-30 16:04:00 +03:00
2024-06-20 11:32:13 -04:00
2024-10-15 15:36:12 +11:00
2024-01-27 12:09:54 +01:00
2024-01-27 12:09:54 +01:00
2024-10-03 13:45:26 +03:00
2025-10-09 13:37:45 +03:00
2025-09-15 16:17:33 +02:00
2025-03-28 13:55:21 +02:00
2025-02-27 04:02:33 +01:00
2025-09-04 18:08:39 +03:00
2025-09-15 16:17:33 +02:00
2025-09-24 13:40:09 +03:00
2024-11-29 13:43:17 +02:00
2025-09-15 16:17:33 +02:00
2025-09-15 16:17:33 +02:00
2024-12-02 11:35:34 +02:00
2024-12-05 10:11:58 +01:00
2025-09-15 16:17:33 +02:00
2025-09-03 10:32:56 +03:00
2025-03-27 08:01:47 +02:00
2024-10-29 15:24:38 +01:00
2025-10-14 15:38:17 +11:00
2025-10-14 15:38:17 +11:00
2024-07-16 15:54:22 +08:00
2024-07-16 15:54:22 +08:00
2025-09-15 16:17:33 +02:00
2025-09-03 10:32:56 +03:00
2025-09-15 16:17:33 +02:00
2025-07-22 06:46:56 +11:00
2025-09-04 18:08:39 +03:00
2025-09-04 18:08:39 +03:00
2025-09-15 16:17:33 +02:00
2025-09-03 10:32:56 +03:00
2024-10-08 11:58:46 +02:00
2024-10-29 15:24:38 +01:00
2024-07-22 15:14:50 +02:00
2025-04-18 14:54:48 +04:00
2025-09-30 12:06:31 +03:00
2025-09-15 16:17:33 +02:00
2025-09-03 10:32:56 +03:00
2024-12-02 11:35:34 +02:00
2024-12-02 11:35:34 +02:00
2025-07-05 10:47:44 +10:00
2024-12-02 11:35:34 +02:00
2025-07-28 19:40:10 +02:00
2025-07-09 08:57:47 +10:00
2024-11-29 13:43:17 +02:00
2024-11-23 08:14:22 -07:00
2024-07-08 22:40:16 +02:00
2023-07-17 14:56:17 +04:00
2024-06-17 12:02:03 +03:00
2024-06-17 15:46:39 +04:00
2025-04-26 10:53:02 +02:00
2024-05-21 19:38:51 +02:00
2023-11-14 18:33:03 +01:00
2023-08-29 14:19:38 +04:00
2025-04-26 10:53:02 +02:00
2025-01-09 07:58:08 +02:00
2024-01-16 18:53:23 +04:00
2025-10-09 13:37:45 +03:00
2025-01-30 12:01:11 +01:00
2025-09-02 15:58:39 +02:00
2023-10-03 08:25:31 +03:00
2025-09-15 16:17:33 +02:00
2025-09-15 16:17:33 +02:00
2025-09-04 18:08:39 +03:00
2025-09-15 16:17:33 +02:00
2024-09-18 07:38:49 +03:00
2025-09-15 16:17:33 +02:00
2024-12-02 11:35:34 +02:00
2023-11-08 16:23:30 +01:00
2023-11-08 14:50:43 +01:00
2024-11-29 12:37:46 +02:00
2024-05-30 16:04:00 +03:00
2025-04-15 18:58:32 +02:00
2025-05-26 12:02:50 +02:00
2025-09-15 16:17:33 +02:00
2025-03-28 13:55:21 +02:00
2025-03-28 13:55:21 +02:00
2024-05-21 19:38:51 +02:00
2025-02-10 22:06:49 +02:00
2025-06-09 21:15:30 +03:00
2025-07-27 15:18:00 +02:00
2025-09-15 16:17:33 +02:00
2025-03-03 11:07:56 +02:00
2024-01-26 06:37:37 +04:00
2024-01-26 06:37:37 +04:00
2023-09-12 17:14:43 +03:00
2025-09-15 16:17:33 +02:00
2025-09-15 16:17:33 +02:00
2025-09-15 16:17:33 +02:00
2025-09-15 16:17:33 +02:00
2025-09-04 18:08:39 +03:00
2025-04-27 22:16:17 -04:00
2024-12-02 11:35:34 +02:00
2025-06-18 16:46:21 +10:00
2024-06-24 13:09:47 +03:00
2024-11-29 13:43:17 +02:00
2023-07-27 19:43:45 +03:00
2024-02-03 11:22:21 +01:00
2024-03-09 00:40:03 +01:00
2024-07-16 15:54:22 +08:00
2025-04-11 23:57:47 +10:00
2025-04-11 23:57:47 +10:00
2024-12-02 11:35:34 +02:00
2024-06-24 13:09:47 +03:00
2024-02-04 22:19:19 +01:00
2025-09-15 16:17:33 +02:00
2025-09-15 16:17:33 +02:00
2025-09-04 18:08:39 +03:00
2024-07-22 15:14:50 +02:00
2025-07-28 19:40:10 +02:00
2025-07-28 19:40:10 +02:00
2025-09-04 18:08:39 +03:00
2025-04-11 13:42:12 +02:00
2025-04-26 10:53:02 +02:00
2025-04-26 10:53:02 +02:00
2025-07-28 19:40:10 +02:00
2025-07-07 14:03:49 -06:00
2025-09-15 16:17:33 +02:00
2023-08-15 10:16:13 +02:00
2025-01-30 12:01:11 +01:00
2025-09-15 16:17:33 +02:00
2023-10-26 20:45:35 +02:00
2023-08-15 10:16:13 +02:00
2023-11-02 13:18:50 +07:00
2023-11-02 13:18:50 +07:00
2024-10-29 15:24:38 +01:00
2024-03-05 20:19:49 +02:00
2025-07-28 19:40:10 +02:00
2025-07-08 16:41:12 +02:00
2025-04-23 17:20:47 -06:00
2025-04-23 17:20:47 -06:00
2025-01-29 11:17:38 +01:00
2024-12-02 11:35:34 +02:00
2024-12-02 11:35:34 +02:00
2024-12-02 11:35:34 +02:00
2024-12-05 11:01:42 +01:00
2025-03-31 18:37:06 +02:00
2023-07-17 14:56:17 +04:00
2025-09-15 16:17:33 +02:00
2023-05-02 10:09:27 +02:00
2024-01-23 13:03:11 +02:00
2024-01-23 13:03:11 +02:00
2024-12-02 11:35:34 +02:00
2025-09-24 13:40:09 +03:00
2025-01-30 11:55:13 +01:00
2025-07-02 17:50:24 +07:00
2025-07-02 17:50:24 +07:00
2025-09-15 16:17:33 +02:00
2025-02-09 13:56:19 +04:00
2023-07-20 17:46:45 +07:00
2024-12-02 11:35:34 +02:00
2024-12-02 11:35:34 +02:00
2024-06-24 13:09:47 +03:00
2025-09-04 18:08:39 +03:00
2025-10-01 07:24:54 +03:00
2025-01-14 23:45:41 +01:00
2025-07-22 20:58:07 +02:00
2024-06-24 13:09:47 +03:00
2025-01-30 12:01:11 +01:00
2025-01-30 12:01:11 +01:00
2024-11-29 12:37:46 +02:00
2024-11-29 12:37:46 +02:00
2023-07-26 15:13:06 +03:00
2025-02-10 22:06:49 +02:00
2024-11-29 13:43:17 +02:00
2025-09-18 18:01:33 +02:00
2025-10-09 13:37:45 +03:00
2025-04-26 10:53:02 +02:00
2025-09-04 18:08:39 +03:00
2024-01-18 19:22:23 +02:00
2025-09-15 16:17:33 +02:00
2024-04-23 14:12:31 +03:00
2025-04-26 10:53:02 +02:00
2024-12-02 11:35:34 +02:00
2025-10-07 13:01:57 +03:00
2025-09-15 16:17:33 +02:00
2025-04-14 12:56:39 -04:00
2025-09-15 16:17:33 +02:00
2024-10-03 13:24:43 +03:00
2025-09-24 13:40:09 +03:00
2025-09-04 18:08:39 +03:00
2024-01-10 18:01:46 +11:00
2025-06-27 22:04:14 +05:30
2025-06-27 22:04:14 +05:30
2025-03-03 11:07:56 +02:00
2025-03-03 11:07:56 +02:00
2025-09-24 13:40:09 +03:00
2025-04-14 12:56:39 -04:00
2024-08-03 09:32:42 +02:00
2024-10-17 21:37:37 +02:00
2025-09-15 10:49:57 +10:00
2024-08-21 09:30:54 +02:00
2025-09-24 13:40:09 +03:00
2025-09-24 13:40:09 +03:00
2025-09-04 18:08:39 +03:00
2024-06-20 11:32:13 -04:00
2024-06-27 10:26:09 +03:00
2025-01-09 07:58:08 +02:00
2024-10-30 15:11:17 +01:00
2024-11-29 12:37:46 +02:00
2025-09-24 13:40:09 +03:00
2025-09-19 12:31:14 +03:00
2025-09-15 16:17:33 +02:00
2025-09-04 18:08:39 +03:00
2025-09-15 16:17:33 +02:00
2025-10-07 13:01:57 +03:00
2024-11-23 08:14:22 -07:00
2023-05-23 12:25:39 +03:00
2025-07-29 13:15:02 +10:00
2025-09-02 15:58:39 +02:00
2024-06-17 15:46:39 +04:00
2025-04-16 12:55:49 +04:00
2024-04-15 18:54:30 +02:00
2025-10-09 13:37:45 +03:00
2025-07-05 10:47:44 +10:00
2025-08-25 18:36:33 +02:00
2024-07-03 12:45:30 +02:00
2025-09-15 16:17:33 +02:00
2023-08-04 08:01:06 +02:00
2025-07-29 13:15:02 +10:00
2025-01-30 11:55:13 +01:00
2025-10-09 13:37:45 +03:00
2024-12-30 16:13:20 +02:00
2025-09-24 13:40:09 +03:00
2023-11-05 23:35:31 +04:00
2025-02-10 21:14:01 +02:00
2023-12-17 11:20:43 +01:00
2023-12-17 11:20:43 +01:00
2025-10-09 13:37:45 +03:00
2025-09-04 18:08:39 +03:00
2025-01-30 12:01:11 +01:00
2024-07-10 18:50:08 +03:00
2024-06-20 11:32:13 -04:00
2023-12-02 01:02:50 +01:00
2025-10-07 13:01:57 +03:00
2025-09-15 16:17:33 +02:00
2025-07-07 13:00:18 +03:00
2025-09-04 18:08:39 +03:00
2025-10-09 13:37:45 +03:00
2025-09-24 13:40:09 +03:00
2024-06-20 11:32:13 -04:00
2024-06-20 11:32:13 -04:00
2025-09-15 16:17:33 +02:00
2025-09-15 16:17:33 +02:00
2025-09-04 18:08:39 +03:00
2024-03-28 10:51:36 +02:00
2025-09-16 17:01:39 +03:00
2025-09-15 16:17:33 +02:00
2025-07-22 11:30:39 -06:00
2024-06-17 15:46:39 +04:00
2025-09-15 16:17:33 +02:00
2023-09-30 14:43:12 +02:00
2025-03-03 11:07:56 +02:00
2025-01-30 12:01:11 +01:00
2025-03-27 08:01:47 +02:00
2024-06-20 11:32:13 -04:00
2025-09-15 16:17:33 +02:00
2023-09-25 13:06:57 +10:00
2025-09-03 10:32:56 +03:00
2023-10-14 13:36:11 +03:00
2024-01-18 19:22:23 +02:00
2023-08-01 15:08:52 +02:00
2023-07-04 16:37:29 +02:00
2024-01-26 06:37:37 +04:00
2025-09-03 10:32:56 +03:00
2025-09-15 16:17:33 +02:00
2024-12-02 11:35:34 +02:00
2024-11-23 08:14:23 -07:00
2025-10-08 17:14:59 +11:00
2025-09-15 16:17:33 +02:00
2025-04-14 12:56:39 -04:00
2023-07-17 14:56:17 +04:00
2025-04-26 10:53:02 +02:00
2025-10-01 07:24:54 +03:00
2024-06-20 11:32:13 -04:00
2025-07-28 19:40:10 +02:00
2025-03-28 13:55:21 +02:00
2024-06-20 11:32:13 -04:00
2025-09-29 08:25:37 +03:00
2025-09-16 17:01:39 +03:00
2025-04-29 15:05:20 +04:00
2024-01-10 18:01:46 +11:00
2025-09-24 13:40:09 +03:00
2025-10-07 13:01:57 +03:00
2025-09-15 16:17:33 +02:00
2023-12-02 01:02:50 +01:00
2024-11-05 21:32:48 +01:00
2025-05-20 17:27:05 +03:00
2024-06-20 11:32:13 -04:00
2024-03-19 11:57:38 +01:00
2025-09-04 18:08:39 +03:00
2024-06-24 13:09:47 +03:00
2025-07-28 19:40:10 +02:00
2025-09-15 16:17:33 +02:00
2024-02-15 13:53:21 +01:00
2025-05-21 09:47:55 +02:00
2024-12-02 11:35:34 +02:00
2024-12-02 11:35:34 +02:00
2025-07-28 19:40:10 +02:00
2024-05-21 19:38:51 +02:00
2025-04-26 10:53:02 +02:00
2024-02-21 13:08:23 +02:00
2025-09-10 15:03:59 +03:00
2025-09-15 16:48:10 +02:00
2024-09-01 02:58:27 +02:00
2023-11-21 15:43:20 +01:00
2025-04-02 10:15:08 +03:00
2024-06-20 11:32:13 -04:00
2024-06-20 11:32:13 -04:00
2024-01-02 17:37:58 +02:00
2025-04-02 10:15:08 +03:00
2024-06-20 11:32:13 -04:00
2024-06-27 10:26:09 +03:00
2025-10-07 13:01:57 +03:00
2025-05-26 08:10:47 +03:00
2024-05-10 20:02:18 +02:00
2023-09-29 12:54:04 +02:00
2024-01-03 15:55:17 +02:00
2023-08-08 03:25:56 +02:00
2025-10-09 07:09:33 +03:00
2025-01-30 11:55:13 +01:00
2025-04-02 04:43:24 +02:00
2024-09-01 02:48:19 +02:00
2024-10-03 13:24:43 +03:00
2024-09-09 13:50:38 +03:00
2025-04-02 10:15:08 +03:00
2024-06-20 11:32:13 -04:00
2025-09-04 18:08:38 +03:00
2025-04-02 04:50:11 +02:00
2025-03-27 08:01:47 +02:00
2024-10-29 15:24:38 +01:00
2023-10-14 13:36:11 +03:00
2025-09-29 08:25:37 +03:00
2025-03-03 11:07:56 +02:00
2025-10-08 14:15:04 +03:00
2025-02-18 19:30:04 +01:00
2025-07-28 19:40:10 +02:00
2024-10-16 13:23:47 +02:00