Sex of the holder, to be specified by use of the single initial commonly used in the language of the State where the document is issued and, if translation into English, French or Spanish is necessary, followed by an oblique and the capital letter F for female, M for male, or X for unspecified.
Machine Readable Zone
F = female; M = male; < = unspecified. ※<は比較演算子ではなく<を使えという意味。
by
Anonymous Coward
on 2021年07月05日 2時24分
(#4063471)
なお、内部データとして性別(生物学的性別)を保存する用途に関してISO 5218 [wikipedia.org]というのがある。ISO 5218ではnot known (0), male (1), female (2), not applicable (9)の4通りの割り当てとなっているので、ternaryな型では不十分。素直に整数型を使おう。
booleanで指定されていたりして (スコア:0)
たいとるおんりー
Re: (スコア:2, 参考になる)
パスポートのフォーマット規約見ると、男と女と未指定の3値が規定されていた。
https://www.icao.int/publ [icao.int]
Re: (スコア:0)
TrueとFalseとnullが欲しいときがある。
ternary型?
Re:booleanで指定されていたりして (スコア:0)
なお、内部データとして性別(生物学的性別)を保存する用途に関してISO 5218 [wikipedia.org]というのがある。ISO 5218ではnot known (0), male (1), female (2), not applicable (9)の4通りの割り当てとなっているので、ternaryな型では不十分。素直に整数型を使おう。