Giter Club home page Giter Club logo

Comments (3)

smalot avatar smalot commented on August 23, 2024

Effectively the locale is usually 5 chars length, but in few cases it can be more longer :
For example :
serbian (rs_CS, sr_CS, sr_RS, sr_Latn_CS, sr_Latn_CS, sr_Latn_BA, en_US)
srpski (sr_Cyrl_CS, sr_Cyrl_BA, sr_RS, sr_CS)

The according RFC (http://www.faqs.org/rfcs/rfc1766.html) describes language tag as follow :

   The language tag is composed of 1 or more parts: A primary language
   tag and a (possibly empty) series of subtags.
   The syntax of this tag in RFC-822 EBNF is:
    Language-Tag = Primary-tag *( "-" Subtag )
    Primary-tag = 1*8ALPHA
    Subtag = 1*8ALPHA

So I suggest to increase the field size to 20 chars, which is a good compromise. Lower values would be a not necessary restriction.
I don't think there is a real interest in using a very small size for this field. An sql index would be enough in term of optimization.

BR

from pim-community-dev.

nidup avatar nidup commented on August 23, 2024

Hi,

It totally makes sense, ok for 20 chars and for add some indexes on these columns.

We'll change it in following days (just after the update to platform beta-1) in pim_catalog_locale, pim_catalog_product_value and pim_catalog_attribute_option_value (and in oro/platform FlexibleEntityBundle).

Thank you,

from pim-community-dev.

nidup avatar nidup commented on August 23, 2024

Thanks again for the feedback ! Fixed and merged on master (think about composer.phar install to update oro/platform if you want to test).

from pim-community-dev.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.