Reputation
8,996
Next tag badge:
71/100 score
35/20 answers
Badges
21 76
Newest
 Nice Answer
Impact
~641k people reached

Nov
13
answered Stored procedure deadlocking itself
Nov
11
comment How can I run a PostgreSQL outside the standard directories on Linux, ie outside /var/run/postgresql etc?
I believe debian and ubuntu put the file in /etc/postgresql/[version]/[cluster]/ so you should have multiple postgresql.conf files in /etc.
Nov
7
answered How can I run a PostgreSQL outside the standard directories on Linux, ie outside /var/run/postgresql etc?
Nov
7
comment Why shouldn't we allow NULLs?
Actually I found one area where they are necessary in relational databases, namely in foreign keys, particularly if it is a composite key. You can probably factor these out to some extent but you cannot have a two column foreign key where one portion is NULL without handling that with some pretty interesting acrobatics DDL-wise.
Nov
7
revised Why shouldn't we allow NULLs?
added 210 characters in body
Nov
7
comment Why shouldn't we allow NULLs?
It's worth noting that '' is distinct from null on PostgreSQL (though not Oracle) and so gives you a two-fold marker, and you could use 0 for numeric columns. The problem with 0 though is that it doesn't work for foreign keys.
Oct
25
awarded  Revival
Oct
9
awarded  Revival
Oct
1
awarded  Revival
Sep
24
comment Migrating database live while being severely handicapped
BTW, this is one of the core uses of views, to maintain app compatibility when db schemas change, IMO.
Sep
23
answered Migrating database live while being severely handicapped
Sep
20
awarded  Quorum
Sep
17
answered Running a UPDATE on 3 million records
Sep
17
comment PGPool Frequent Queries
Prepared statements are often at a lower level than the ORM. For example, in Perl, DBD::Pg by default uses them (you can turn them off though).
Sep
17
answered PGPool Frequent Queries
Sep
16
awarded  Revival
Sep
16
comment PostgreSQL: DBLink weird permission/connection error
The overall point (and the point of my answer) is that you need a procedural approach to make sure your connection is started and stopped properly. Otherwise, you run into the fact that the planner will quite happily simplify your set operations for you and the side effects of those (that the planner is unaware of) will get omitted.
Sep
16
answered PostgreSQL transaction locked database table: “idle in transaction”
Sep
16
comment Measuring SQL execution time in PostgreSQL?
hmmmm I misread "in" for "on." Yes, pg_stat_statements is an option, provided you don't need to be able to report on which tables were hit.
Sep
16
answered How I can copy from local file to remote DB in PostgreSQL?