Обсуждение: Maximum columns for optimum performance (fwd)
Can anybody comment on this? -- Peter Eisentraut Sernanders väg 10:115 peter_e@gmx.net 75262 Uppsala http://yi.org/peter-e/ Sweden ---------- Forwarded message ---------- Date: Wed, 16 Feb 2000 11:16:48 -0600 From: Jude Weaver <exec@shreve.net> To: Peter Eisentraut <peter_e@gmx.net> Subject: Maximum columns for optimum performance One of our tables have 476 columns and only 12 records or rows in it. We are coding in Java. When we compile and run against this table it is super slow. Is there a maximum number of columns past which performance suffers? Would we be better off building several smaller tables with fewer columns instead of one big table? Does the number of columns in a table affect speed?
Peter Eisentraut <peter_e@gmx.net> forwards:
> One of our tables have 476 columns and only 12 records or rows in it. We are
> coding in Java. When we compile and run against this table it is super slow.
> Is there a maximum number of columns past which performance suffers?
What exactly are you finding to be super slow? It's hard to tell from
this report whether the performance problem is in the backend or the
Java client interface (or even in your application code...)
While I can think of places that have loops over columns, I wouldn't
have thought that any of them are remarkably time-critical. It
probably depends on just what sort of query you are doing ... so a
specific example of a slow query would be helpful, along with the
details of the table declaration.
regards, tom lane