hi I have to upload products with many variations. unfortunately it creates a very long SKU, for this reason I cannot enter these products.
is there a way to remove the limit on the number of characters in the sku?
I have read about manual changes to the database, but I doubt that with an update these changes will be canceled.
The kind of modification that you propose as a solution is not a very good idea as it breaks compatibility with the core installation and it may create unpredictable behaviour in the future when upgrading the core. This quick and dirty way of solving problems will only create problems in the future.
What I recommend is adding a custom attribute to the product object called custom_sku that can be a string and you can make it as long as you want.
Let me know if you have any concern.
Thanks
hello could you give me an example, please?
hello could you give me an example, please?
Hello @davidrossi22aa
There are two ways to remove limit of SKU.
1. Increase the limit from the database tables like catalog_product_entity
> https://prnt.sc/u95uo8 and also others where use sku field
> Now, You need to override the files where sku limit validation like https://prnt.sc/u95tso
2. You can create new attribute and consider as a SKU and insert sku inside it.
If my answer is useful, please Accept as Solution & give Kudos
@davidrossi22aa You can just create a product attribtute just like sku and named it as custom_sku and used it wherever you want to use.
Hope it helps.
Thanks