Metadata contains all the customization you can do to your salesforce organisation. Use this tag for specific questions about the metadata itself. Use the metadata-api tag for questions on deploy/retrieve/update/delete of the metadata with salesforce organisations.

learn more… | top users | synonyms

5
votes
3answers
350 views

How do I get the length of a string field?

For a string field, is there a way to get the defined length of the field? For example say I allow a maximum of 10 chars, can I get that in apex? I am not asking how to get the length of a string ...
0
votes
0answers
11 views

Create CustomObjectCriteriaBasedSharingRule through metadata CRUD API

I'm trying to create sharing rule (critteria based) through Metadata API (wsdl imported to APEX). After many tries and fails I have got to point when I no longer know what to do. Currently I have XML ...
3
votes
3answers
51 views

Quick way to clear all classes and triggers

Long story, but I want to clear all the code from an org. I don't need to clear Visualforce pages (there is only one, and I'm deleting that manually) - just all triggers and Apex classes. Does anyone ...
1
vote
0answers
24 views

Tool to migrate field dependencies

Currently we have several controlling picklist fields that have 300-400 dependent fields under them. We are doing the field dependency matrix manually in the UI. Is there any tool that can be used to ...
12
votes
1answer
77 views

Salesforce Object with _hd suffix?

I am coming across an underscore hd ( _hd ) object in my instance, Ive not noticed this before? I have a custom object called Membershi__c I also see the following to additional objects ...
3
votes
1answer
94 views

Must specify a {http://www.w3.org/2001/XMLSchema-instance}type during creating Approval process using metadata API

I am trying to create Approval process using Metadata API but unable to figure out what i am missing. One doubt is XML don't have any symbol why which me or Salesforce could identify on which object ...
2
votes
2answers
51 views

Metadata comparison

Are there any service/known option to campare metadata on file system and some org and to identify what components have differencies. Is it possible to link this feature with Ci tool so it ...
1
vote
2answers
93 views

Force.com Migration Tool - How to correctly retrieve & deploy

I'm looking for some guidance on how this tool is widely used. We have the following scenario: Source: 1x Production org, with 1 (or more) managed packages installed. Targets: Multiple Production ...
2
votes
2answers
50 views

Finding the SObjectType from the SObjectField

As part of the implementation of an API, I would like to be able to find the SObjectType from the SObjectField: public class MyClass { // Fields are from various SObjects public void ...
1
vote
2answers
45 views

Best Practices to move metadata from sandbox to free developer org

I need to move the metadata from sandbox to free developer org.I have 7 custom objects,pages,classes,components,static resources,updates to standard objects..Please suggest the best practices and ...
6
votes
1answer
149 views

Premature End of File error while creating metadata from nodejs

I am trying to create a list view on a custom object from nodejs server. I have constructed a the SOAP(XML) body like I had done here, but I keep getting the Premature End of File error, which doesn't ...
3
votes
1answer
42 views

Is there any way via any API to track Metadata history?

I am using metadata API to retrieve the LastModifiedBy of an Object. But, it returns me only one User. I wanted to know if we can track, the Users whoever modified the Object. Is it possible by any ...
1
vote
1answer
71 views

Get address information from Metadata

I would like to get values for Address.Setting Metadata Component in Salesforce.There are stored all country and state ISO codes. <?xml version="1.0" encoding="UTF-8"?> <AddressSettings ...
2
votes
0answers
48 views

Can the MetadataService.cls be used to create Workflows via Apex?

I'm trying to use the MetadataService.cls provided by FinancialForce.com to create Workflows. The problem I am having is that the declaration for the "workFlow" class and its related components does ...
0
votes
1answer
64 views

Accessing field dependancy values in the back end

On our UI we have two picklist fields where we provided field dependancy. On the front end we can see these dependancies. Now at the backend there will be a table to store these values. I would like ...
8
votes
6answers
508 views

Bug with force.com IDE/Eclipse plugin with Spring 14 org's only

On two of my sandboxes I am getting an error every time I open a class or try to open the schema (the classes load but the schema does not). Other org's are working fine but these two, which are from ...
3
votes
1answer
68 views

profile missing list of enabled apex classes and VF pages

I'm developing a managed package and I have a test EE org provisioned from the partner portal. I made an update to a profile there and when I pulled down the latest metadata all of my apex class and ...
2
votes
1answer
136 views

Customize “Recently Viewed” list views

I have been asked to customize the generic "Recently Viewed [object]" list views that are present for Salesforce objects (note: I do not mean the [object] Tab Search Layout.) The only problem is that ...
6
votes
2answers
395 views

Resetting my development org to an empty state

I would like to clear out my development org of all artefacts on a regular basis and then do a deploy of the development package from my local source. I realise there are retrieve and list tasks ...
3
votes
2answers
58 views

Is it possible to interrogate the Flow Designer objects?

I've seen Visual Workflow and how flows and processes can be created in the flash tool. But after these are created, can they be interrogated from the SObject or metadata API? There is ...
7
votes
2answers
198 views

Some boolean values are 0/1 and some are true/false

What are the standard values for boolean datatype? I have two columns like below in different tables. One table has values like 0 and 1 and the other table has true and false. I need this to set a ...
2
votes
1answer
72 views

Best way to manage Custom Object layouts through API?

I have a Ruby on Rails application. I am asking the user for the object name that they use for invoices, i.e. "Invoice__c". With use of the metaforce gem the app creates the field "PDF_Link__c" on ...
4
votes
3answers
258 views

Are profile and permission set metadata files getting all project objectPermissions?

I have a project in development. There about 45 new SObjects to the org but there is also a couple of new profiles for the org. The permissions on several existing SObjects have been specifically ...
3
votes
1answer
206 views

Issues with managed package visibility?

Question Is anyone experiencing issues with incorrect managed package apex class visibility? Suddenly unable to save a class and everything seems to be in order. What am I missing? Anyone run into ...
4
votes
2answers
61 views

Are deployments based on components API Name?

When I do a deployment from sandbox to production is this action based on the component's API Name? I'm curious because I've deployed some code to production and am now going to setup a portal and ...
6
votes
3answers
152 views

How can I deploy objects without their profile permissions?

I would like to deploy a bunch of objects from a sandbox to Production. However, I am not yet ready to give permission to the users to use these new objects. Therefore, I do not want to deploy ...
3
votes
1answer
76 views

Filtered Lookup Meta-Data

I am using Sublime Text and Mavens Mate to bring meta-data into our Git repository. I recently added a Lookup filter to a packaged field (managed-released). The change went through in the org just ...
5
votes
0answers
82 views

Create OwnerSharingRule via Salesforce Metadata API

I'm currently struggling in creating a ContactOwnerSharingRule via the Salesforce Metadata API. I am using Ruby and the metaforce gem. I am using the the create-method which calls out to the SOAP ...
3
votes
1answer
222 views

Deploying standard picklists via Metadata API

Have some trouble deploying leadSource and Industry picklists via Metadata API. Had to comment out both of them from the build. It may have something to do with these picklists being shared by ...
4
votes
1answer
125 views

How to retrieve action overrides?

Question Is there any trick to retrieving action overrides via the metadata api? Background The docs seem to indicate this is straightforward, just use object dot notation and a type of ...
7
votes
2answers
416 views

Connected apps available via Metadata API?

When developing apps for the AppExchange, we use a development workflow in which each developer has their own DE org, but commits to a common source code repository (git in this case). We then use a ...
3
votes
1answer
77 views

Can I save anything in the *-meta.xml file?

Every .page, .cls, etc... has a *-meta.xml file (at least as viewed from Eclipse). Here is an example for a sample page: <?xml version="1.0" encoding="UTF-8"?> <ApexPage ...
2
votes
1answer
177 views

Get all page-layouts for an object via API

I am attempting to get all page-layouts (w/ details) for a given object via the API. Currently using describeLayout which gives me the details I would need about a layout, the problem with this is ...
4
votes
1answer
181 views

How do i retrieve all installed packages names through API?

I am using RetrieveRequest object to retrieve packaged and unpackaged components. Part of the code is: String[] packageName = {"Salesforce for Google AdWords"}; RetrieveRequest retrieveRequest = new ...
3
votes
2answers
426 views

How to get a list of the managed packages (including version numbers) installed in an org?

For a continuous integration setup, I only want to install/upgrade some packages (through the new InstalledPackage mechanism) when necessary. I've looked at the Metadata WSDL (and documentation) and ...
4
votes
1answer
319 views

Default states missing when state and country picklists are enabled

I've had the "state and country picklist" feature enabled in a production org today. The documentation says: In this beta release, 239 countries are provided by default, as well as the states and ...
4
votes
2answers
1k views

Access to State and Country Picklist values through Apex or API?

I recognize that State and Country Picklists are still a "Beta" feature, but does anyone know if, in Summer 13, its possible to get at the State and Country Picklist Values through either the Apex ...
10
votes
4answers
275 views

Class and Trigger packageVersions elements missing in meta XML files using Force IDE

Today two of my colleagues - one working on a na12 org and one working on a na15 org - have found that the meta.xml files that the Eclipse Force IDE pulls back for classes and triggers are missing the ...
2
votes
2answers
138 views

Is metadata api missing Record Type assignments in permission sets?

we have a use case to insert permissionsets dynamically and assign the right type of record types for objects of that particular permission set. does metadata api has the record type assignment type ...
0
votes
0answers
126 views

Changes to Workflow Metadata Email Addresses in Sandbox

We maintain all of our Salesforce metadata (classes, objects, pages, etc.) in GIT, and we use this to go between our Production and Sandboxes. Recently, when we went to do a "refresh from server", ...
5
votes
2answers
150 views

Tool for determining object custom field use

Is there a good tool that checks the schema to determine custom fields and their use in triggers, page layouts, classes, etc? We have a couple objects that are getting close to the 500 max and it ...
6
votes
1answer
176 views

Customizing Package.xml for updating Sandboxes with Continuous Integration

I am setting up a continuous integration for a team development process using GitHub and Ant (and eventually Jenkins) and have a problem with deploying to dev sandboxes to keep them in sync with ...
2
votes
2answers
306 views

Update layout in post install script

I'm developing an app for the appexchange containing custom visualforce pages/components. Instead of asking the user to create custom fields and edit layouts to place the vf pages after the ...
4
votes
1answer
157 views

Are Field History tracking objects the only Salesforce objects that have fields of DisplayType “ANYTYPE”?

Field History tracking objects, such as "AccountHistory", "ContactHistory", etc., keep track of changes to field values on records of objects with History tracking enabled on those fields. The ...
2
votes
1answer
132 views

Create Public Group from an exception/does not contain/not equal to

I need to create a public group from 'Everyone' minus another smaller public group. The public group 'Everyone' is created from everyone under Role CEO and Internal Subordinates. The smaller group is ...
3
votes
1answer
119 views

Where to edit XML for “Lookup Filter” in Force.com

I created custom lookup fields for my custom object in web UI. Some of these lookup fields have lookup field filters. I need to create the same filter for many other similar lookup fields. I ...
4
votes
3answers
308 views

Keeping picklists on multiple objects in sync

We have picklists on a couple of different objects that we want to keep in sync. I looked at the idea exchange, but was wondering if there was a good practice way for keeping them in sync. My idea is ...
2
votes
1answer
89 views

Can't find ForecastingItem sObject in DescribeGlobalResult

We recently upgraded to salesforce API v27 (from 21). Documentation says that there are some new objects added between v21 and v27. ForecastingItem object is one such object. But when I get all the ...
3
votes
3answers
136 views

Removing managed package version information from meta files

I have the same problem that is mentioned in this question and while Andrew's answer explains WHY it happens, I would like to know: Is there any way to prevent/stop managed package version information ...
8
votes
3answers
462 views

Using Force.com IDE to move schema from 1 prod org to DE org

A [similar question] was asked here 1 Copying metadata and code from one Production org to another and I have a twist on this... Assuming there are two orgs, Prod1 and DE, or Prod1 and Prod2. ...