I'm puzzled if this is by design or just overlooked... create table t(a int, b varchar); insert into t values(1,'x'); For basic query: select t from t result is of type t. If I query: select sq from (select t from t) sq; result is of type record. I need to query like this: select (sq).t from (select t from t) sq; or like this: select t from (select t from t) t; to get result of type t. Wrapping t to record if another alias is used seems a bit unintuitive to me? Is this by design and if yes, why? Regards, Rikard -- Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general