locked
Fetch XML- Opportunity Form RRS feed

  • Question

  • Hello, all.

    I need to create a Fetch XML on an Opportunity Form. When the form loads it returns the Contacts that are associated with the Account on that opportunity record.

    Anyhelp is appreciated!!!

    Thursday, May 29, 2014 5:50 PM

All replies

  • Hi ,

    You may create a Fetch XML using the Advanced find view. Here is the sample XML for the same. you need a data from Contact so select the contact entity then goto the related Account then go the related opportunity - once you defined the crieteria then run the query to see if that is returning the expected result then you can download the XML  by clicking download fetch XML button.

    <?xml version="1.0"?>
    @namespace html url(http://www.w3.org/1999/xhtml); :root { font:smallVerdana; font-weight: bold; padding: 2em; padding-left:4em; } * { display: block; padding-left: 2em; } html|style{ display: none; } html|span, html|a{ display: inline; padding: 0; font-weight: normal; text-decoration: none; } html|span.block{ display: block; } *[html|hidden], span.block[html|hidden] { display: none; } .expand { display: block; } .expand:before{ content: '+'; color: red; ; left: -1em; } .collapse { display: block; } .collapse:before { content: '-'; color: red; ; left:-1em; } -<fetch distinct="true" mapping="logical" output-format="xml-platform" version="1.0">-<entity name="contact"><attribute name="fullname"/><attribute name="telephone1"/><attribute name="emailaddress1"/><attribute name="address1_stateorprovince"/><attribute name="address1_city"/><attribute name="parentcustomerid"/><attribute name="mobilephone"/><attribute name="jobtitle"/><attribute name="contact_level"/><attribute name="firstname"/><attribute name="contactid"/><order descending="false" attribute="fullname"/>-<link-entity name="account" alias="ag" to="contactid" from="primarycontactid">-<link-entity name="opportunity" alias="ah" to="accountid" from="parentaccountid">-<filter type="and"><condition attribute="opportunityid" value="{4585F31B-7769-E011-8C05-005056B8537B}" uitype="opportunity" uiname="Processed Materials" operator="eq"/></filter></link-entity></link-entity></entity></fetch>

    Thursday, May 29, 2014 8:29 PM