Function not imported in Entity Framework

From: Vikram Sah <rblucky3(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Function not imported in Entity Framework
Date: 2020-02-06 09:36:38
Message-ID: CAOqTwfao5VbcdU_vWK3JKrpGT_bTDBkAttPdSOksCefgM66jKA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Dear sir/mam,

I want to integrate PostgreSQL database to entity framework in asp.net
using database first approach. but when try to add function then
error occurred:

*Error 6046: Unable to generate function import return type of the store
function.*

I have following configuration:

PostgreSQL 11.6,
npgsql v.4.0.9.0,
EntityFramework6.Npgsql 3.2.1.1,
in .net framework 4.5.2

*My function in postgresql database is :*

CREATE OR REPLACE FUNCTION dbo.EmployeeDetail ()
RETURNS TABLE (
emp_name VARCHAR,
emp_Id UUID
)
AS $$
BEGIN
RETURN QUERY SELECT
"EmployeName",
"EmployeeID"
FROM
dbo.Employee;
END; $$

LANGUAGE 'plpgsql';

Can you pls help! I did more researches but no luck.

Thanks!

Responses

Browse pgsql-general by date

  From Date Subject
Next Message hubert depesz lubaczewski 2020-02-06 10:21:39 Re: POLL: Adding transaction status to default psql prompt
Previous Message Guillaume Lelarge 2020-02-06 07:20:03 Re: POLL: Adding transaction status to default psql prompt