pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Arrays Question? -Simon Moses
2+ messages / 2 participants
[nested] [flat]

* Arrays Question? -Simon Moses
@ 2004-09-25 10:20  Simon Moses <ks_moses@yahoo.com>
  0 siblings, 1 reply; 2+ messages in thread

From: Simon Moses @ 2004-09-25 10:20 UTC (permalink / raw)
  To: pgsql-jdbc

dear sir,

i want to use arrays(like int4[]) in my tables insted
of taking many int4 fields.
----------
for ex. 

Intvalues int4[2]

insted of 

bill_no int4
qty int4

i can assume that int4[1] is bill_no and int4[2] is
qty.
i can change code to support '{1,2}' syntax. 
----------
is there any performance problem?
is there any SQL syntax problem? like i cannot put
'order by' or 'group by' or where condition or .. ?
is there anyone using this without any problems?
in future will i get problems?

thanks in advance.
-Simon Moses
Bangalore.
India.

=====
**************************
Visit My Home Page
http://www.geocities.com/ks_moses
updated: 22 February 2004.
Simon Moses
**************************


		
_______________________________
Do you Yahoo!?
Declare Yourself - Register online to vote today!
http://vote.yahoo.com



^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: Arrays Question? -Simon Moses
@ 2004-09-25 19:36  Kris Jurka <books@ejurka.com>
  parent: Simon Moses <ks_moses@yahoo.com>
  0 siblings, 0 replies; 2+ messages in thread

From: Kris Jurka @ 2004-09-25 19:36 UTC (permalink / raw)
  To: Simon Moses <ks_moses@yahoo.com>; +Cc: pgsql-jdbc



On Sat, 25 Sep 2004, Simon Moses wrote:

> i want to use arrays(like int4[]) in my tables insted
> of taking many int4 fields.

In general this isn't a great idea.  You lose a lot of flexibility for no 
real good reason.  Combining these field just obscures what's going on and 
makes it more difficult to work with them.  The only possible reason I 
could see for doing this is if you had an outrageous number of fields 
(more than the postgresql limit), but that suggests a more drastic 
redesign instead of just stuffing them into arrays.

What do you think the possible advantages are?

Kris Jurka




^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2004-09-25 19:36 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2004-09-25 10:20 Arrays Question? -Simon Moses Simon Moses <ks_moses@yahoo.com>
2004-09-25 19:36 ` Kris Jurka <books@ejurka.com>

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