Am 05.11.2010 16:17, schrieb ALT SHN:
> I have a column of a table of paleontological sites named "Paleosites"
> wich has a column named "species". A paleosite can contain remais of
> one or more animals. So in that column sometimes I have to put this:
> dinossauria crocodilia plantae. This indicates that from a given
> paleosite were retrieved the remais of 3 different species.
> Now my question is: wich data type should the column "Species" be?
> Text? Varchar?
Do it with 3 tables and use numerical representation of your keywords as
The technique is called foreign key and normalisation.
This might sound complicated at first but it is much better than writing
everything in a textfield.
As soon as you have a certain amount of data in your database, you will
have to cope with "dynosauria" and "krocodillia". Typing errors will happen.
Please find some time to get a better idea what a relational database is
Really this will help you a lot.
And you should be prepared to do the whole work again when you learnd
some basics. ;)
BTW you might be interested to know that PostgreSQL has datatypes and an
addon for geolocations.
You will want to store GPS coordinates for the sites.
I'm sure some others here have allready used this feature. I just saw it
In response to
pgsql-novice by date
|Next:||From: Vaduvoiu Tiberiu||Date: 2010-11-06 09:37:10|
|Subject: Describe command alternatives in postgresql|
|Previous:||From: Chris Browne||Date: 2010-11-05 21:25:58|
|Subject: Re: COPY command and serial columns|