I don't think Derby and PostgreSQL are alternatives.
You could use Derby for your development incl. unit test because it is
practically no install/config and PostgreSQL for your QA and production
for the reliability and performance.
I'd almost say it was the other way round. PostgreSQL is pretty easy to
install - as root (paraphrasing what i actually just did):
yum install postgresql-server # will prompt to confirm
sudo -u postgres initdb
# possibly edit pg_hba.conf
service postgresql start
sudo -u postgres createuser -P -S developer # will prompt for a password
sudo -u postgres createdb -O developer development
pg_hba.conf is the file which defines access methods, and access control.
With every package i have ever installed, it is created in a state which
allows the normal console user to get access to the database. However, the
details vary: IIRC, on OS X (with MacPorts), it is set up to use peer
authentication for unix domain sockets (which is secure), and MD5 password
authentication for TCP/IP sockets (which is fairly secure). However, a
default install on Fedora 15 has no authentication on either kind of
socket; that said, TCP/IP sockets are only opened on the loopback
interface, so this is not that bad. An old installation on Fedora came
with only unix domain sockets by default, and no TCP/IP. So, that file may
need some tweaking.
So, not nearly as easy as installing Derby (which with a Sun JDK involves
precisely zero steps), but not at all difficult. Suitable for a
development machine.
Whereas i think the great strength of Derby is in production - if and only
if you are distributing code to run on desktop machines. There, the less
you need to install, the better, and the fact that Derby comes in the JDK
makes it a bit of a slam-dunk. It's not a particularly great database, but
you can't argue with the ease of installation.
tom