Skip site navigation (1) Skip section navigation (2)

Re: Column Ordering

From: Richard Broersma Jr <rabroersma(at)yahoo(dot)com>
To: Andres Ledesma <alchir(at)yahoo(dot)com>, pgsql-novice(at)postgresql(dot)org
Subject: Re: Column Ordering
Date: 2007-09-10 21:45:43
Message-ID: 252216.43330.qm@web31808.mail.mud.yahoo.com (view raw or flat)
Thread:
Lists: pgsql-novice
--- Andres Ledesma <alchir(at)yahoo(dot)com> wrote:
> Forgive me if I'm wrong but as far as I know, in the relational theory behind the RDBMSs, the
> colum order in a tupple is irrelevant, like the elements in a set. 

This is correct.

> Is there any solid reason or need for having colunms ordered ? 

My guess for this request is that alot of people would rather write:

SELECT * 
  FROM Table;

instead of:

SELECT column1, column5, column2, column3, column4
  from Table;


I've seen alot of "BEST PRACTICE" advice on this list that suggests that writing out all of the
columns is recommended.  However, I am sure that there are alot of individuals that like to write
these queries with the least amount of code possible.

Regards,
Richard Broersma Jr.

In response to

Responses

pgsql-novice by date

Next:From: johnfDate: 2007-09-10 21:53:57
Subject: the copy command
Previous:From: Andres LedesmaDate: 2007-09-10 21:18:31
Subject: Re: Column Ordering

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group