ConcourseSuite Support

Support
Corporate
PUBLIC PROFILE

Back to topics

Discuss Development

Fields that can be used with DataRecord.

You need to be logged in to post messages

Fields that can be used with DataRecord.

12/11/2008 5:10 AM EST (edited)

Hi.

Can someone tell me where in the docs I can find a list of the fields that can be set for records of different types. eg:
CRMConnection crm = createConnection();

DataRecord contact = new DataRecord();
contact.setName("contact");
contact.setAction(DataRecord.INSERT);
contact.setShareKey(true);
contact.addField("nameFirst", "Jeff");
contact.addField("nameLast", "Gehlbach");
contact.addField("company", "Malta");
contact.addField("title", "Knight of Order");
contact.addField("source", "Always");
contact.addField("isLead", "true");
contact.addField("accessType", 2);
contact.addField("leadStatus", 1);
contact.addField("enteredBy", 0);
contact.addField("modifiedBy", 0);

That adds a lead. Where can I find a list of the fields ike 'company', 'isLead' ... that I can set and what their values mean in the case of numerical values?

Thanks
Daniel

1. 12/11/2008 8:55 AM EST

Daniel,

You could look at the import-mappings.xml which has a xml definition for each object. There is a class for each object type (contact, account etc) and a set of fields that the base object has defined.

If you see a 'lookup' attribute then that means the field references another object and the field is a foreign key.

A Lead, Contact and Employee are all individuals and are hence represented by one base object called Contact.java ('contact' in the mappings file). The xml definition for 'contact' has boolean fields that indicate if it is a lead or an employee.

Hope that helps...

Ananth

2. 12/11/2008 9:22 AM EST

Ananth Balasubramanyam wrote:
Daniel,

You could look at the import-mappings.xml which has a xml definition for each object. There is a class for each object type (contact, account etc) and a set of fields that the base object has defined.

If you see a 'lookup' attribute then that means the field references another object and the field is a foreign key.

A Lead, Contact and Employee are all individuals and are hence represented by one base object called Contact.java ('contact' in the mappings file). The xml definition for 'contact' has boolean fields that indicate if it is a lead or an employee.

Hope that helps...

Ananth


That was extremely helpful. Thanks a lot.

-Daniel

3. 12/11/2008 9:46 AM EST

There is one thing I'm still unsure of.
From the xml for 'contact'
<property field="lead">isLead</property>
<property field="lead_status">leadStatus</property>

How can I find out what possible values leadStatus can take and what each will mean?
How would I know that it is a numeric field?

I guess the booleans will generally begin with 'is'.

-Daniel

3 results found