Re: 9.4 Proposal: Initdb creates a single table

From: Albe Laurenz <laurenz(dot)albe(at)wien(dot)gv(dot)at>
To: "Simon Riggs *EXTERN*" <simon(at)2ndQuadrant(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: 9.4 Proposal: Initdb creates a single table
Date: 2014-04-23 07:20:54
Message-ID: A737B7A37273E048B164557ADEF4A58B17CF2F22@ntex2010i.host.magwien.gv.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Simon Riggs wrote:
> I propose we add a single table called Postgres when we Initdb
>
> CREATE TABLE Postgres (Id Integer, Data Jsonb);
> COMMENT ON TABLE Postgres IS 'Single table for quick start usage -
> design your database';
>
> The purpose of this is to make the database immediately usable. By
> including this table in the default initdb it will mean that programs
> can rely on the existence of this table and begin working quicker.
>
> By now, some of you will be doubled over laughing as if this is an
> April fool joke. I don't mean it to be at all.
>
> The idea is to have a stupidly obvious and easy table that will
> potentially be usable by just about everyone, in any language.

I am a PostgreSQL newbie.
How is this table useful for me?
I want to develop a database application.
I want to store personal data like name and birth date!

Actually, I feel confused. What should I do with this table?
Is it part of the database system? Will the database be broken if
I drop it? Do I have to ship it with my application?

> If you don't like it, don't use it. If you really dislike it, drop it.

No, I'm not the kind of person who reads a manual to figure out what to
do with this table. I want to start coding *right now*.

> But for new people coming to Postgres, they will have a data object to
> access and begin using the database immediately. Their code will work,
> their examples will work. OK, so they need to go back and think about
> the design, but at least they got it to work and will be encouraged to
> do more.

I have found a sample application for personal data on the internet.
How can I make it work with this table?

> Remember when we didn't have a database called Postgres? Remember how
> much simpler life is now? Remember that now.

Good that you mention that! I have wondered what to do with it.
When I first connected to PostgreSQL, I created a sample table, but the
senior developer from the other office told me that this is the "postgres"
database and that I shouldn't create any objects there.

What is it good for? Can I delete it?

Yours,
Laurenz Albe

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Craig Ringer 2014-04-23 07:39:23 Re: 9.4 Proposal: Initdb creates a single table
Previous Message Pavel Stehule 2014-04-23 07:13:37 Re: 9.4 Proposal: Initdb creates a single table