Revision 4948
Added by Aaron Marcuse-Kubitza about 12 years ago
schemas/py_functions.sql | ||
---|---|---|
171 | 171 |
params = dict(first=first, middle=middle, last=last) |
172 | 172 |
|
173 | 173 |
_name_parts_slices_items = [ |
174 |
('first', slice(None, 1)), |
|
174 |
('first', slice(None, -1)),
|
|
175 | 175 |
('middle', slice(1, -1)), |
176 | 176 |
('last', slice(-1, None)), |
177 | 177 |
] |
Also available in: Unified diff
schemas/py_functions.sql: _namePart(): Slice the first name from the beginning of the string to one word before the end, instead of one after the beginning, in order to avoid overlap with the last name, which starts one before the end, when there is only one word. Note that only one word means the name is assumed to be a last name. This assumption may not always be true, but when a datasource provides the name concatenated, an assumption must be made when not all name components are present.