Page MenuHomePhabricator

Add field to Silverpop export: highest_native_amount
Closed, ResolvedPublic1 Estimated Story Points

Description

One of the database fields we use in every email is the highest_usd_amount field. It allows us to customize the ask, button amounts, etc based on the highest past gift. But because the amount is in USD, we have to set up a bunch of complicated rulesets to convert the USD amount into its foreign equivalent.

I'd like to add a highest_native_amount field to the database, so that a rule like "If highest_native_amount is between 5-9.99, display '10'" will never need to be dynamic based on conversion. This would really simplify my life :)

Event Timeline

DStrine set the point value for this task to 1.May 17 2016, 8:12 PM
DStrine moved this task from Triage to Sprint +3 on the Fundraising-Backlog board.
CCogdill_WMF raised the priority of this task from Medium to High.Jul 26 2016, 3:57 PM

I'm bumping priority on this because I realized using the highest_usd_amount field is forcing us to serve an inaccurate experience to donors.

We use highest_usd_amount in all our form links to show customized amounts on the landing page — but am I right in thinking that usd_amount field doesn't update conversions? If someone gave 10 EUR 5 years ago, the USD equivalent would be much different than 10 EUR now.

Can we get the highest_native_amount field in the silverpop export before the big EUR countries coming up (i.e. Italy)?

Change 318360 had a related patch set uploaded (by Ejegg):
WIP add highest_native_amount

https://gerrit.wikimedia.org/r/318360

Can I add another field request onto this task? Is there any way to get the
first donation date? :D

@CCogdill_WMF Scope creep! ;)

that field doesn't exist in wmf_donor. that sounds like it might be a bit complicated but I'll let @Ejegg give more info. If this is complicated, let's make a separate task.

Haha I figured as much... happy to make a new task. This isn't a must have
but could try some cool tests with it. You never know what could make a 15%
gain.

first donation date ought to be really easy

Change 318360 merged by jenkins-bot:
Add highest_native_amount to Silverpop export

https://gerrit.wikimedia.org/r/318360

OK @CCogdill_WMF, this is ready for deployment (probably Monday). It will add three new columns after highest_usd_amount: highest_native_amount, highest_native_currency, and highest_donation_date.

Don't know if you need the date, but it doesn't slow things down any more than grabbing the other two. I figured you would need highest_native_currency because it's not necessarily the same as latest_native_currency.

@Ejegg yes, this is so wonderful! Thank you! Let me know when you deploy it
and I'll set up Silverpop to import the new fields.

Hey @Ejegg, is this going out today by chance?

Sorry for the delay @CCogdill_WMF, I'm deploying this one today.

This is up. Tomorrow morning's export will have the new fields.

This added 12 minutes to the total export time. Unrelated: that logging I added is useless because it's always the first 80 chars of the query prefix.