The Y2Gay Problem


A meditation on the problem of updating bureaucracies' databases that presently only support reciprocal "husband-wife" relationships, but not "husband-husband" or "wife-wife".


This schema is much more sophisticated. A marriage blob is formed. Initially, at least two people, Jeff and Elizabeth, are members – this would be enforced at the application logic level. They have rows in the marriage_partners table. As time passes, Bob joins, creating another row in the marriage_partners table with the same marriage_id. He may then leave, inserting a divorce_date. He may even join again: this would be a new marriage_partners row entirely. He would have had two discontinuous marriages, though they would involve the same people. Then Elizabeth might leave. She would only have one marriage_partners row listed, and so, technically, would only have one marriage to her name. Jeff and Bob would be left behind. And finally, neither Bob nor Jeff could leave individually; both of them would have to leave the marriage blob simultaneously. Again, this would have to be enforced at the application logic level.

(And of course you would need to ensure that at any given moment in time, each person was a member of only one marriage. …Right?)

Pretty sneaky, sis!

I can still imagine some potential complications – for example, what if Bob and Jeff were involved in one marriage, and Elizabeth and Daphne were involved in another, and then Jeff decided to marry Elizabeth? You would need to provide for some way for Daphne to be "pulled over" to join Bob and Jeff's marriage too. Or for Bob to be "pulled over" and joined in with Elizabeth and Daphne's marriage too. Or, for equality's sake, for all four of them to dissolve their current marriages and join an entirely new, four-person marriage blob.

Again, you could hack it, but you would really have no choice but to introduce arbitrary, instantaneous temporary divorces into the system. And it would be unavoidable that there would be no continuity. At least one, and possibly both, of the original marriage blobs would be ended permanently in the merger. Because marriage is not just an irreflexive binary relation; it's a transitive, irreflexive, binary relation. If Jeff is married to Elizabeth, and Elizabeth is married to Bob, then Jeff is married to Bob.

Right?

Gay marriage: the database engineering perspective [QNTM]


(via JWZ)

(Image: 40.MarriageEqualityRally.SupremeCourt.WDC.26March2013,
Elvert Barnes, CC-BY-SA
)