Services
24×7×365 Technical Support
Migration to PostgreSQL
High Availability Deployment
Database Audit
Remote DBA for PostgreSQL
Products
Postgres Pro Enterprise
Postgres Pro Standard
Cloud Solutions
Postgres Extensions
Resources
Blog
Documentation
Webinars
Videos
Presentations
Community
Events
Training Courses
Books
Demo Database
Mailing List Archives
About
Leadership team
Partners
Customers
In the News
Press Releases
Press Info
Services
24×7×365 Technical Support
Migration to PostgreSQL
High Availability Deployment
Database Audit
Remote DBA for PostgreSQL
Products
Postgres Pro Enterprise
Postgres Pro Standard
Cloud Solutions
Postgres Extensions
Resources
Blog
Documentation
Webinars
Videos
Presentations
Community
Events
Training Courses
Books
Demo Database
Mailing List Archives
About
Leadership team
Partners
Customers
In the News
Press Releases
Press Info
Facebook
Downloads
Home
>
mailing lists
Pg/SQL returning composite type - Mailing list pgsql-general
From
P. Broennimann
Subject
Pg/SQL returning composite type
Date
November 16, 2012
12:47:08
Msg-id
CACm4aU8hkp5c8_Y+oq4BWxgDdZGcLPihi2UfG3K0je=PWBkCxg@mail.gmail.com
Whole thread
Raw
Responses
Re: Pg/SQL returning composite type
(Raymond O'Donnell <rod@iol.ie>)
List
pgsql-general
Tree view
Hi there
I have in schema "core":
CREATE OR REPLACE FUNCTION core.f_read
(
...
)
RETURNS core.c_result_type AS
$$
declare
c_result core.c_result_type%rowtype;
begin
...
return c_result;
end
...
CREATE TYPE core.c_result_type AS (
a_value text,
a_result_code integer,
a_result text,
a_time integer
);
And in schema "canu":
CREATE OR REPLACE FUNCTION canu.f_read
(
...
)
RETURNS canu.c_result_type AS
$$
declare
c_result canu.c_result_type%rowtype;
begin
select core.f_read(...) into c_result;
return c_result;
end
...
CREATE TYPE canu.c_result_type AS (
a_value text,
a_result_code integer,
a_result text,
a_time integer
);
When calling core.f_read() the result is fine. When calling canu.f_read() I get all values back together/concatenated in the first "a_value" field!?
What am I doing wrong here? I am using PG 9.1.6 under Ubuntu 10.04/64
Thanks & cheers,
Peter
pgsql-general
by date:
Previous
From:
Sébastien Lardière
Date:
16 November 2012, 12:09:41
Subject:
Re: Plproxy with returns table() make PG segfault
Next
From:
Raymond O'Donnell
Date:
16 November 2012, 12:59:06
Subject:
Re: Pg/SQL returning composite type
Есть вопросы? Напишите нам!
Соглашаюсь с условиями обработки персональных данных
I confirm that I have read and accepted PostgresPro’s
Privacy Policy
.
I agree to get Postgres Pro discount offers and other marketing communications.
✖
×
×
Everywhere
Documentation
Mailing list
List:
all lists
pgsql-general
pgsql-hackers
buildfarm-members
pgadmin-hackers
pgadmin-support
pgsql-admin
pgsql-advocacy
pgsql-announce
pgsql-benchmarks
pgsql-bugs
pgsql-chat
pgsql-cluster-hackers
pgsql-committers
pgsql-cygwin
pgsql-docs
pgsql-hackers-pitr
pgsql-hackers-win32
pgsql-interfaces
pgsql-jdbc
pgsql-jobs
pgsql-novice
pgsql-odbc
pgsql-patches
pgsql-performance
pgsql-php
pgsql-pkg-debian
pgsql-pkg-yum
pgsql-ports
pgsql-rrreviewers
pgsql-ru-general
pgsql-sql
pgsql-students
pgsql-testers
pgsql-translators
pgsql-www
psycopg
Period
anytime
within last day
within last week
within last month
within last 6 months
within last year
Sort by
date
reverse date
rank
Services
24×7×365 Technical Support
Migration to PostgreSQL
High Availability Deployment
Database Audit
Remote DBA for PostgreSQL
Products
Postgres Pro Enterprise
Postgres Pro Standard
Cloud Solutions
Postgres Extensions
Resources
Blog
Documentation
Webinars
Videos
Presentations
Community
Events
Training Courses
Books
Demo Database
Mailing List Archives
About
Leadership team
Partners
Customers
In the News
Press Releases
Press Info
By continuing to browse this website, you agree to the use of cookies. Go to
Privacy Policy
.
I accept cookies