Exporting names now works correctly if there's a space in the end of a name

This commit is contained in:
Eric Schultz 2019-01-30 14:14:11 -06:00
parent 25aea032f0
commit 638de59cd6

View file

@ -426,9 +426,9 @@ UNION DISTINCT
def self.supporter_export_selections
[
"substring(supporters.name from '^.+ ([^\s]+)$') AS \"Last Name\"",
"substring(supporters.name from '^(.+) [^\s]+$') AS \"First Name\"",
"supporters.name AS \"Full Name\"",
"substring(trim(both from supporters.name) from '^.+ ([^\s]+)$') AS \"Last Name\"",
"substring(trim(both from supporters.name) from '^(.+) [^\s]+$') AS \"First Name\"",
"trim(both from supporters.name) AS \"Full Name\"",
"supporters.organization AS \"Organization\"",
"supporters.email \"Email\"",
"supporters.phone \"Phone\"",