Results 1 to 5 of 5

Thread: Setting a custom 'Relate' field with SOAP

  1. #1
    mngibso is offline Junior Member
    Join Date
    Jul 2008
    Posts
    4

    Default Setting a custom 'Relate' field with SOAP

    SugarCRM Professional
    Version 5.0.0g

    I have a custom 'Relate' filed on the Opportunities Module. This is used to relate an Opportunity with an Account. I can set the value through the SugarCRM web interface to the name of an account.

    However, when I use set_entry to try and set the custom field to the name of an Account, it doesn't work. No error is returned, the value simply is not saved.

    Is there anyway to set this field through SOAP?

    Thanks,
    Mark

  2. #2
    andopes's Avatar
    andopes is offline A Sugar Hero | Help Forum Moderator
    Join Date
    Jul 2006
    Location
    São Paulo - Brazil
    Posts
    8,335

    Default Re: Setting a custom 'Relate' field with SOAP

    Hi, Mark

    All relate field are composed by 2 fields: the field_name (non-db), which is the field you are trying to save and the field_id (saved into database). I believe you have to use the set_entry passing this field.

    Cheers
    André Lopes
    DevToolKit / Project of the Month - June 2009
    Lampada Global Services- Open Source Solutions
    Avenida Ipiranga, 318
    Bloco B - CJ 1602
    São Paulo, SP 01046-010
    Brazil
    Office: +55 11 3237-3110
    Mobile: +55 11 7636-5859
    e-mail: andre@lampadaglobal.com

    Lampada Global delivers offshore software development and support services to customers around the world.
    Lampada is proud to be a SugarCRM Gold Partner, revolutionizing Customer Relationship Management.

    I DO NOT answer questions through PM and Email. If you need some help post your question into SugarForum.

  3. #3
    mngibso is offline Junior Member
    Join Date
    Jul 2008
    Posts
    4

    Default Re: Setting a custom 'Relate' field with SOAP

    Quote Originally Posted by andopes
    All relate field are composed by 2 fields: the field_name (non-db), which is the field you are trying to save and the field_id (saved into database). I believe you have to use the set_entry passing this field.

    Cheers

    Thanks! That did it. Although it looks like both the field name and field id are stored in the opportunities_cstm table.

  4. #4
    andopes's Avatar
    andopes is offline A Sugar Hero | Help Forum Moderator
    Join Date
    Jul 2006
    Location
    São Paulo - Brazil
    Posts
    8,335

    Default Re: Setting a custom 'Relate' field with SOAP

    All custom fields are stored into _cstm table to avoid modify the schema of default tables.
    But these fields are recognized by sugar as regular fields.
    André Lopes
    DevToolKit / Project of the Month - June 2009
    Lampada Global Services- Open Source Solutions
    Avenida Ipiranga, 318
    Bloco B - CJ 1602
    São Paulo, SP 01046-010
    Brazil
    Office: +55 11 3237-3110
    Mobile: +55 11 7636-5859
    e-mail: andre@lampadaglobal.com

    Lampada Global delivers offshore software development and support services to customers around the world.
    Lampada is proud to be a SugarCRM Gold Partner, revolutionizing Customer Relationship Management.

    I DO NOT answer questions through PM and Email. If you need some help post your question into SugarForum.

  5. #5
    rtpl_developer is offline Sugar Community Member
    Join Date
    Feb 2011
    Posts
    12

    Default Re: Setting a custom 'Relate' field with SOAP

    I need to set the entries into related tables of custom module. My table name is course_contacts_c and my main module name is course. I need to insert the course and contact id into course_contacts table. Please let me know how to do this using soap?

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. custom search field doesn't work
    By jojiju in forum Developer Help
    Replies: 3
    Last Post: 2008-05-01, 04:15 PM
  2. Replies: 2
    Last Post: 2007-05-07, 03:01 AM
  3. Asterisk Patch 1.1.0 Crash on logon
    By skyracer in forum Help
    Replies: 6
    Last Post: 2006-07-08, 06:30 AM
  4. Replies: 7
    Last Post: 2006-06-06, 07:56 PM

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
  •