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

MySQL Spatial Data Types #660

Closed
normancesar opened this Issue Aug 9, 2016 · 0 comments

Comments

2 participants
@normancesar

normancesar commented Aug 9, 2016

Hi,

We have recently added some Spatial Data Types to our MySQL database and it caused some issues (models failed).

A quick search found the issue raised about SQL Server
https://groups.google.com/forum/#!topic/cfwheels/eO2N9YITEac

And the fix by xxrxndxvxs (Aaron) and implemented by ellor1138 in #145.

I found implementing a similar fix in /wheels/models/adapters/MySQL.cfc fixed my issues.

I have added all the Spatial Data Types listed here to return as binary
https://dev.mysql.com/doc/refman/5.7/en/spatial-datatypes.html

Here is the code snippet change in $getType().

case "binary": case "geometry": case "point": case "linestring": case "polygon": case "multipoint": case "multilinestring": case "multipolygon": case "geometrycollection":
                    loc.rv = "cf_sql_binary";
                    break;

Thanks

Norman

@perdjurner perdjurner added the bug label Aug 11, 2016

@perdjurner perdjurner added this to the 2.0.0 milestone Aug 11, 2016

@perdjurner perdjurner self-assigned this Aug 11, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment