Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make third wkt-parametr (axis-order=long-lat) optional for MariaDB compatibility #50

Closed
Surzhikov opened this issue Sep 3, 2022 · 1 comment

Comments

@Surzhikov
Copy link

Unlike MySQL, the WKT-input spatial analysis functions in MariaDB (like ST_GeomFromText and ST_DISTANCE) do not take an options parameter: https://mariadb.com/kb/en/st_geomfromtext/

For this reason, we should get an SQL error, while saving the model with spatial fields:
SQLSTATE[42000]: Syntax error or access violation: 1582 Incorrect parameter count in the call to native function 'ST_GeomFromText'

A similar issue was in grimzy/laravel-mysql-spatial and it was fixed by pull request grimzy/laravel-mysql-spatial#152

@Surzhikov
Copy link
Author

Adding pull request #51

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants