Re: Function not imported in Entity Framework

From: Vikram Sah <rblucky3(at)gmail(dot)com>
To: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Function not imported in Entity Framework
Date: 2020-02-11 11:56:30
Message-ID: CAOqTwfYzYeZ=g-34x3ugHqqoxDdBF3cv0vuCaC_4M6KmrNcrUQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Thank you so much sir, but it didn't work for me as the database function
in PostgreSQL and EntityFramework6.Npgsql is used as provider for entity
framework.

Thanks!
Vikram

On Thu, Feb 6, 2020 at 9:23 PM Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
wrote:

> On 2/6/20 1:36 AM, Vikram Sah wrote:
> > Dear sir/mam,
> >
> > I want to integrate PostgreSQL database to entity framework in asp.net
> > <http://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.*
>
> This really a question for the EntityFramework maintainers/users. Still
> I did find this:
>
>
> https://stackoverflow.com/questions/24161005/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!
> >
> >
> >
>
>
> --
> Adrian Klaver
> adrian(dot)klaver(at)aklaver(dot)com
>

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Rich Shepard 2020-02-11 13:43:31 Re: Pre-version pg_upgrade syntax check
Previous Message Nick Renders 2020-02-11 11:32:05 Re: Postgres 12.1 : UPPER() in WHERE clause restarts server