Guest

7xjw43

By: a guest on Jan 28th, 2012  |  syntax: None  |  size: 1.55 KB  |  hits: 24  |  expires: Never
download  |  raw  |  embed  |  report abuse
Copied
  1. Okay this is 100% solved, here are the steps i used to insert 300 vouchers at one time. Total time it took was 15 minutes.
  2. Tables to be altered in phpMysql
  3. 1) ps_discount
  4. 2) ps_discount_lang
  5. 3) ps_discount_category
  6. Steps for ps_discount
  7. (id_discount    id_discount_type        behavior_not_exhausted  id_customer     id_group        id_currency name        value   quantity        quantity_per_user       cumulable       cumulable_reduction     date_from       date_to minimal active  cart_display    date_add        date_upd)
  8. 1 in a csv file, create and update values for above fields
  9. 2 note: id_discount is the primary reference key for the other tables, so please keep track of it
  10. 3 note: for the date, the format is yyyy:mm:dd hh:mm:ss (if it is not properly set, the import will have issues)
  11. 4 next goto import (in table ps_discount), browse to your csv file and select it
  12. 5 change the options for csv (fields terminated by "," and fields enclosed by "leave blank"
  13. 6 click import and you are done
  14. Steps for ps_discount_lang
  15. (id_discount    id_lang description)
  16. - in a csv file update the values for the above fields
  17. - note id_discount should be the exact same values copied from the ps_discount csv file
  18. - follow the same steps as above (4, 5, 6)
  19. Steps for ps_discount_category
  20. (id_category    id_discount)
  21. -in a csv file update the values for the above fields
  22. - note id_category are the category numbers for all the categories you want the voucher to be active in
  23. - note id_discount should be the exact same values copied from the ps_discount csv file
  24. - follow the same steps as above (4,5,6)
  25. And thats it, you are done.
  26. Enjoy !!