Skip to content

Commit 27af3a4

Browse files
author
Oleksii Korshenko
authored
MAGETWO-70667: Updated EAV Attribute code max lenght #10225
2 parents 1c7ebea + 235ccff commit 27af3a4

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

app/code/Magento/Eav/Model/Entity/Attribute.php

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,12 @@ class Attribute extends \Magento\Eav\Model\Entity\Attribute\AbstractAttribute im
2121
\Magento\Framework\DataObject\IdentityInterface
2222
{
2323
/**
24-
* Attribute code max length
24+
* Attribute code max length.
25+
*
26+
* The value is defined as 60 because in the flat mode attribute code will be transformed into column name.
27+
* MySQL allows only 64 symbols in column name.
2528
*/
26-
const ATTRIBUTE_CODE_MAX_LENGTH = 255;
29+
const ATTRIBUTE_CODE_MAX_LENGTH = 60;
2730

2831
/**
2932
* Cache tag

0 commit comments

Comments
 (0)