Welcome Guest, Not a member yet? Register   Sign In
Support for spatial data types and functions
#1

I would like to add support for spatial data types and functions. Is it possible to extend the classes in the system / database folder and create a composer package? From my tests it doesn't seem possible ...
Codeigniter 4 - Docker Image [github] [docker hub]
Reply
#2

Last I heard there was not a meaningful way to *replace* a database driver with your own, but you can easily define your own driver as an extension of the existing one(s) and add whatever you want to it. Then in your database Config just select the new driver:

'DBDriver' => 'SpatialMySQL'

Also check out @kenjis Pull Request for RawSql support because it is possible that will allow you to do spatial handling without a separate driver.
Reply
#3

(06-19-2022, 03:31 AM)MGatner Wrote: Last I heard there was not a meaningful way to *replace* a database driver with your own, but you can easily define your own driver as an extension of the existing one(s) and add whatever you want to it. Then in your database Config just select the new driver:

'DBDriver' => 'SpatialMySQL'

Also check out @kenjis Pull Request for RawSql support because it is possible that will allow you to do spatial handling without a separate driver.

Obviously my approach was wrong. Thank you very much: I will work following your advice.
Codeigniter 4 - Docker Image [github] [docker hub]
Reply




Theme © iAndrew 2016 - Forum software by © MyBB