Quantcast
Channel: EntityFramework Reverse POCO Code First Generator
Viewing all 1642 articles
Browse latest View live

New Post: From this to WEB API OData for AdventureWorks

$
0
0
Hi, You need to mark the FK's with [JsonIgnore] as you don't want to serialize those links.
    // If you need to serialize your entities with the JsonSerializer from Newtonsoft, this would serialize
    // all properties including the Reverse Navigation and Foreign Keys. The simplest way to exclude them is
    // to use the data annotation [JsonIgnore] on reverse navigation and foreign keys.
    AdditionalReverseNavigationsDataAnnotations = new string[] // Data Annotations for ReverseNavigationProperty.
    {
        "JsonIgnore"
    };  
    AdditionalForeignKeysDataAnnotations = new string[] // Data Annotations for ForeignKeys.
    {
        "JsonIgnore"
    };  

New Post: Marking POCO's serializable?

$
0
0
Is it possible to add the [Serializable] attribute to the generated data classes?

New Post: Marking POCO's serializable?

$
0
0
Yes, use the provided WritePocoClassAttributes callback function in your settings.tt file.

Source code checked in, #720a67d9d92d

$
0
0
Case 177. bit with string as default value always returns true. Thanks to thbaan.

Source code checked in, #582974a54cee

$
0
0
Case 176. Adding Visual Studio Installer Setup Project to Solution causes issues. Thanks to bbieb.

Edited Issue: bit with string as default value always returns true [177]

$
0
0
It is possible to use both the integer values _0_ or _1_ __AND__ the string values _true_ or _false_ as default values for the bit data type in SQL Server.

The T4 template does not handle the string values:

```
Default = (Default == "0") ? "false" : "true";
```
_(EF.Reverse.POCO.Core.ttinclude - line number 823)_

As described, this will return _true_, because the string value is not handled. I would suggest changing to something like this

```
Default = (Default == "0" || Default == "\"false\"") ? "false" : "true";
```

/Thomas

Commented Issue: bit with string as default value always returns true [177]

$
0
0
It is possible to use both the integer values _0_ or _1_ __AND__ the string values _true_ or _false_ as default values for the bit data type in SQL Server.

The T4 template does not handle the string values:

```
Default = (Default == "0") ? "false" : "true";
```
_(EF.Reverse.POCO.Core.ttinclude - line number 823)_

As described, this will return _true_, because the string value is not handled. I would suggest changing to something like this

```
Default = (Default == "0" || Default == "\"false\"") ? "false" : "true";
```

/Thomas

Comments: Thanks thbaan. I've updated the source code and will be in the next version See this [changeset](https://efreversepoco.codeplex.com/SourceControl/changeset/720a67d9d92d).

Commented Unassigned: adding Visual Studio Installer Setup Project to Solution causes issues [176]

$
0
0
Hi Simon,
When adding a Installer Setup Project to a VS2015 Windows Service project, the poco generator fails. I think it is looking for a config file within the installer project. I "attempted" to debug the .tt file but that just added to my confusion. Am I missing something simple?

Severity Code Description Project File Line
Error Running transformation: System.ArgumentNullException: Value cannot be null.
Parameter name: source
at System.Linq.Enumerable.Cast[TResult](IEnumerable source)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConfigPathsInProjectForFile(Project project, String filename)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConfigPathsInProject(Project project)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConfigPaths()
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConnectionString(String& connectionStringName, String& providerName, String& configFilePath)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.InitConnectionString()
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetDbProviderFactory()
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.TransformText() rcrs_server_its C:\_VS2010\GIS_dt_RCRS_Server_ITS\DEV\Src\rcrs_server_its\rcrs_server_its\Data\dot_rcrs.tt 1

Comments: Not sure what VS has done, but it sounds like the expected VS object I get back (to allow me to add/remove files to VS) is null for some reason. Moving the data project out and into its own solution DLL. The reference the data DLL in your installer project. In my company, we use our own NuGet feed. So the data dll would be in its own Nuget package, and can be pulled into any project.

Commented Unassigned: adding Visual Studio Installer Setup Project to Solution causes issues [176]

$
0
0
Hi Simon,
When adding a Installer Setup Project to a VS2015 Windows Service project, the poco generator fails. I think it is looking for a config file within the installer project. I "attempted" to debug the .tt file but that just added to my confusion. Am I missing something simple?

Severity Code Description Project File Line
Error Running transformation: System.ArgumentNullException: Value cannot be null.
Parameter name: source
at System.Linq.Enumerable.Cast[TResult](IEnumerable source)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConfigPathsInProjectForFile(Project project, String filename)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConfigPathsInProject(Project project)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConfigPaths()
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConnectionString(String& connectionStringName, String& providerName, String& configFilePath)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.InitConnectionString()
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetDbProviderFactory()
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.TransformText() rcrs_server_its C:\_VS2010\GIS_dt_RCRS_Server_ITS\DEV\Src\rcrs_server_its\rcrs_server_its\Data\dot_rcrs.tt 1

Comments: I have now replicated the error. working on a fix...

Commented Unassigned: adding Visual Studio Installer Setup Project to Solution causes issues [176]

$
0
0
Hi Simon,
When adding a Installer Setup Project to a VS2015 Windows Service project, the poco generator fails. I think it is looking for a config file within the installer project. I "attempted" to debug the .tt file but that just added to my confusion. Am I missing something simple?

Severity Code Description Project File Line
Error Running transformation: System.ArgumentNullException: Value cannot be null.
Parameter name: source
at System.Linq.Enumerable.Cast[TResult](IEnumerable source)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConfigPathsInProjectForFile(Project project, String filename)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConfigPathsInProject(Project project)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConfigPaths()
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConnectionString(String& connectionStringName, String& providerName, String& configFilePath)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.InitConnectionString()
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetDbProviderFactory()
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.TransformText() rcrs_server_its C:\_VS2010\GIS_dt_RCRS_Server_ITS\DEV\Src\rcrs_server_its\rcrs_server_its\Data\dot_rcrs.tt 1

Comments: Fixed it. Change this function in EF.Reverse.POCO.Core.ttinclude as follows: ``` private List<string> GetConfigPathsInProjectForFile(EnvDTE.Project project, string filename) { try { if (project == null || project.Kind == EnvDTE.Constants.vsProjectKindUnmodeled) { // Project is 'unloaded' return new List<string>(); } return (from ProjectItem item in project.ProjectItems where item.Name.Equals(filename, StringComparison.InvariantCultureIgnoreCase) select Path.Combine(GetProjectPath(project), item.Name)) .ToList(); } catch (Exception) { return new List<string>(); } } ```

Edited Issue: adding Visual Studio Installer Setup Project to Solution causes issues [176]

$
0
0
Hi Simon,
When adding a Installer Setup Project to a VS2015 Windows Service project, the poco generator fails. I think it is looking for a config file within the installer project. I "attempted" to debug the .tt file but that just added to my confusion. Am I missing something simple?

Severity Code Description Project File Line
Error Running transformation: System.ArgumentNullException: Value cannot be null.
Parameter name: source
at System.Linq.Enumerable.Cast[TResult](IEnumerable source)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConfigPathsInProjectForFile(Project project, String filename)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConfigPathsInProject(Project project)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConfigPaths()
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConnectionString(String& connectionStringName, String& providerName, String& configFilePath)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.InitConnectionString()
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetDbProviderFactory()
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.TransformText() rcrs_server_its C:\_VS2010\GIS_dt_RCRS_Server_ITS\DEV\Src\rcrs_server_its\rcrs_server_its\Data\dot_rcrs.tt 1

Edited Issue: Compilation error when generating stored proc return models in POCO assembly [175]

$
0
0
Hi,

Since v2.17.1 I have been able to generate stored proc return models in the POCO assembly. This assembly does not have a reference to EF. However, the new version, v2.17.2, has changed the usings in the generated POCO classes - it now includes "using System.Data.Entity.Infrastructure;" and "using System.Data.Entity.Core.Objects;". The assembly won't build because it does not reference EF. Please can you restore the previous behaviour.

Thanks,
Andy

Commented Issue: adding Visual Studio Installer Setup Project to Solution causes issues [176]

$
0
0
Hi Simon,
When adding a Installer Setup Project to a VS2015 Windows Service project, the poco generator fails. I think it is looking for a config file within the installer project. I "attempted" to debug the .tt file but that just added to my confusion. Am I missing something simple?

Severity Code Description Project File Line
Error Running transformation: System.ArgumentNullException: Value cannot be null.
Parameter name: source
at System.Linq.Enumerable.Cast[TResult](IEnumerable source)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConfigPathsInProjectForFile(Project project, String filename)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConfigPathsInProject(Project project)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConfigPaths()
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetConnectionString(String& connectionStringName, String& providerName, String& configFilePath)
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.InitConnectionString()
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.GetDbProviderFactory()
at Microsoft.VisualStudio.TextTemplating4F7B8D9CDB82346626B41E8D67DD2DF6E5570318C72F9EF6F35975B5ED5379B2557537AE3B4A7D1B71C9DC4CC21B5BB7C9C66D8B92591974F756BB3559A8FB62.GeneratedTextTransformation.TransformText() rcrs_server_its C:\_VS2010\GIS_dt_RCRS_Server_ITS\DEV\Src\rcrs_server_its\rcrs_server_its\Data\dot_rcrs.tt 1

Comments: Perfect! Thanks for your effort on this project. It is a godsend for someone like me who jumps back and forth between coding and managing our GIS. Thanks again. brian

Edited Feature: using DB "newsequentialid()" to help with indexing [174]

$
0
0
We have a database that now has a surrogate key that we use for lookup. We have it set as a "UniqueIdentifier" and have a default value of "newsequentialid()". We want to use the sqeuential id from MSSQL as when when index on the value it will make for better paging. I have changed the code in the core ttinclude to set the column as "IsStoreGenerated" = 1. Here is the code that i have created.

```
CAST(CASE WHEN COLUMNPROPERTY(OBJECT_ID(QUOTENAME(c.TABLE_SCHEMA) + '.' + QUOTENAME(c.TABLE_NAME)), c.COLUMN_NAME, 'IsIdentity') = 1 THEN 1
WHEN COLUMNPROPERTY(OBJECT_ID(QUOTENAME(c.TABLE_SCHEMA) + '.' + QUOTENAME(c.TABLE_NAME)), c.COLUMN_NAME, 'IsComputed') = 1 THEN 1
WHEN DATA_TYPE = 'TIMESTAMP' THEN 1
WHEN DATA_TYPE = 'UNIQUEIDENTIFIER' AND ISNULL(COLUMN_DEFAULT, '') = '(newsequentialid())' THEN 1
ELSE 0
END AS BIT) AS IsStoreGenerated,
```
I did not change the constructor of the class as since the column will now be set to "HasDatabaseGeneratedOption(DatabaseGeneratedOption.Computed)" and EF will ignore the value anyway

Commented Feature: using DB "newsequentialid()" to help with indexing [174]

$
0
0
We have a database that now has a surrogate key that we use for lookup. We have it set as a "UniqueIdentifier" and have a default value of "newsequentialid()". We want to use the sqeuential id from MSSQL as when when index on the value it will make for better paging. I have changed the code in the core ttinclude to set the column as "IsStoreGenerated" = 1. Here is the code that i have created.

```
CAST(CASE WHEN COLUMNPROPERTY(OBJECT_ID(QUOTENAME(c.TABLE_SCHEMA) + '.' + QUOTENAME(c.TABLE_NAME)), c.COLUMN_NAME, 'IsIdentity') = 1 THEN 1
WHEN COLUMNPROPERTY(OBJECT_ID(QUOTENAME(c.TABLE_SCHEMA) + '.' + QUOTENAME(c.TABLE_NAME)), c.COLUMN_NAME, 'IsComputed') = 1 THEN 1
WHEN DATA_TYPE = 'TIMESTAMP' THEN 1
WHEN DATA_TYPE = 'UNIQUEIDENTIFIER' AND ISNULL(COLUMN_DEFAULT, '') = '(newsequentialid())' THEN 1
ELSE 0
END AS BIT) AS IsStoreGenerated,
```
I did not change the constructor of the class as since the column will now be set to "HasDatabaseGeneratedOption(DatabaseGeneratedOption.Computed)" and EF will ignore the value anyway
Comments: This is now implemented and will be in the next release. I modified it slightly, so please see this [changset](https://efreversepoco.codeplex.com/SourceControl/changeset/0807997121d7) and let me know if there are any problems simon@hicrest.net

Commented Issue: ReadStoredProcReturnObject throws an exception if a parameter contains a user defined type [173]

$
0
0
Hi,

The generated query used to work out the return model of a stored proc in invalid if it contains a user defined type.

The tool generates the following query for a stored proc in my database:

```
SET FMTONLY OFF; SET FMTONLY ON;
EXEC [Products].[ShipGoodsOut] @carrier=null, @service=null, @trackingNumber=null, @goodsOutIds=null
SET FMTONLY OFF; SET FMTONLY OFF;
```

The last parameter is a user defined table type:

```
CREATE TYPE [dbo].[Ids] AS TABLE(
[Id] [int] NOT NULL
)
```

Running the generated query gives the following error:

> Msg 206, Level 16, State 2, Procedure ShipGoodsOut, Line 13
Operand type clash: NULL is incompatible with Ids


That causes an exception and means the code required to populate the return model is never generated and so it fallsback to the code required to set the out parameter.

If I change the query such that it looks like this:

```
SET FMTONLY OFF; SET FMTONLY ON;
DECLARE @carrier varchar(25)
DECLARE @service varchar(25)
DECLARE @trackingNumber varchar(25)
DECLARE @goodsOutIds [dbo].[Ids]
EXEC [Products].[ShipGoodsOut] @carrier, @service, @trackingNumber, @goodsOutIds
SET FMTONLY OFF; SET FMTONLY OFF;
```

It works fine.
Comments: Hi Simon, I can confirm that your change works :) Thank you, Andy

Source code checked in, #0807997121d7

$
0
0
Case 174 Using DB "newsequentialid()" to help with indexing. Thanks to mbargar13

Source code checked in, #6da3d185f0d3

$
0
0
Remove Elements.StoredProcedures enum, and replace it with IncludeStoredProcedures boolean flag.

Commented Feature: Minimise usings to the bare minimum required [172]

$
0
0
There are too many using statements which are not required if the code is outputted on a file by file basis.
Comments: Hi, Since v2.17.1 I have been able to generate stored proc return models in the POCO assembly. This assembly does not have a reference to EF. However, the new version, v2.17.2, has changed the usings in the generated POCO classes - it now includes "using System.Data.Entity.Infrastructure;" and "using System.Data.Entity.Core.Objects;". The assembly won't build because it does not reference EF. Please can you restore the previous behaviour. Thanks, Andy

Commented Issue: Compilation error when generating stored proc return models in POCO assembly [175]

$
0
0
Hi,

Since v2.17.1 I have been able to generate stored proc return models in the POCO assembly. This assembly does not have a reference to EF. However, the new version, v2.17.2, has changed the usings in the generated POCO classes - it now includes "using System.Data.Entity.Infrastructure;" and "using System.Data.Entity.Core.Objects;". The assembly won't build because it does not reference EF. Please can you restore the previous behaviour.

Thanks,
Andy
Comments: Thanks Andy This is a duplicate of [case 172](https://efreversepoco.codeplex.com/workitem/172) and is __currently being worked on__. I'll add your note to 172.
Viewing all 1642 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>