printing vector column seems to print the rest of the row too - Mailing list pgsql-general

From Jeff Hamann
Subject printing vector column seems to print the rest of the row too
Date
Msg-id DA7968A5-ED53-48C4-AB44-5183A2E7484A@gmail.com
Whole thread Raw
Responses Re: printing vector column seems to print the rest of the row too
List pgsql-general
I'm sorry if this not the appropriate place for this post, but I couldn't figure out where to put this and I didn't see
anythingonline so far... 

I've been prototyping a small database, with the following table definition:

drop table if exists tradeprices cascade;
create table tradeprices (
     universedate date not null,
     tradetimestamp timestamp not null,
     tradeprice real[] not null,
     primary key (universedate,tradetimestamp)
);

When I insert the following row,

insert into tradeprices (universedate,tradetimestamp,tradeprice) values ('2010-07-20','2010-07-20
14:31:02','{1076.09,84.1199,100.21,95.74,107.2822,105.2657,11.67,53.75,40.04,61.41,68.176,71.13,39.85,59.41,61.66,63.32,38.92,83.46,49.03,48.6999,108.21,34.18,54.1901,73.52,54.94,40.17,17.35,51.7,42,43.0195,52.419,41.7,41.8,55.57,35.14,28.31,19.17,18.0608,34.2}');

The results are printed as:


select universedate,tradetimestamp,tradeprices from tradeprices where date(tradetimestamp) = CURRENT_DATE order by
tradetimestampdesc; 
-[ RECORD 1
]--+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
universedate   | 2010-07-20
tradetimestamp | 2010-07-20 11:10:44
tradeprices    | (2010-07-20,"2010-07-20
11:10:44","{1076.09,84.1199,100.21,95.74,107.282,105.266,11.67,53.75,40.04,61.41,68.176,71.13,39.85,59.41,61.66,63.32,38.92,83.46,49.03,48.6999,108.21,34.18,54.1901,73.52,54.94,40.17,17.35,51.7,42,43.0195,52.419,41.7,41.8,55.57,35.14,28.31,19.17,18.0608,34.2}")

where the "tradeprices" vector contains, in the print output only, the values of the previous columns in the row (see
thefirst two elements of the tradeprices vector). 

I've tried connecting to the database and retrieved to test connections using psql, ODBC drivers, RPostgreSQL, etc. and
theresults come back, depending on the client.  

I was originally working with 8.3, and have only recently updated to 8.4

Is this a bug, or something that I'm not doing correctly, or both?

Respectfully,
Jeff.




Jeff Hamann
jeff.d.hamann@gmail.com




pgsql-general by date:

Previous
From: Merlin Moncure
Date:
Subject: Re: check_postgres reports most of my tables are unanalyzed for 8 weeks; why isn't autovacuum analyzing them?
Next
From: Alvaro Herrera
Date:
Subject: Re: printing vector column seems to print the rest of the row too