<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>Question Re: Error on Model generation (Entity Framework Database First ) in Technology Q&amp;A</title>
    <link>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaa-p/13835119#M4865962</link>
    <description>&lt;P&gt;Thank you for your enquiry, 
I installed VS Wizard with SetupVSPackage.exe /i option, I checked also .Net Version: it has to be NET 4.0 in our case, I'm using the ODBC data source to the demo database test connection to which was successfull, in my app.config 
I can see the following lines:&lt;/P&gt;

&amp;lt;configuration&amp;gt;
  &amp;lt;configsections&amp;gt;
    &amp;lt;section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, 
             EntityFramework, Version=4.4.0.0, 
             Culture=neutral, PublicKeyToken=b77a5c561934e089" requirepermission="false"/&amp;gt;
    
  &amp;lt;/configsections&amp;gt;
  &amp;lt;connectionstrings&amp;gt;
    &amp;lt;add name="Entities3" connectionstring="metadata=res://*/Model3.csdl|res://*/Model3.ssdl|res://*/Model3.msl;
         provider=Sap.Data.SQLAnywhere;provider connection string='UserID=dba;Password=sql;
         DataSourceName="SQL Anywhere 17 Demo"'" providername="System.Data.EntityClient"/&amp;gt;
  &amp;lt;/connectionstrings&amp;gt;
  &amp;lt;entityframework&amp;gt;
    &amp;lt;defaultconnectionfactory type="System.Data.Entity.Infrastructure.SqlConnectionFactory, EntityFramework"/&amp;gt;
    &amp;lt;providers&amp;gt;
      &amp;lt;provider invariantname="System.Data.SqlClient" type="System.Data.Entity.SqlServer.SqlProviderServices, 
                EntityFramework.SqlServer"/&amp;gt;
    &amp;lt;/providers&amp;gt;
  &amp;lt;/entityframework&amp;gt;
&amp;lt;/configuration&amp;gt;</description>
    <pubDate>Tue, 14 Feb 2017 13:06:10 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2017-02-14T13:06:10Z</dc:date>
    <item>
      <title>Error on Model generation (Entity Framework Database First )</title>
      <link>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaq-p/13835117</link>
      <description>&lt;P&gt;Hello guys, &lt;/P&gt;
&lt;P&gt;today I tried to generate a model for a provided demo db (Visual Studio 2013 Update 5, Sql Anywhere 17.0.4.2053, Entity framework 5.0.0 ) and I got in the output window of VS the exception :The model was generated with warnings or errors.Model.edmx Please see the Error List for more details. In my edmx file I can see : Errors Found During Generation:
error 6004: The table '.GROUPO.Customers' is referenced by a relationship, but cannot be found.
error 6004: The table '.GROUPO.Contacts' is referenced by a relationship, but cannot be found.
        &amp;lt;Association Name="FK_Contacts_5_Customers" &lt;/P&gt;
&lt;P&gt;What I'm doing wrong?&lt;/P&gt;
&lt;P&gt;Regards, 
Boris&lt;/P&gt;</description>
      <pubDate>Mon, 13 Feb 2017 11:04:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaq-p/13835117</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2017-02-13T11:04:19Z</dc:date>
    </item>
    <item>
      <title>Re: Error on Model generation (Entity Framework Database First )</title>
      <link>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaa-p/13835118#M4865961</link>
      <description>&lt;P&gt;It would be handy to know what steps you are performing. Are you following the Database First to an existing database tutorial at &lt;A href="http://dcx.sap.com/index.html#sqla170/en/html/37fb9e8558e94547b66156b9298be16f.html"&gt;http://dcx.sap.com/index.html#sqla170/en/html/37fb9e8558e94547b66156b9298be16f.html&lt;/A&gt; ?&lt;/P&gt;</description>
      <pubDate>Tue, 14 Feb 2017 10:31:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaa-p/13835118#M4865961</guid>
      <dc:creator>jack_schueler</dc:creator>
      <dc:date>2017-02-14T10:31:25Z</dc:date>
    </item>
    <item>
      <title>Re: Error on Model generation (Entity Framework Database First )</title>
      <link>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaa-p/13835119#M4865962</link>
      <description>&lt;P&gt;Thank you for your enquiry, 
I installed VS Wizard with SetupVSPackage.exe /i option, I checked also .Net Version: it has to be NET 4.0 in our case, I'm using the ODBC data source to the demo database test connection to which was successfull, in my app.config 
I can see the following lines:&lt;/P&gt;

&amp;lt;configuration&amp;gt;
  &amp;lt;configsections&amp;gt;
    &amp;lt;section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, 
             EntityFramework, Version=4.4.0.0, 
             Culture=neutral, PublicKeyToken=b77a5c561934e089" requirepermission="false"/&amp;gt;
    
  &amp;lt;/configsections&amp;gt;
  &amp;lt;connectionstrings&amp;gt;
    &amp;lt;add name="Entities3" connectionstring="metadata=res://*/Model3.csdl|res://*/Model3.ssdl|res://*/Model3.msl;
         provider=Sap.Data.SQLAnywhere;provider connection string='UserID=dba;Password=sql;
         DataSourceName="SQL Anywhere 17 Demo"'" providername="System.Data.EntityClient"/&amp;gt;
  &amp;lt;/connectionstrings&amp;gt;
  &amp;lt;entityframework&amp;gt;
    &amp;lt;defaultconnectionfactory type="System.Data.Entity.Infrastructure.SqlConnectionFactory, EntityFramework"/&amp;gt;
    &amp;lt;providers&amp;gt;
      &amp;lt;provider invariantname="System.Data.SqlClient" type="System.Data.Entity.SqlServer.SqlProviderServices, 
                EntityFramework.SqlServer"/&amp;gt;
    &amp;lt;/providers&amp;gt;
  &amp;lt;/entityframework&amp;gt;
&amp;lt;/configuration&amp;gt;</description>
      <pubDate>Tue, 14 Feb 2017 13:06:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaa-p/13835119#M4865962</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2017-02-14T13:06:10Z</dc:date>
    </item>
    <item>
      <title>Re: Error on Model generation (Entity Framework Database First )</title>
      <link>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaa-p/13835120#M4865963</link>
      <description>&lt;P&gt;I tried with .NET 4.5 &amp;amp; EF6, it works like expected, with this app.config  genaration run successfully : &lt;/P&gt;
&lt;PRE&gt;
&amp;lt;configuration&amp;gt;
  &amp;lt;configsections&amp;gt;
    
    &amp;lt;section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection, EntityFramework, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirepermission="false"/&amp;gt;
  &amp;lt;/configsections&amp;gt;
  &amp;lt;startup&amp;gt;
    &amp;lt;supportedruntime version="v4.0" sku=".NETFramework,Version=v4.5"/&amp;gt;
  &amp;lt;/startup&amp;gt;
  &amp;lt;system.data&amp;gt;
    &amp;lt;dbproviderfactories&amp;gt;
      &amp;lt;clear/&amp;gt;
      &amp;lt;add name="SQL Anywhere 17 Data Provider" invariant="Sap.Data.SQLAnywhere" description=".Net Framework Data Provider for SQL Anywhere 17" type="Sap.Data.SQLAnywhere.SAFactory, Sap.Data.SQLAnywhere.EF6, Version=17.0.0.10094, Culture=neutral, PublicKeyToken=f222fc4333e0d400"/&amp;gt;
    &amp;lt;/dbproviderfactories&amp;gt;
  &amp;lt;/system.data&amp;gt;
  &amp;lt;entityframework&amp;gt;
    &amp;lt;defaultconnectionfactory type="Sap.Data.SQLAnywhere.SAConnectionFactory, Sap.Data.SQLAnywhere.EF6, Version=17.0.0.10094, Culture=neutral, PublicKeyToken=f222fc4333e0d400"&amp;gt;
    &amp;lt;/defaultconnectionfactory&amp;gt;
    &amp;lt;providers&amp;gt;
      &amp;lt;provider invariantname="Sap.Data.SQLAnywhere" type="Sap.Data.SQLAnywhere.SAProviderServices, Sap.Data.SQLAnywhere.EF6, Version=17.0.0.10094, Culture=neutral, PublicKeyToken=f222fc4333e0d400"/&amp;gt;
    &amp;lt;/providers&amp;gt;
  &amp;lt;/entityframework&amp;gt;
&amp;lt;connectionstrings&amp;gt;&amp;lt;add name="Entities" connectionstring="metadata=res://*/Model1.csdl|res://*/Model1.ssdl|res://*/Model1.msl;provider=Sap.Data.SQLAnywhere;provider connection string='UserID=dba;Password=sql;DataSourceName="SQL Anywhere 17 Demo"'" providername="System.Data.EntityClient"/&amp;gt;&amp;lt;/connectionstrings&amp;gt;&amp;lt;/configuration&amp;gt;
&lt;/PRE&gt;

&lt;P&gt;But what should we do, if we use previos versions of sql anywhere /EF ? E.g. I tried to generate model with the following app.config (which failed with foreign keys and navigation properties) : &lt;/P&gt;
&lt;PRE&gt;
&amp;lt;configuration&amp;gt;
  &amp;lt;configsections&amp;gt;
    &amp;lt;section name="entityFramework" type="System.Data.Entity.Internal.ConfigFile.EntityFrameworkSection,  EntityFramework, Version=4.4.0.0,  Culture=neutral, PublicKeyToken=b77a5c561934e089" requirepermission="false"/&amp;gt;
    
  &amp;lt;/configsections&amp;gt;
  &amp;lt;startup&amp;gt;
    &amp;lt;supportedruntime version="v4.0" sku=".NETFramework,Version=v4.0"/&amp;gt;
  &amp;lt;/startup&amp;gt;
  &amp;lt;system.data&amp;gt;
    &amp;lt;dbproviderfactories&amp;gt;
      &amp;lt;clear/&amp;gt;
       &amp;lt;add name="SQL Anywhere 11 Data Provider" invariant="iAnywhere.Data.SQLAnywhere" description=".Net Framework Data Provider for SQL Anywhere 11" type="iAnywhere.Data.SQLAnywhere.SAFactory, iAnywhere.Data.SQLAnywhere.v4.0, Version=11.0.1.29604, Culture=neutral, PublicKeyToken=f222fc4333e0d400"/&amp;gt;
    &amp;lt;/dbproviderfactories&amp;gt;
  &amp;lt;/system.data&amp;gt;
  &amp;lt;entityframework&amp;gt;
    &amp;lt;defaultconnectionfactory type="iAnywhere.Data.SQLAnywhere.SAFactory, iAnywhere.Data.SQLAnywhere.v4.0, Version=11.0.1.29604, Culture=neutral, PublicKeyToken=f222fc4333e0d400"&amp;gt;
    &amp;lt;/defaultconnectionfactory&amp;gt;
    &amp;lt;providers&amp;gt;
      &amp;lt;provider invariantname="iAnywhere.Data.SQLAnywhere" type="iAnywhere.Data.SQLAnywhere.SAProviderServices, iAnywhere.Data.SQLAnywhere.v4.0, Version=11.0.1.29604, Culture=neutral, PublicKeyToken=f222fc4333e0d400"/&amp;gt;
    &amp;lt;/providers&amp;gt;
  &amp;lt;/entityframework&amp;gt;
&amp;lt;connectionstrings&amp;gt;&amp;lt;add name="Entities" connectionstring="metadata=res://*/Model1.csdl|res://*/Model1.ssdl|res://*/Model1.msl;provider=iAnywhere.Data.SQLAnywhere;provider connection string='DataSourceName="SQL Anywhere 11 Demo"'" providername="System.Data.EntityClient"/&amp;gt;&amp;lt;/connectionstrings&amp;gt;&amp;lt;/configuration&amp;gt;
&lt;/PRE&gt;</description>
      <pubDate>Wed, 15 Feb 2017 10:29:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaa-p/13835120#M4865963</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2017-02-15T10:29:13Z</dc:date>
    </item>
    <item>
      <title>Re: Error on Model generation (Entity Framework Database First )</title>
      <link>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaa-p/13835121#M4865964</link>
      <description>&lt;P&gt;I tried also with &lt;BR /&gt;
&amp;lt;entityframework&amp;gt;
    &amp;lt;defaultconnectionfactory type="iAnywhere.Data.SQLAnywhere.SAConnectionFactory, iAnywhere.Data.SQLAnywhere.v4.0, Version=11.0.1.29604, Culture=neutral, PublicKeyToken=f222fc4333e0d400"&amp;gt;
    &amp;lt;/defaultconnectionfactory&amp;gt;
    &amp;lt;providers&amp;gt;
      &amp;lt;provider invariantname="iAnywhere.Data.SQLAnywhere" type="iAnywhere.Data.SQLAnywhere.SAProviderServices, iAnywhere.Data.SQLAnywhere.v4.0, Version=11.0.1.29604, Culture=neutral, PublicKeyToken=f222fc4333e0d400"/&amp;gt;
    &amp;lt;/providers&amp;gt;
  &amp;lt;/entityframework&amp;gt; 
it doesn't work as exprected&lt;/P&gt;</description>
      <pubDate>Wed, 15 Feb 2017 10:41:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaa-p/13835121#M4865964</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2017-02-15T10:41:48Z</dc:date>
    </item>
    <item>
      <title>Re: Error on Model generation (Entity Framework Database First )</title>
      <link>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaa-p/13835122#M4865965</link>
      <description>&lt;P&gt;FWIW, I used a pair of pre-tags to format the code as-is... (but don't know the answer, sorry...)&lt;/P&gt;</description>
      <pubDate>Wed, 15 Feb 2017 10:42:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaa-p/13835122#M4865965</guid>
      <dc:creator>VolkerBarth</dc:creator>
      <dc:date>2017-02-15T10:42:11Z</dc:date>
    </item>
    <item>
      <title>Re: Error on Model generation (Entity Framework Database First )</title>
      <link>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaa-p/13835123#M4865966</link>
      <description>&lt;P&gt;I see you are using Version=11.0.1.29604. &lt;/P&gt;
&lt;P&gt;You'll have to upgrade to a newer version (preferably 17.0) to get the most up-to-date Entity Framework support. Version 11.0.1 and 12.0.1 are no longer supported.&lt;/P&gt;</description>
      <pubDate>Wed, 15 Feb 2017 11:33:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaa-p/13835123#M4865966</guid>
      <dc:creator>jack_schueler</dc:creator>
      <dc:date>2017-02-15T11:33:21Z</dc:date>
    </item>
    <item>
      <title>Re: Error on Model generation (Entity Framework Database First )</title>
      <link>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaa-p/13835124#M4865967</link>
      <description>&lt;P&gt;Thanks for your suggestion and nice formatting, the problem is that some of our customers still use version 11.0.1.X, referred to &lt;A href="https://wiki.scn.sap.com/wiki/display/SQLANY/Using+SQL+Anywhere+and+the+ADO.NET+Entity+Framework"&gt;https://wiki.scn.sap.com/wiki/display/SQLANY/Using+SQL+Anywhere+and+the+ADO.NET+Entity+Framework&lt;/A&gt; it is possible to use EF with Versions up SQL Anywhere 11.0.1.2427,  isn't?&lt;/P&gt;
&lt;P&gt;So how do we have to configure app.config in order to get it working with .NET 4.0 &amp;amp; EF 5.0.0 ?&lt;/P&gt;</description>
      <pubDate>Thu, 16 Feb 2017 04:06:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/error-on-model-generation-entity-framework-database-first/qaa-p/13835124#M4865967</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2017-02-16T04:06:29Z</dc:date>
    </item>
  </channel>
</rss>

