Can't import Postgres stored procedure
Posted: Mon 10 Jan 2011 13:19
Hi
This applied to Devart and MS Entity models. Why can't I import a stored procedure with the following DDL? It means I have to use Linq or ADO.net to dispatch these.
Thanks
Richard
CREATE OR REPLACE FUNCTION "vhn_external"."public_live_location_list" (
out "location_short_id" char,
out "address_name" varchar,
out "location_type" varchar,
out "line_1" varchar,
out "line_2" varchar,
out "line_3" varchar,
out "town" varchar,
out "county" varchar,
out "postcode" varchar,
out "country_code" varchar,
out "weekday_start" time,
out "weekday_end" time,
out "saturday_open" boolean,
out "saturday_start" time,
out "saturday_end" time,
out "sunday_open" boolean,
out "sunday_start" time,
out "sunday_end" time,
out "email" varchar,
out "phone" varchar
)
RETURNS SETOF record AS
$body$
BEGIN
RETURN QUERY
SELECT etc etc
END;
$body$
LANGUAGE 'plpgsql'
VOLATILE
CALLED ON NULL INPUT
SECURITY INVOKER
COST 100 ROWS 1000;
This applied to Devart and MS Entity models. Why can't I import a stored procedure with the following DDL? It means I have to use Linq or ADO.net to dispatch these.
Thanks
Richard
CREATE OR REPLACE FUNCTION "vhn_external"."public_live_location_list" (
out "location_short_id" char,
out "address_name" varchar,
out "location_type" varchar,
out "line_1" varchar,
out "line_2" varchar,
out "line_3" varchar,
out "town" varchar,
out "county" varchar,
out "postcode" varchar,
out "country_code" varchar,
out "weekday_start" time,
out "weekday_end" time,
out "saturday_open" boolean,
out "saturday_start" time,
out "saturday_end" time,
out "sunday_open" boolean,
out "sunday_start" time,
out "sunday_end" time,
out "email" varchar,
out "phone" varchar
)
RETURNS SETOF record AS
$body$
BEGIN
RETURN QUERY
SELECT etc etc
END;
$body$
LANGUAGE 'plpgsql'
VOLATILE
CALLED ON NULL INPUT
SECURITY INVOKER
COST 100 ROWS 1000;