[Mapbender-dev] i18n - table translations

Samson, Marko Marko.Samson at wald-und-holz.nrw.de
Mon Aug 13 05:09:04 EDT 2007


Hi Devs,

Perhaps a PK like:

CONSTRAINT translations_pkey PRIMARY KEY (locale,msgid)

would be possible? I'm not so involved in i18n, but if 'locale' means the used language and msgid the id of the message, there should be always just one combination of locale and msgid, so that it could be used for PK.
On the other hand its easier to use the trs_id for relations to other tables.

Unattached of this, I agree to Bjoern, that a sequence value for trs_id should not create double entries. 

@Astrid: Do you think creating the update script will raise a problem with sequence values for trs_id or do you mean double entries because of not having a clear'n'unique pk, so that entries can have different trs_id but same values for the rest of the columns?


Greetings,
Marko Samson

 

> -----Original Message-----
> From: mapbender_dev-bounces at lists.osgeo.org 
> [mailto:mapbender_dev-bounces at lists.osgeo.org] On Behalf Of 
> Heuser, Bjoern
> Sent: Monday, August 13, 2007 9:59 AM
> To: Mapbender Developer List
> Subject: AW: [Mapbender-dev] i18n - table translations
> 
> Hi Astrid,
> 
> I prefer using the trs_id column.
> Because this column is also the primary key and the values 
> are generated by a sequence I would wonder if there are 
> double entries.
> 
> wkr
> 
> Björn
> 
> -----Ursprüngliche Nachricht-----
> Von: mapbender_dev-bounces at lists.osgeo.org 
> [mailto:mapbender_dev-bounces at lists.osgeo.org] Im Auftrag von 
> Astrid Emde (WhereGroup)
> Gesendet: Montag, 13. August 2007 09:40
> An: Mapbender_dev
> Betreff: [Mapbender-dev] i18n - table translations
> 
> Hi devs, hi peter, hi christoph,
> 
>  I have a question about the new table translation.
> 
>  At the moment the table looks like this:
> 
> CREATE TABLE public.translations
> (
>   trs_id int4 NOT NULL DEFAULT 
> nextval('translations_trs_id_seq'::regclass),
>   locale varchar(8),
>   msgid varchar(512),
>   msgstr varchar(512),
>   CONSTRAINT translations_pkey PRIMARY KEY (trs_id) );
> 
> Do we need the column trs_id ? Or can we skip it? It would we 
> easier without the column, as we won't get problems with 
> double entries in the trs_id column.
> 
> What do you think?
> 
> Best regards astrid
> _______________________________________________
> Mapbender_dev mailing list
> Mapbender_dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapbender_dev
> 
> 
> _______________________________________________
> Mapbender_dev mailing list
> Mapbender_dev at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapbender_dev
> 


More information about the Mapbender_dev mailing list