Jump to content

Artikel per ID in zusätzliche Kategorie schieben


Recommended Posts

Hallo,

 

ich habe mir ja per SQL Script die Artikel exportiert, die ich bereits verkauft habe.

 

Nun hat mich der Support vom eBay Modul auf die Idee gebracht, dass ich die Artikel ja einer Kategorie "ebay" zuweisen kann. So muss ich nicht im Modul selbst in den Konfiguration immer was ändern. 

 

Es wird also dann nur noch die Kategorie "Ebay" Synchronisiert. Super Lösung :)

 

Aber: Wie bekomme ich jetzt die IDS 1,2,3,4,5,6,7,8,9 etc. zusätzlich in die Kategorie "110" - eBay...?

 

Jemand eine Idee dafür?

 

 

Im PMA ist ja u.a. Die Tabelle "ps_product" da ist aber nur die default category zu finden

 

Dann gibt es die Tabelle "`ps_category_product`"

 

Würde es reichen die ID zu updaten?

 

bzw. in der Struktur müsste es ein insert sein, oder?

 

Ist ja nicht product_id:1,2,3,4,5,6,7,8,9 und dann category_id:110

 

Ist ja 

product_id:1 category_id:110

product_id:1 category_id:1

product_id:1 category_id:2

product_id:1 category_id:3

 

etc...

 

 

Was genau heißt "Position" in der Tabelle: "ps_category_product" ?

 

Meine Lösung wäre so:

INSERT INTO `ps_category_product` (`id_category`, `id_product`, `position`) VALUES ('110', '1', '0');
INSERT INTO `ps_category_product` (`id_category`, `id_product`, `position`) VALUES ('110', '2', '0');
INSERT INTO `ps_category_product` (`id_category`, `id_product`, `position`) VALUES ('110', '3', '0');
INSERT INTO `ps_category_product` (`id_category`, `id_product`, `position`) VALUES ('110', '4', '0');
INSERT INTO `ps_category_product` (`id_category`, `id_product`, `position`) VALUES ('110', '5', '0');
INSERT INTO `ps_category_product` (`id_category`, `id_product`, `position`) VALUES ('110', '6', '0');

Allerdings weiß ich nicht, was ich mit der dämlichen "position" machen soll oder muss.

 

Muss die genauso hoch gesetzt werden? also  quasi so:

INSERT INTO `ps_category_product` (`id_category`, `id_product`, `position`) VALUES ('110', '1', '1');
INSERT INTO `ps_category_product` (`id_category`, `id_product`, `position`) VALUES ('110', '2', '2');
INSERT INTO `ps_category_product` (`id_category`, `id_product`, `position`) VALUES ('110', '3', '3');
INSERT INTO `ps_category_product` (`id_category`, `id_product`, `position`) VALUES ('110', '4', '4');
INSERT INTO `ps_category_product` (`id_category`, `id_product`, `position`) VALUES ('110', '5', '5');
INSERT INTO `ps_category_product` (`id_category`, `id_product`, `position`) VALUES ('110', '6', '6');
Edited by Lausli (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...