pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Steve Crawford <scrawford@pinpointresearch.com>
To: Oliveiros d'Azevedo Cristina <oliveiros.cristina@marktest.pt>
Cc: Nikolay <wheelly@gmail.com>
Cc: pgsql-sql@postgresql.org
Subject: Re: Mysterious column "name"
Date: Tue, 09 Aug 2011 09:00:52 -0700
Message-ID: <4E4159B4.2050304@pinpointresearch.com> (raw)
In-Reply-To: <80B8AE0F6EA345ECB04802EB381EF1B1@marktestcr.marktest.pt>
References: <4E3AB1B2.5040704@gmail.com>
	<80B8AE0F6EA345ECB04802EB381EF1B1@marktestcr.marktest.pt>

On 08/09/2011 08:34 AM, Oliveiros d'Azevedo Cristina wrote:
> Strange...
>
> Tables have hidden columns but AFAIK, "name" is not one of them...
>
> http://www.postgresql.org/docs/9.0/interactive/ddl-system-columns.html
>
> ...
>
>> Good day!
>>
>> I found one strange results for sql-query.
>>
>> create table testtable (
>> f1 int,
>> f2 int
>> );
>>
>> insert into testtable(f1, f2) values(1, 100);
>>
>> select testtable.* from testtable; // it is ok
>>
>> select testtable from testtable; // it is ok
>>
>> select testtable.name from testtable; // returns strange result.
>> -----------------------------------------------------------------
>> name
>> name
>> -----------------------------------------------------------------
>> "(1,100)"
>> -----------------------------------------------------------------
>> no error message about nonexistent column.
>> Result is similar to second variant, but pgAdmin3 shows not full record.
>> ...
>
See http://www.postgresql.org/docs/9.0/static/rowtypes.html on composite 
data types and scroll to section 8.15.3.

Cheers,
Steve



view thread (4+ messages)  latest in thread

Message-ID: <4E4159B4.2050304@pinpointresearch.com>
Permalink:  ../4E4159B4.2050304@pinpointresearch.com/
Also on:    postgresql.org/message-id/4E4159B4.2050304@pinpointresearch.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: scrawford@pinpointresearch.com, oliveiros.cristina@marktest.pt, wheelly@gmail.com
  Subject: Re: Mysterious column "name"
  In-Reply-To: <4E4159B4.2050304@pinpointresearch.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox