[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Dolibarr-dev] Question about dictionnary => id versus code

From: Florian HENRY
Subject: [Dolibarr-dev] Question about dictionnary => id versus code
Date: Fri, 24 Oct 2014 14:13:08 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.2.0

Hello all,
I wondering something about best practice with dictionnary dolibarr implementation.

    I take two exemple about thirdparty.
llx_societe.fk_prospectlevel : a foreign key on llx_c_prospectlevel.code
        The dictionnay llx_c_prospectlevel don't have rowid column

    llx_societe.fk_typent => a foreign key on
The dictionnary llx_c_typent have a id column (should be renamed into rowid by the way) but also get a code column

    What is the best strategy, to your mind, with dictionnary :

        1 :
            llx_dictionnary_1 (rowid,code,label,active)
            llx_table.fk_dict1 => llx_dictionnary_1.rowid

        2 :
            llx_dictionnary_1 (rowid,code,label,active)
            llx_table.fk_dict1 => llx_dictionnary_1.code

For me the best option is 1 but in this case what is the purpose of a "code" column ?


Florian Henry
+33 6 03 76 48 07
Twitter : @_Open_Concept_
Google+ :

reply via email to

[Prev in Thread] Current Thread [Next in Thread]