Null integer columns

From: Jeffrey Tenny <jeffrey(dot)tenny(at)comcast(dot)net>
To: pgsql-performance(at)postgresql(dot)org
Subject: Null integer columns
Date: 2005-01-05 19:09:11
Message-ID: 41DC3B57.2040109@comcast.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

I have an integer column that is not needed for some rows in the table
(whether it is necessary is a factor of other row attributes, and it
isn't worth putting in a separate table).

What are the performance tradeoffs (storage space, query speed) of using
NULL versus a sentinel integer value?

Not that it matters, but in the event where the column values matter,
the numberic value is a foreign key. Advice on that welcome too.

Thanks!

Browse pgsql-performance by date

  From Date Subject
Next Message Miles Keaton 2005-01-06 02:31:49 Benchmark two separate SELECTs versus one LEFT JOIN
Previous Message Dave Cramer 2005-01-05 18:21:59 Re: Low Performance for big hospital server ..