Page 1 of 2 12 LastLast
Results 1 to 10 of 11

Thread: Custom Field - Field names

  1. #1
    xray is offline Junior Member
    Join Date
    Feb 2005
    Posts
    3

    Default Custom Field - Field names

    Hi,

    i took a look into the database and saw that the custom_fields table contains all the values of the custom fields for a corresponding ID. But i have nowhere found the Lable name of the custom field. Where is iit stored??? Christoph

    Thank you in advance,

  2. #2
    chrismartin is offline Junior Member
    Join Date
    Feb 2005
    Posts
    4

    Default Re: Custom Field - Field names

    haven't got sugar open in front of me but have you looked in
    \cache\custom_fields\custom_fields_def.php file.

    or something like that path?

  3. #3
    xray is offline Junior Member
    Join Date
    Feb 2005
    Posts
    3

    Default Reporting on Custom Fields

    Yes you are right. It is stored in an array in that php file. I need to create reports based on custom fields and i am now wondering how i could do that if the field names are not in the database....
    i.e. A answer to the following question: How many open Opportunities exist where Opportunity.custom.field Territory=Europe?

    Any idea? Has someone already done that?

  4. #4
    blex2005's Avatar
    blex2005 is offline Sugar Community Member
    Join Date
    Aug 2004
    Posts
    101

    Default Re: Custom Field - Field names

    Each object as a customfield attirbute that stores the custom fields. In addition you can locate the field info through the field_defs in the object (such as Opportunities). So you don't need to read the file. If you look through the initialization code of the class, like Opportunity you will see where the CustomFields are added to the class.
    Do you have children? Want to enjoy and support them more?
    Check out Family Matters from Weiner Family Studios.
    Or follow us on twitter @weinerfamily.



    Scott Weiner
    CRM Consultant
    BrokerSuite, LLC
    SugarCRM Business Partner

    sweiner@brokersuite.com
    "Customized CRM solutions"
    www.blueriverassociates.com
    www.brokersuite.com




  5. #5
    rangel is offline Member
    Join Date
    Sep 2004
    Posts
    78

    Default Re: Custom Field - Field names

    Reports for Custom Fields will be available in the next release coming out soon: 2.5.1

  6. #6
    andreasw is offline Sugar Community Member
    Join Date
    Mar 2005
    Posts
    130

    Default Re: Custom Field - Field names

    Maybe I'm missing something...
    I still don't understand where custom_field entries are stored.
    Let's say I have a custom_fields_def like

    2 =>
    array (
    'name' => 'department',
    'label' => 'MOD.LBL_DEPARTMENT',
    'type' => 'char',
    ),

    Where is this stored inside the sugarcrm database.
    I cannot find a field called "department" .

    Any hints?
    Thanks in advance,

    Andreas

  7. #7
    florent is offline Sugar Community Member
    Join Date
    Mar 2005
    Posts
    31

    Default Re: Custom Field - Field names

    Hi.

    I've been searching for some time before understanding this .
    In fact, in the sugar DB, you will find "custom_fields" table; used to store your custom fields you've added.

    bean_id -> stores the id of the module (eg contact_id, task_id, call_id, ...).
    field0 to field9 : mapped with the custom fields you've added (in contacts, tasks, calls, ...)

    To see which field correspond to field0, for instance, I've looked the value stored in the table. I don't know if they're stored in the order they're created ?

    Maybe they're still other things to know

    Florent.

  8. #8
    midwaypg is offline Sugar Community Member
    Join Date
    Feb 2005
    Posts
    53

    Default Re: Custom Field - Field names

    I agree with Andreas, I would like to see the field name stored in the table. Is there a way to add the custom field into the appropriate table and NOT to be effected by new upgrades?? What I mean is that if i create a custom field called "Program" in Opprtunities, is there a way to add that field to the opportunities table? If yes what changes do i need to do?

    Thanks in advance

    Mike

  9. #9
    philipc is offline Junior Member
    Join Date
    Apr 2005
    Posts
    4

    Question Re: Custom Field - Field names

    I have the same questions... Perhaps a good documentation about the way tu use with this could be a better answer?

  10. #10
    Vince is offline Sugar Community Member
    Join Date
    Jul 2004
    Posts
    92

    Default Re: Custom Field - Field names

    Just pay attention that all custom_fileds are in only one table. And if this table gets too big response time of queries will increase deeply.
    Sometime consider spending a few minutes adding your field into your table especilaly if you have a lot of lines (several thousands) in it.

    Custom fields is an easy way to add fields and is very useful but just think to this if your business is big enough and contains thousands of lines. Also consider using MySQL 4.X in this case because LEFT join used in SugarCRM are very faster with it (MySQL engine was improved also on this).

    Vince
    Last edited by Vince; 2005-04-08 at 12:45 PM.
    SYNOLIA
    Oldest SugarCRM partner in the world and Gold Partner / Partenaire GOLD SugarCRM
    Official French Translator / Responsable de la traduction Française

    51 Avenue Jean Jaurès - 69007 LYON - FRANCE - Tel : +33 4 27 70 53 70
    www.synolia.com | @synolia sur Twitter
    www.crm-france.com | Forum CRM-France

Page 1 of 2 12 LastLast

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •