How to generate/import hundreds of coupons?

  • Posts: 174
  • Thank you received: 2
  • Hikashop Business
10 years 11 months ago #135305

I need to have hundreds or thousands of coupons. Ho can i generate or import (even better) them?
If i will need to do it manually i'll probably will get old before i'll do that :)

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
10 years 11 months ago #135319

Hi,

In HikaShop there is no batch generation or import system for the coupons.
But in HikaSerial, you have a batch generation for coupons. Using the "coupon generator", you can generate manually serials which will generate coupons.
You can also generate dynamically some coupons, for example if you want to send coupons in an Acymailing newsletter.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 174
  • Thank you received: 2
  • Hikashop Business
10 years 11 months ago #135323

so if i need to have a thousand coupons 00007,00008,00009,00010,00011 ... 01007 HikaSerial will do that for me?

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
10 years 11 months ago #135341

Hi,

The coupon generator will create the coupon code, it uses a random algorithm for the coupon codes so it is not easy to "find" a code like that.
When you have a coupon generator used in a pack (a pack is a group of serials) you can "generate" serials and specify a number of coupon you want to create (it can be a thousand of coupon if you want).

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 174
  • Thank you received: 2
  • Hikashop Business
10 years 11 months ago #135343

sorry, but it seems that it is something i don't need. I don't mind to pay for HikaSerial, but it just isn't what i need. I just need the possibility to generate a number of codes, shoose codes format and coupons options. Maybe i can use INSERT INTO function and add all coupons directly to database throught phpmyadmin?

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
10 years 11 months ago #135348

Hi,

Yes you can insert directly your coupons in the database. The best is to copy the values of an existing coupon in order to right fill all columns correctly.

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 174
  • Thank you received: 2
  • Hikashop Business
10 years 11 months ago #135351

i just run SQL guery on my datadase:

INSERT INTO qdvsk_hikashop_discount(discount_type, discount_percent_amount, discount_code, discount_published, discount_currency_id, discount_coupon_nodoubling, discount_coupon_product_only, discount_affiliate)VALUES( 'coupon','30','888','1','91','0','0','-1');

and it seems that did the trick. My coupon is ready to use. Now i need somehow to generate as many these queries as i need coupons, i think i'll use MS Access for that, because codes i already have in my excel table.

Please Log in or Create an account to join the conversation.

  • Posts: 15
  • Thank you received: 1
10 years 1 month ago #172728

export excel table to csv, and there are doesn't of simple ways to script your import a csv to your table --
the most rudimentary would be a script to generate your sql insert statements from the csv.

perl, php, ruby, even a shell script could be used to create your sql insert statements.

ruby has some nice gems to make connecting to the db, and processing csv fairly simple. I have to do this -- and i"m going to use ruby -- I'll post my script here for the benefit of the community. As it looks like this is a fairly common request with things like groupon, etc.

The following user(s) said Thank You: Jerome

Please Log in or Create an account to join the conversation.

Time to create page: 0.079 seconds
Powered by Kunena Forum