Skip to content
This repository has been archived by the owner on Apr 29, 2019. It is now read-only.

Magento modifies the SKU when creating products and SKU is already used #101

Open
federivo opened this issue Feb 16, 2018 · 3 comments
Open
Milestone

Comments

@federivo
Copy link
Contributor

Preconditions

  1. Magento 2.x
  2. PHP 5.5 5.6 7.0 7.1
  3. MySql 5.5 5.6

Steps to reproduce

  1. Create a product with SKU "ABC"
  2. Then create another product with the same SKU "ABC"

Expected result

  1. It should alert the user with an error message that the SKU is already in use by another product

Actual result

  1. Magento appends a "-1" to the SKU and saves it.
@federivo
Copy link
Contributor Author

As discussed in Feb 16th import/export meeting, @dmanners will discuss this with a Magento product owner to consider changing actual behavior regarding SKU management.

@federivo
Copy link
Contributor Author

Approved by @piotrekkaminski. Moving forward with this issue.

@federivo federivo assigned federivo and unassigned dmanners Feb 27, 2018
@federivo federivo mentioned this issue Feb 28, 2018
4 tasks
@dmanners dmanners added this to the Phase 1 milestone Feb 28, 2018
@orlangur
Copy link
Contributor

@federivo @piotrekkaminski what about SKU autogeneration for a new product? As far as I remember current behavior when SKU was left empty and autogenerated one was already in use is to show warning "SKU was changed to ABC-1" or something like that.

I don't see this case covered in linked PR.

magento-engcom-team pushed a commit that referenced this issue Apr 13, 2018
Update `zendframework/zend-code`
magento-engcom-team added a commit that referenced this issue Jul 19, 2018


 - Merge Pull Request magento/graphql-ce#101 from magento/graphql-ce:category-fragment-fix
 - Merged commits:
   1. 284f345
   2. 6c8f256
@dmanners dmanners assigned pogster and unassigned federivo Jul 23, 2018
pogster pushed a commit to pogster/import-export-improvements that referenced this issue Aug 11, 2018
pogster added a commit to pogster/import-export-improvements that referenced this issue Aug 11, 2018
pogster added a commit to pogster/import-export-improvements that referenced this issue Aug 18, 2018
pogster added a commit to pogster/import-export-improvements that referenced this issue Aug 18, 2018
pogster added a commit to pogster/import-export-improvements that referenced this issue Aug 18, 2018
pogster added a commit to pogster/import-export-improvements that referenced this issue Aug 18, 2018
pogster added a commit to pogster/import-export-improvements that referenced this issue Aug 18, 2018
pogster added a commit to pogster/import-export-improvements that referenced this issue Aug 18, 2018
…and the constraint anymore this way. Test needs to be adjusted to result in expected error.
pogster added a commit to pogster/import-export-improvements that referenced this issue Sep 11, 2018
…U won't be changed by beforeSave anymore. Only a duplicated product will receive a changed SKU on its creation.
pogster added a commit to pogster/import-export-improvements that referenced this issue Sep 11, 2018
pogster pushed a commit to pogster/import-export-improvements that referenced this issue Sep 12, 2018
pogster pushed a commit to pogster/import-export-improvements that referenced this issue Oct 23, 2018
…th the same URL key to prevent 'SKU already exists' error.
pogster pushed a commit to pogster/import-export-improvements that referenced this issue Oct 24, 2018
pogster added a commit to pogster/import-export-improvements that referenced this issue Oct 24, 2018
pogster added a commit to pogster/import-export-improvements that referenced this issue Oct 24, 2018
pogster added a commit to pogster/import-export-improvements that referenced this issue Oct 24, 2018
pogster added a commit to pogster/import-export-improvements that referenced this issue Oct 24, 2018
…and the constraint anymore this way. Test needs to be adjusted to result in expected error.
pogster added a commit to pogster/import-export-improvements that referenced this issue Oct 24, 2018
…U won't be changed by beforeSave anymore. Only a duplicated product will receive a changed SKU on its creation.
pogster pushed a commit to pogster/import-export-improvements that referenced this issue Oct 24, 2018
…th the same URL key to prevent 'SKU already exists' error.
dmanners added a commit to pogster/import-export-improvements that referenced this issue Oct 24, 2018
Clean up the header of the class to fit with the static-tests.
pogster pushed a commit to pogster/import-export-improvements that referenced this issue Nov 7, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants