EDM MySQL Enums

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for MySQL
Post Reply
pleb
Posts: 37
Joined: Mon 23 Jun 2008 06:21
Location: Melbourne, Australia

EDM MySQL Enums

Post by pleb » Mon 23 Jun 2008 06:31

Hi everyone,

Does anyone know away to get around the lack of enum support in the entity framework?

Thanks pleb

pleb
Posts: 37
Joined: Mon 23 Jun 2008 06:21
Location: Melbourne, Australia

Post by pleb » Mon 23 Jun 2008 11:02

I'm not sure how to proceed because any table that contains an ENUM (and I guess SET) can't be used. Sure you can use every column bar that those ones, but this isn't a good situation to be in.

I wondering if you could make sense to convert MySQL Enum or Set to type string? I envision ENUM would be plain old string and SET would be comma separated string.

At least this way you would work with tables which contain these types. I read awhile ago that Enum support in the EDM isn't planned until version 2, so a long way off. I guess SET (ENUM with flags) would be never.

What do you think?

Pleb

anton.connect
Posts: 43
Joined: Thu 19 Jun 2008 14:30

Post by anton.connect » Tue 24 Jun 2008 10:22

At this moment Microsoft doesn't support ENUM type.
We are planning that kind of support in future, but it definitely will not be in the nearest build.

pleb
Posts: 37
Joined: Mon 23 Jun 2008 06:21
Location: Melbourne, Australia

Post by pleb » Tue 24 Jun 2008 11:21

I bet they would have supported it if their SQL Server had it as a native type :evil:

Alexey.mdr
Posts: 729
Joined: Thu 13 Dec 2007 10:24

Post by Alexey.mdr » Thu 26 Jun 2008 09:46

Hello,

we are investigating the possibility of implementing ENUM support in MyDirect .NET.
Please note, this may take some time.

Regards,
Alexey.

pleb
Posts: 37
Joined: Mon 23 Jun 2008 06:21
Location: Melbourne, Australia

Post by pleb » Thu 26 Jun 2008 10:57

Hi Alexey

Yeah I figure this would be a tuff one. May I suggest the conversion to a string type for the following reasons. When MS do implement Enum support you don't want be stuck supporting two implementations. An Enum can easily be converted to a string. You've already got support for an the string type.

Regards,

Pleb

Alexey.mdr
Posts: 729
Joined: Thu 13 Dec 2007 10:24

Post by Alexey.mdr » Thu 26 Jun 2008 15:49

Hello Pleb,

Your suggestion is reasonable and it's likely we will stick to the idea,
because it is the most natural way.
Apparently, we will implement ENUMs in the next build which is planned to be release in tree - four weeks.

Regards,
Alexey

AndreyR
Devart Team
Posts: 2919
Joined: Mon 07 Jul 2008 13:16

Post by AndreyR » Thu 24 Jul 2008 06:46

Hello, Pleb.

The ENUM and SET types are implemented and will be available in the next build.
By the way, if you have any more suggestions on the Entity Framework support, feel free to tell us, your help wil be appreciated.

Regards, Andrey.

pleb
Posts: 37
Joined: Mon 23 Jun 2008 06:21
Location: Melbourne, Australia

Post by pleb » Thu 24 Jul 2008 07:49

Sounds great Alexey,

thanks for providing enum support, it will surely be used ;)

Pleb

Post Reply