Last post Dec 24, 2014 12:10 AM by sw-ing
Dec 23, 2014 06:03 AM|bhushan_microsoft|LINK
I wrote stored PRocedure In Which I aM Using Temp Table..I Want To Return Temp Table.when I am Going To Retrieve Temp Table Through Entoty Framework Ia m Getting Above Message....
Please give Me Solution
Dec 23, 2014 06:36 AM|Webblogsforyou2013|LINK
What is the error message? Show your code and procedure as well.
Dec 23, 2014 06:38 AM|Mikesdotnetting|LINK
EF is having difficulty working out that your procedure returns. To get round that, you make it clear by providing a SELECT statement that will never execute but will tell EF what columns and data types to expect. The accepted answer in this thread (http://stackoverflow.com/questions/16593473/ef-cant-infer-return-schema-from-stored-procedure-selecting-from-a-temp-table)
calls it a Faux Data Contract. Here's a blog article where the solution is also discussed and applied: http://jacstech.wordpress.com/2013/09/27/getting-entity-framework-to-recognise-the-return-type-of-a-stored-procedure-that-returns-a-temp-table/
Dec 24, 2014 12:10 AM|sw-ing|LINK
You could refer to the following links which discuss the similar issue.