Jump to content

Problem importing categories from eBay to PS / sort of solved but...


hypergiro

Recommended Posts

hi all,

I'm afraid I'm posting regarding an old problem, but searching the forum did not bring up any solution. I'll try to explain as accurately as possible.

 

I am using eBay module 1.9.2 and get stuck when I try to load the eBay categories in PS, before sync. I go on Shop categories, hit reload and the error I get is:

INSERT INTO `ps_ebay_store_category` (`id_ebay_profile`, `ebay_category_id`, `name`, `order`, `ebay_parent_category_id`) VALUES ('3', '9713240013', 'Maglieria', '2', '0')

If I run the query manually, from within the muSQL interface, i get this error: #1062 - Duplicate entry '3-2147483647' for key 'id_ebay_profile'

 

I tried to look into it a bit and went into the ps_ebay_store_category. I noticed that the second category loaded (the first is 'Other' and appears automatically) has 2147483647 as ebay_category_id value. If i change this value to a more approachable '1' value (0 being 'Other'), I can sort of solve the issue.

 

now, the number 2147483647 rang a bell; in fact to cite Wikipedia is the eighth Mersenne prime, equal to 231 − 1. Basically it's also the biggest value for an int field, or so is my understanding. Obviously I cannot put any bigger value. I tried to change the structure of the table and replaced int(16) with int(32) to no avail. I then changed to BIGINT and lo and behold, it works: it imports everything.

 

Now

 

1- is this normal behavior?

2- (mostly) will there be any issue or any unexpected consequence now that I changed to BIGINT? does anyone know what queries are run against these fields?

3- even though subcategories are imported in the database and correctly linked, they do not appear in the eBay shop categories PS module: only main categories appear. Is this normal behavior again? any workaround?

 

thanks in advance.

cheers

hyp

Edited by hypergiro (see edit history)
Link to comment
Share on other sites

  • 1 month later...

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...