akeneo / pim-community-dev

[Community Development Repository] The open source Product Information Management (PIM)
http://www.akeneo.com
Other
954 stars 514 forks source link

Product import recurring problem #5032

Closed itravais closed 4 years ago

itravais commented 8 years ago

I'm reporting a Bug

We have persistent problem to import datas in our daily batch. We observe that this problem is only on products in variant group. This problem is about images. But our import is only on datas without images. Message : PRODUCT IMPORT An exception occurred while executing 'INSERT INTO akeneo_file_storage_file_info (file_key, original_filename, mime_type, size, extension, hash, storage) VALUES (?, ?, ?, ?, ?, ?, ?)' with params ["6\/4\/7\/a\/647a66c5b33e25e2059ec4ad065ef5af31ae1772_000100570_a.jpg", "000100570_a.jpg", "image\/jpeg", 85251, "jpg", "a9821840d3838eef3bef01647c1521ecd0b6268d", "catalogStorage"]: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '6/4/7/a/647a66c5b33e25e2059ec4ad065ef5af31ae1772_000100570_a.jpg' for key 'UNIQ_F19B3719A5D32530' We are in 1.6 This produt is in variant group with other. We have image(s) on the variant group If i suppress image(s) on the variant group I see that all products in this groups have image too If i suppress image(s) on each product in this group, and re-set images on the group, the import interface work but stop it on the next product in the same config later on the import process On each product on wich i made this (suppress image on the groups, suppress images on the products in the group and re-set image on the groups), the import batch didn't stop on this product but on another in this case I have 30000 products and 580 groups, I cannot do this manually I tried to start from scratch and re-import a previous export => it doesn't work I tried to start from scratch and re-import a previous export with no image on products who are in group with image => images are automatically re-set on products from the group and it doesn't work I tried to delete product's images in database (only for products in group) => the import batch work !!! but i have an error 500 when I call the product in akeneo So, if someone have a good idea...

naolis commented 8 years ago

I have the same behavior on a 1.5 CE case. No image attribute in the variant group csv files and get the error about 'SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry 'x/x/x/x/....jpg' for key 'UNIQ_XXXXXXXXX''

rybus commented 7 years ago

Hello @itravais and thanks for reporting this issue.

I don't understand the problem you have hence I cannot reproduce it. From what I understand, you have a variant group, let's call it VG_FOO for the sake of example. This variant group has many attribute pictures. Let's say you have one image attribute.

You have many products being part of that VG_FOO variant group. At this point, what do you want to achieve? You said you wanted to remove picture from the variant group, then remove them from the product, and then reset it on the variant group. So it is unclear to me what you wanted to achieve at first.

Hello @naolis, How can I reproduce the error you get ?

Remy

itravais commented 7 years ago

Hello @rybus

The initial problem is to import data from csv file daily. After we make groups and import images with batch (not with ui), our daily import bug on some product with the message : PRODUCT IMPORT An exception occurred while executing 'INSERT INTO akeneo_file_storage_file_info (file_key, original_filename, mime_type, size, extension, hash, storage) VALUES (?, ?, ?, ?, ?, ?, ?)' with params ["6\/4\/7\/a\/647a66c5b33e25e2059ec4ad065ef5af31ae1772_000100570_a.jpg", "000100570_a.jpg", "image\/jpeg", 85251, "jpg", "a9821840d3838eef3bef01647c1521ecd0b6268d", "catalogStorage"]: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '6/4/7/a/647a66c5b33e25e2059ec4ad065ef5af31ae1772_000100570_a.jpg' for key 'UNIQ_F19B3719A5D32530' Even we don't import images but only data about products.

So we observe that the products on which have problem are only products in variant_groups. And when we make (with application user interface) the manip to suppress image on groups, suppress images on products (yes yes we have image on groups and products both ; on the same image attribute) and re-attach image on groups. We dont have problem on this product. But we have near 600 groups with many products...

I think, it's our massive images import who produce this situation. Now, as we have not automatic solution, my client do the cleaning manually on each variants_groups and included products to solve problem.

Any idea Ivan

rybus commented 7 years ago

Hello @itravais

I suggest we continue via email, can you write me one so we continue the discussion there. I will update this post when necessary to keep the community updated.

Rémy

kodea commented 7 years ago

Hello,

Do you have any news on this issue? I have the same problem.

I have variant groups with images; thoo the simples, the simples have their own, who are actualliy the same picture. Images import are separated from attributes import; when I import data for some attributes of the simples related to the variant groups, import fails with the mentionned exception.

Thanks! Jean-Paul

LaureBrosseau commented 7 years ago

Hello,

We have fixed a similar issue from 1.6.11 version. We were not able to reproduce it, can you let us know if you still experience this issue on versions above 1.6.11?

thanks!

julienanquetil commented 6 years ago

Hi,

still got some issues like that....

[2018-01-17 03:02:01] batch.ERROR: Encountered an error executing the step: An exception occurred while executing 'INSERT INTO akeneo_file_storage_file_info (file_key, original_filename, mime_type, size, extension, hash, storage) VALUES (?, ?, ?, ?, ?, ?, ?)' with params ["0\/c\/b\/a\/0cbaef1a397ba777f9153567d96cea4aaf811f01_xxxx.jpg", "xxxxx.jpg", "image\/jpeg", 78410, "jpg", "fb2661061c1624a8c4dd2f17a1924bd2f28c1004", "catalogStorage"]: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '0/c/b/a/0cbaef1a397ba777f9153567d96cea4aaf811f01_xxx' for key 'UNIQ_F19B3719A5D32530'
An error occurred during the import execution. Error #0 in class Doctrine\DBAL\DBALException: An exception occurred while executing 'INSERT INTO akeneo_file_storage_file_info (file_key, original_filename, mime_type, size, extension, hash, storage) VALUES (?, ?, ?, ?, ?, ?, ?)' with params ["0\/c\/b\/a\/0cbaef1a397ba777f9153567d96cea4aaf811f01_xxxxx.jpg", "xxxxxx.jpg", "image\/jpeg", 78410, "jpg", "fb2661061c1624a8c4dd2f17a1924bd2f28c1004", "catalogStorage"]:

SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '0/c/b/a/0cbaef1a397ba777f9153567d96cea4aaf811f01_gvFRAISES_DIAMA' for key 'UNIQ_F19B3719A5D32530'

what i didn't understand is why there in an insert into akeneo_file_storage_file_info because i'm just updating some values of simple product without updating media....

I'm on 1.7.16

thanks

jmleroux commented 4 years ago

Hello,

1.x versions are not supported anymore and i will close this issue. Do not hesitate to reopen it if needed.

Regards