1 CREATE TABLE site_language (
3 site_id int REFERENCES site ON UPDATE CASCADE ON DELETE CASCADE NOT NULL,
4 language_id int REFERENCES
6 UPDATE CASCADE ON DELETE CASCADE NOT NULL,
7 UNIQUE (site_id, language_id)
10 CREATE TABLE community_language (
11 id serial PRIMARY KEY,
12 community_id int REFERENCES community ON UPDATE CASCADE ON DELETE CASCADE NOT NULL,
13 language_id int REFERENCES
15 UPDATE CASCADE ON DELETE CASCADE NOT NULL,
16 UNIQUE (community_id, language_id)
19 -- update existing users, sites and communities to have all languages enabled
29 INSERT INTO local_user_language (local_user_id, language_id) (
41 INSERT INTO site_language (site_id, language_id) (
53 INSERT INTO community_language (community_id, language_id) (