Re: Internationalisation (i18n) with Postgres as backend

2021-06-02 Thread Laurenz Albe
On Tue, 2021-06-01 at 20:09 +, Laura Smith wrote: > I'm creating a Postgres backend for an internal tool which is essentially a > very simple implementation of multi-lingual CMS. > > I am especially interested in feedback and suggestions in relation to the > following questions: > > (a) Is

Re: Internationalisation (i18n) with Postgres as backend

2021-06-02 Thread Laurenz Albe
On Tue, 2021-06-01 at 23:08 +, Laura Smith wrote: > I didn't consider hstore, I did consider jsonb though. > > The thing that made me lean towards individual rows rather than consolidated > was > that I thought versioning would ultimately be easier/cleaner to achieve with > individual rows

Re: Internationalisation (i18n) with Postgres as backend

2021-06-02 Thread Laura Smith
On Wednesday, 2 June 2021 00:42, Rob Sargent wrote: > On 6/1/21 5:00 PM, Laura Smith wrote: > > > > What is your notion of "object".  I first assumed it was akin to > > > "document" but then pages have objects. > > > > I think my terminology is a bit off. > > > > A document/page has object(s) on

Re: Internationalisation (i18n) with Postgres as backend

2021-06-01 Thread Rob Sargent
On 6/1/21 5:00 PM, Laura Smith wrote: What is your notion of "object".  I first assumed it was akin to "document" but then pages have objects. I think my terminology is a bit off. A document/page has object(s) on it. Or, perhaps better expressed, think of document/page as the template and obj

Re: Internationalisation (i18n) with Postgres as backend

2021-06-01 Thread Laura Smith
Hi Steve, I didn't consider hstore, I did consider jsonb though. The thing that made me lean towards individual rows rather than consolidated was that I thought versioning would ultimately be easier/cleaner to achieve with individual rows (e.g. using tsrange & gist exclude).  But willing to be

Re: Internationalisation (i18n) with Postgres as backend

2021-06-01 Thread Laura Smith
> What is your notion of "object".  I first assumed it was akin to > "document" but then pages have objects. I think my terminology is a bit off. A document/page has object(s) on it. Or, perhaps better expressed, think of document/page as the template and object(s) is what fills the gaps in t

Re: Internationalisation (i18n) with Postgres as backend

2021-06-01 Thread Steve Baldwin
Hi Laura, Did you consider using hstore to store language and data as a kvp? For example: b2bc_owner@b2bcreditonline=# create table langtest(pageid text, objectid text, objectdata hstore, constraint langtest_pk primary key (pageid, objectid)); CREATE TABLE b2bc_owner@b2bcreditonline=# insert into

Re: Internationalisation (i18n) with Postgres as backend

2021-06-01 Thread Rob Sargent
On 6/1/21 2:09 PM, Laura Smith wrote: Hi, I'm creating a Postgres backend for an internal tool which is essentially a very simple implementation of multi-lingual CMS. So far my thoughts are along the lines of the below, but I would appreciate a second (or more !) pair of eyes from some Postgr

Internationalisation (i18n) with Postgres as backend

2021-06-01 Thread Laura Smith
Hi, I'm creating a Postgres backend for an internal tool which is essentially a very simple implementation of multi-lingual CMS. So far my thoughts are along the lines of the below, but I would appreciate a second (or more !) pair of eyes from some Postgresql gurus. I am especially interested