diff --git a/specification/gedcom-3-structures-1-organization.md b/specification/gedcom-3-structures-1-organization.md index a153daa..43fda97 100644 --- a/specification/gedcom-3-structures-1-organization.md +++ b/specification/gedcom-3-structures-1-organization.md @@ -396,6 +396,90 @@ However, as of 2021 relatively few applications have a user interface that prese A `SHARED_NOTE_RECORD` may contain a pointer to a `SOURCE_RECORD` and vice versa. Applications must not create datasets where these mutual pointers form a cycle. Applications should also ensure they can handle invalid files with such cycles in a safe manner. +#### `SHARED_PLACE_RECORD` := + +```gedstruct +n @XREF:SPLAC@ SPLAC {1:1} g71:record-SPLAC + +1 TYPE {0:1} g71:SPLAC-TYPE + +1 LANG {0:1} g7:LANG + +1 TRAN {0:M} g71:TRAN + +2 LANG {0:1} g7:LANG + <> {1:1} + <> {0:M} g71:SPLAC +``` + +A descriptor of a single place, location, or jurisdiction. + +The `<>` inside a `SHARED_PLACE_RECORD` points to larger jurisdictions that this place is a part of. +If a city is part of a county which is part of a state, the city's place record should point to the county's place record, not the state's. +Multiple `<>`s are permitted to support places within multiple hierarchies (for example, a church that's both within an ecclesiastical region and a political region). + +Shared place records offer more flexibility than place structures do. +A `PLAC` can be replaced by an `SPLAC` without loss of information by making one `SPLAC` record for each non-empty string in the `PLAC`'s payload and linking them together using the `SPLAC`'s `SHARED_PLACE_STRUCTURE`s. +Information is copied into the new chain of `SPLAC` records as follows: + +- The `PLAC` structure is replaced by an `SPLAC` structure that points to the first `SPLAC` record in the chain. +- Any `NOTE` substructures of `PLAC` are retained as substructures of the new `SPLAC` structure. +- Empty list entries are skipped. +- The `PLAC` payload parts become `SPLAC` payloads. +- The `FORM` payload parts (which may be copied from the `HEAD`.`PLAC`.`FORM` if that is present but `PLAC`.`FORM` is not) become `SPLAC`.`TYPE` payloads. +- The `TRAN` payload parts become `TRAN` payloads. +- `LANG` and `TRAN`.`LANG` are copied to each record in the linked list. +- All other substructures (`MAP` and `EXID`) are copied only to the first record in the list. + +:::example + +The 7.0 structure + +```gedcom +2 PLAC one, two, , three +3 FORM city, county, state, country +3 LANG en +3 TRAN uno, dos, , tres +4 LANG es +3 MAP +4 LATI N12.3 +4 LONG W45.6 +3 NOTE this is an example +``` + +can be converted without loss of information into the new structure + +```gedcom +2 SPLAC @SP1@ +3 NOTE this is an example +``` + +and new records + +```gedcom +0 @SP1@ SPLAC one +1 TYPE city +1 LANG en +1 TRAN uno +2 LANG es +3 MAP +4 LATI N12.3 +4 LONG W45.6 +1 SPLAC @SP2@ +0 @SP2@ SPLAC two +1 TYPE county +1 LANG en +1 TRAN dos +2 LANG es +1 SPLAC @SP3@ +0 @SP3@ SPLAC three +1 TYPE country +1 LANG en +1 TRAN tres +2 LANG es +``` + +::: + +Conversion in the other direction is also possible (from `SPLAC` to `PLAC`) but will in general discard information about individual places in the `SPLAC` chain. + + #### `SOURCE_RECORD` := ```gedstruct @@ -404,7 +488,7 @@ n @XREF:SOUR@ SOUR {1:1} g7:record-SOUR +2 EVEN {0:M} g7:DATA-EVEN +3 DATE {0:1} g7:DATA-EVEN-DATE +4 PHRASE {0:1} g7:PHRASE - +3 <> {0:1} + +3 <> {0:1} +2 AGNC {0:1} g7:AGNC +2 <> {0:M} +1 AUTH {0:1} g7:AUTH @@ -567,7 +651,7 @@ Time phrases are expected to be added in version 7.1. ```gedstruct n <> {0:1} -n <> {0:1} +n <> {0:1} n <> {0:1} n PHON {0:M} g7:PHON n EMAIL {0:M} g7:EMAIL @@ -957,7 +1041,7 @@ Ordinances performed by members of The Church of Jesus Christ of Latter-day Sain ```gedstruct n <> {0:1} n TEMP {0:1} g7:TEMP -n <> {0:1} +n <> {0:1} n STAT {0:1} g7:ord-STAT +1 DATE {1:1} g7:DATE-exact +2 TIME