Support

Home Forums Event Espresso Premium Batch Upload Promo Code through DB

Batch Upload Promo Code through DB

Posted: September 23, 2016 at 1:29 am

Viewing 4 reply threads


azraai

September 23, 2016 at 1:29 am

My Problem:
I have to create a use-once only promo code for 1,500 codes. I have created the code from my Excel file (csv).
Now, I want to upload it from database (using Sequel Pro) – it is too many to do it manually one by one.

I have take a look in the tables – found this tables related.
i. Table: wp_esp_promotion
ii. Table: wp_esp_promotion_object
iii. Table: wp_esp_price

Can you advice me which table should I updated through Sequel Pro?

Thanks


Josh

  • Support Staff

September 23, 2016 at 7:28 am

For each promo code, you’ll add one row to wp_esp_promotion and one row to wp_esp_price.


azraai

September 25, 2016 at 5:36 am

Hi Josh, I tried your suggestion. It is inserted successfully.

However, the data for the “Applies To” specifically event name do not entered. Which table I should create this relationship between Coupon Code and to which event it should?
Manually you select the which event on the right column in the admin page of the “Event Espresso – Promotions”.

Thanks


Josh

  • Support Staff

September 26, 2016 at 8:32 am

The table that adds the relationship between event and coupon code is the wp_esp_promotion_object. If, however, you want a code to apply to all events, you set the wp_esp_promotion.PRO_global field to 1.


azraai

September 26, 2016 at 8:27 pm

Hi Josh, thanks for your support.

I did add a line in the “wp_esp_promotion_object” table to link to specific event in the system. And it is working.

Thanks

Viewing 4 reply threads

The support post ‘Batch Upload Promo Code through DB’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso