tuhaihe commented on issue #1395:
URL: https://github.com/apache/cloudberry/issues/1395#issuecomment-3410156286

   Hi @hw118118 I tried the latest patch, it tested well on the demo env:
   
   ```sql
   distributed_crash_test=# SELECT
       a.id,
       COUNT(b.id) as contained_points
   FROM distributed_geoms a, distributed_geoms b
   WHERE a.id <= 5 AND ST_Contains(ST_Buffer(a.geom, 10), b.geom)
   GROUP BY a.id
   ORDER BY a.id;
    id | contained_points
   ----+------------------
     1 |                8
     2 |                9
     3 |               10
     4 |               11
     5 |               12
   (5 rows)
   
   distributed_crash_test=# SELECT
       a.id,
       ST_Area(ST_Intersection(a.large_geom, b.large_geom)) as intersection_area
   FROM toast_geoms a, toast_geoms b
   WHERE a.id < b.id
     AND a.id <= 5
     AND b.id <= 10
     AND ST_Intersects(a.large_geom, b.large_geom)
   LIMIT 10;
    id | intersection_area
   ----+--------------------
     5 |  64.44202461524796
     5 | 25.150801571120464
     5 | 14.268293279551697
     5 |   50.6346855984039
     5 |  37.42066563719037
     1 | 25.150801571120464
     1 |  64.44202461524806
     1 | 14.268293279551695
     1 | 50.634685598403884
     1 | 37.420665637190325
   (10 rows)
   
   distributed_crash_test=# SELECT
       a.id,
       COUNT(b.id) as contained_points
   FROM replicated_geoms a, replicated_geoms b
   WHERE a.id <= 5 AND ST_Contains(ST_Buffer(a.geom, 10), b.geom)
   GROUP BY a.id
   ORDER BY a.id;
    id | contained_points
   ----+------------------
     1 |                8
     2 |                9
     3 |               10
     4 |               11
     5 |               12
   (5 rows)
   
   
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to