Oracle Code First Migraitons - Varchar2

Discussion of open issues, suggestions and bugs regarding Entity Framework support in ADO.NET Data providers
Post Reply
ndroe
Posts: 18
Joined: Fri 03 Feb 2012 16:08

Oracle Code First Migraitons - Varchar2

Post by ndroe » Thu 21 Jun 2012 20:09

Is there any way to get the code first migrator create columns of type "VARCHAR2(10 BYTE)" instead of "VARCHAR2(10 CHAR)"?

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

Re: Oracle Code First Migraitons - Varchar2

Post by Shalex » Fri 22 Jun 2012 14:15

As far as we concerned, a user expects that the datatype with 10 chars will be created in the database after setting the 10 symbols limitation for the string property of .NET class.

The BYTE semantics allows the situation when the database could have more strict length limitation for the column than the one for the corresponding .NET property. As a result, a string value could not be inserted into the database although it passed validation at the .NET level.

Post Reply