Page 1 of 1

Bulk update all coupon codes

Posted: Tue Jan 31, 2017 1:08 am
by misdirekted
Hi! I was wondering if anybody could tell me how I can bulk update all of the expiration dates on our site's coupon codes? My manager has a tendency to create custom codes for different customers, and now we have over 1500 codes that she wants to make sure will not expire, but they all have different expiration dates that are coming up soon. Is there a way to change all expiration dates to the same date in year 2020 or something? Thank you!

Re: Bulk update all coupon codes

Posted: Tue Jan 31, 2017 1:18 am
by thekrotek
The fastest way is to update it via database, using PHPMyAdmin:

Code: Select all

UPDATE `oc_coupon` SET date_end = '2020-01-01'

Re: Bulk update all coupon codes

Posted: Tue Jan 31, 2017 1:23 am
by misdirekted
thekrotek wrote:The fastest way is to update it via database, using PHPMyAdmin:

Code: Select all

UPDATE `oc_coupon` SET date_end = '2020-01-01'
Wow thanks so much! Talk about a fast response - much appreciated :)