mysql - Does EF fully support ANY cross-platform database? -


for past few hours, tried "port" current project sql server mysql, ended errors like:

the underlying provider not support type varchar(max) (or uniqueidentifier, or else)

i use poco, , code first - thought, 1 of purposes of ef provide easy repository "switching", seam basic types not mapped correctly :/

i tried sqlite in worst shape, , far know, postrage sql support lacking.

so... question - there cross-platform (preferably free) database out there has real (sql server like) support in ef?

thanks in advance.

best regards.

edit:

to more specific approach:

i use poco, , code first, want automatically create database if doesn't exists, don't use special inside poco classes, standard .net types. example poco looks this:

[key] [databasegeneratedattribute(databasegeneratedoption.identity)] public int id { get; set; }  [required] [stringlength(128)] public string name { get; set; }  [required] public int agencyid { get; set; }  [required] public bool isenabled { get; set; }  #region navigationproperties  [navigationproperty] public virtual agency agency { get; set; }  #endregion 

edit2:

my app.config looks this:

<?xml version="1.0" encoding="utf-8"?> <configuration>   <configsections>     <!-- more information on entity framework configuration, visit http://go.microsoft.com/fwlink/?linkid=237468 -->     <section name="entityframework" type="system.data.entity.internal.configfile.entityframeworksection, entityframework, version=6.0.0.0, culture=neutral, publickeytoken=b77a5c561934e089" requirepermission="false" />   </configsections>   <entityframework>     <!--<defaultconnectionfactory type="system.data.entity.infrastructure.sqlconnectionfactory, entityframework" />     <providers>       <provider invariantname="system.data.sqlclient" type="system.data.entity.sqlserver.sqlproviderservices, entityframework.sqlserver" />     </providers>-->     <defaultconnectionfactory type="mysql.data.mysqlclient.mysqlclientfactory, mysql.data" />   </entityframework> </configuration> 

you seem have sqlserver set defaultconnectionfactory in app/wbeb.config file results in ef using sqlserver types. need set defaultconnectionfactory mysql connection factory.


Comments

Popular posts from this blog

android - Get AccessToken using signpost OAuth without opening a browser (Two legged Oauth) -

org.mockito.exceptions.misusing.InvalidUseOfMatchersException: mockito -

google shop client API returns 400 bad request error while adding an item -