EntityFramework-Reverse-POCO-Code-First-Generator icon indicating copy to clipboard operation
EntityFramework-Reverse-POCO-Code-First-Generator copied to clipboard

Configuration / Data Types for Stored Procedure Return Model

Open MarkLFT opened this issue 2 years ago • 4 comments

I have noticed that stored procedures do not define a configuration class for the return model. This causes warnings because of data types and precision. Specifically, one of our databases makes extensive use of Money type fields in the database, and we need to inform EF of the underlying data type to prevent the warnings.

Is there a setting I am missing that creates the config classes for stored procedure return classes? If not, what is the recommended way to resolve this issue?

Thanks

MarkLFT avatar Nov 05 '22 04:11 MarkLFT

I have recreated the problem

sjh37 avatar Nov 08 '22 10:11 sjh37

I am also experiencing this issue. Since we use a lot of decimal types in stored procedures and functions, EF generates a TON of model validation warnings on startup / ModelValidation. I am using 3.7.0, and EFCore 6. I was hoping there was a workaround.

Pricejd avatar Mar 04 '23 19:03 Pricejd

Still having this problem in 3.9.0

rcheung9 avatar Jun 10 '24 07:06 rcheung9

I am still working on it. This is due to an error being returned from SQL Server when using #temp' tables as part of the return data. As a fallback if I receive an error, am implementing the use of sp_describe_first_result_set` which will correctly return the columns.

sjh37 avatar Jun 10 '24 12:06 sjh37