copy or create table for data logging? - Mailing list pgsql-general

From John Smith
Subject copy or create table for data logging?
Date
Msg-id f029597e0704241550r7a4e52f1l41a8db722ef670c6@mail.gmail.com
Whole thread Raw
List pgsql-general
guys,
i want to log some data everyday. for this i can do 1 of 2 things:

1) i can create an empty 'template' table and copy it everyday before
data logging including defaults.
# including constraints (thanks greg) doesn't work but more on that later.

helps-
i avoid spending more time on lengthy domain creation everyday (??).

hurts-
i have to share sequences between everyday tables (i can do away with
sequences but not sure on that).

2) i can simply create an identical table everyday and go on with data logging.

helps-
hmm, the smell of fresh new sequences everyday!

hurts-
i spend more time on creation (??).

either way i get the job done but what would you recommend? no
inheritance please since it couples and complicates. using 8.1.4.
jzs
http://developer.postgresql.org/pgdocs/postgres/sql-createtable.html

pgsql-general by date:

Previous
From: Mike Goldner
Date:
Subject: Additional debugging of idle sessions?
Next
From: "Joris Dobbelsteen"
Date:
Subject: Re: Audit-trail engine: getting the application's layer user_id