vs2012+entityframework6+mysql server 5.7.2+spatial data geometry issue

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for MySQL
Post Reply
jamesbond
Posts: 1
Joined: Wed 04 Dec 2013 20:14

vs2012+entityframework6+mysql server 5.7.2+spatial data geometry issue

Post by jamesbond » Wed 04 Dec 2013 22:17

Hi there, I am new to the dotConnect for MySQL and entity framework 6. Basically,
1. I use ADO.NET entity data model to generate entity data model from database;
2. I use dotConnect as the mysql server connector to get the entity model out from the mysql;
3. Add generated code item from the entity framework;

I setup it up and I can read non-spatial data without any problems.

However, when I try to update (dbcontext.SaveChanges()) or read the geometry information out from the database (e.g. item.geom.AsText()), the vs2012 gives me a error message saying: This functionality is not supported by Default spatial service.

I double check with the object automatically created by the ADO.NET Entity Data Model, the .net spatial type is:
System.Data.Entity.Spatial.DbGeometry geom { get; set; }

anyone knows how to solve this?

Shalex
Site Admin
Posts: 9543
Joined: Thu 14 Aug 2008 12:44

Re: vs2012+entityframework6+mysql server 5.7.2+spatial data geometry issue

Post by Shalex » Thu 05 Dec 2013 14:52

You can implement enhanced Entity Framework Spatials support in your application in this way: http://blog.devart.com/enhanced-entity- ... resql.html.

We recommend you to use Entity Developer (Devart Entity Model, *.edml) instead of EDM Designer (ADO.NET Entity Data Model, *.edmx) because it is adjusted for working with Oracle and has an advanced functionality: http://www.devart.com/entitydeveloper/ed-vs-edm.html.

Post Reply