🇨🇬 Java Enum: Republic of the Congo Departments
The Republic of the Congo is divided into 12 departments. Here's a Java enum using official ISO 3166-2:CG codes:
java
public enum CongoDepartment {
BOUENZA("CG-11"),
BRAZZAVILLE("CG-BZV"),
CUVETTE("CG-8"),
CUVETTE_OUEST("CG-15"),
KOILOU("CG-5"),
LEKOUMOU("CG-2"),
LIKOUALA("CG-7"),
NIARI("CG-9"),
PLATEAUX("CG-14"),
POINTE_NOIRE("CG-16"),
POOL("CG-12"),
SANGHA("CG-13");
private final String code;
CongoDepartment(String code) {
this.code = code;
}
public String getCode() {
return code;
}
}
🗃️ SQL Table and Insert Statements
sql
CREATE TABLE congo_departments (
id SERIAL PRIMARY KEY,
name VARCHAR(64) NOT NULL,
code VARCHAR(8) NOT NULL UNIQUE
);
INSERT INTO congo_departments (name, code) VALUES
('Bouenza', 'CG-11'),
('Brazzaville', 'CG-BZV'),
('Cuvette', 'CG-8'),
('Cuvette-Ouest', 'CG-15'),
('Kouilou', 'CG-5'),
('Lékoumou', 'CG-2'),
('Likouala', 'CG-7'),
('Niari', 'CG-9'),
('Plateaux', 'CG-14'),
('Pointe-Noire', 'CG-16'),
('Pool', 'CG-12'),
('Sangha', 'CG-13');
✅ Summary
This setup accurately reflects the 12 departments of the Republic of the Congo, including the capital Brazzaville and major department Pointe-Noire, using the ISO 3166-2:CG codes. It's perfect for software systems managing regional data or administrative mappings.