4

We have a formula field that we want to change to a text field. We know we can't do this directly, so we need to create a new text field, then we'd remove the formula field.

What we'd like to do is programatically add the new field into any private list views that any of our 2500 users might have set up (getting them to do it manually wouldn't be palatable.)

We were hoping that we could run some SOQL against our Live Org to extract all the Private List views containing this field (or perhaps pull them from the server using Mavens Mate or similar) and then we could amend them with the new field then push them back up to Live using ANT.

However if doesn't appear that Private List views are available through the Metadata API.

Does anyone know if what we'd like to do is possible? Or is there another way? We're very comfortable with ANT, Apex, SOQL.

Any help or suggestions gratefully received!

Thanks in advance, Scott

2
  • What development tools are you comfortable with? Do you have system admin access to the org? The way I'd accomplish this is through a tool such as eclipse/force.com ide.
    – Nick C
    Commented Sep 13, 2016 at 11:10
  • We use ANT, SOQL, Maven's Mate and are comfortable with the various APIs. Our issue is more around how we see the data. It doesn't appear to be available through the metadata API Commented Sep 13, 2016 at 16:01

3 Answers 3

4

Based on my experimentation with List Views and some forum posts, you cannot do anything with private views (or even see them), regardless of your profile/permissions. Also note this help topic, which is somewhat poorly worded but more or less states that private list views will not be viewable even to System Administrators.

It looks like the ListView documentation in the Metadata API Developer Guide also contains a helpful reference:

List views with the Visible only to me Restrict Visibility option are not accessible in Metadata API. Each of these list views is associated with a particular user.

If you want to modify private list views, you have to log in as the user that created them. Note that login delegation such as this will not allow you to use ANT or any IDE outside of the Developer Console. With 2500 users, each of whom may have created multiple views referencing the field in question, modifying the list views for your users is not really feasible.

Your only realistic option is to send out an org wide email.

1
  • Thanks Adrian. I had hoped that the documentation might have been incorrect, since it seems odd that an Admin can't see them... Commented Sep 20, 2016 at 14:43
2

I suggest that, rather than deleting your formula field, you modify the formula to point to your new text field. That way, anyone who is still using the old field can continue to use it indefinitely.

Obviously, this introduces some clutter into your configuration. Make sure that you include enough detail in the Field Descriptions that a future admin will know what's going on and why.

2
  • You could also use this strategy as a "phase out" period, so users get a certain amount of warning that it will eventually be removed, with a clearly explicated target date.
    – Adrian Larson
    Commented Sep 20, 2016 at 12:33
  • Thanks for the reply. That's a good option if we can live with the clutter for a while (and trust the users to actually change their view...) Commented Sep 20, 2016 at 14:41
0

If you are deleting the formula field and loading the values to a newly created text field, private list view will loose its criteria and may not display the values as expected.

You can not automatically set this field on to all of your 2500 users as each one may have a different purpose.

Only solution is to notify all your users about this change and ask them to make a change in their private list views accordingly.

2
  • So to summarise what I think you are saying - as an Admin, I can't administer private list views owned by other people. Is that correct? Commented Sep 13, 2016 at 13:32
  • I didn't really understand what you meant by " as each one may have a different purpose.". Can you clarify? Thanks, Scott Commented Sep 14, 2016 at 16:17

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .