Every database regardless SQL/ noSQL needs some lists of values. And it is not important if you use them relationally or “noSQL-ly”… 🙂
Bank SWIFT codes
Table name: config.bank_swift_code
Record structure in RDBMS:
Column name | Type | Constraints | Foreign key column | Foreign table value |
ID | bigserial | |||
NAME | text | not null | ||
COUNTRY_ID | bigint | not null | config.country.id | config.country.name |
CITY_ID | bigint | not null | config.city.id | config.city.name |
BRANCH | text | |||
SWIFT | text | not null, unique |
Record structure in noSQL JSON:
{ "_id": 1, "name": "AAREAL BANK AG", "country": "Germany", /* from list of countries */ "city": "BERLIN", /* from list of cities */ "branch": null, "swift": "AARBDE5W100" }
Example data:
(data for Germany, city is shown as config.cities.name not as ID)
ID | Bank or Institution | City | Branch | Swift Code |
---|---|---|---|---|
1 | AAREAL BANK AG | BERLIN | AARBDE5W100 | |
2 | AAREAL BANK AG | ESSEN | AARBDE5W360 | |
3 | AAREAL BANK AG | FRANKFURT AM MAIN | AARBDE5W500 | |
4 | AAREAL BANK AG | HAMBURG | AARBDE5W200 | |
5 | AAREAL BANK AG | HANNOVER | AARBDE5W250 | |
6 | AAREAL BANK AG | LEIPZIG | AARBDE5W860 | |
7 | AAREAL BANK AG | MAINZ | AARBDE5W550 | |
8 | AAREAL BANK AG | MUENCHEN | AARBDE5W700 | |
9 | AAREAL BANK AG | STUTTGART | AARBDE5W600 | |
10 | AAREAL BANK AG | WIESBADEN | (CLEARING) | AARBDE5WCLE |
11 | AAREAL BANK AG | WIESBADEN | (GF -BK01-) | AARBDE5WDOM |