[MDEV-13363] Query with ST_BUFFER is very slow comparing to MySQL Created: 2017-07-20  Updated: 2017-07-20

Status: Open
Project: MariaDB Server
Component/s: GIS
Affects Version/s: 5.5, 10.0, 10.1, 10.2
Fix Version/s: 10.2

Type: Bug Priority: Minor
Reporter: Elena Stepanova Assignee: Alexey Botchkov
Resolution: Unresolved Votes: 0
Labels: None


 Description   

The query below is almost instant on MySQL 5.6/5.7, but takes ~15 seconds on any of current MariaDB releases.

SELECT ST_BUFFER(
    ST_UNION(
        MULTILINESTRINGFROMTEXT( ' MULTILINESTRING( ( 3 4 , 2 5 , 7 6 , 1 8 ) , ( 0 0 , 1 6 , 0 1 , 8 9 , 2 4 , 6 1 , 3 5 , 4 8 ) , ( 9 3 , 5 4 , 1 8 , 4 2 , 5 8 , 3 0 ) )' ) ,
        MULTILINESTRINGFROMTEXT( ' MULTILINESTRING( ( 3 4 , 3 1 , 2 7 , 4 2 , 6 2 , 1 5 ) ) ' )
    ), 
    AREA(
        MULTIPOLYGONFROMTEXT( ' MULTIPOLYGON( ( ( 7 7 , 6 7, 1 5, 7 6 , 7 7 ) ) , ( (0 5, 3 5, 3 4, 1 4 , 1 3 , 3 3 , 3 0 , 0 0 , 0 5), ( 1 1 , 2 1 , 2 2 , 1 2 , 1 1 ) ) ) ' )
    )
);

Results are also different, though.


Generated at Thu Feb 08 08:05:01 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.