You need to sign in to do that
Don't have an account?

Field ID's & sandboxes
Hi,
We have a config sandbox linked to a full sandbox, linked to production.
We are in the process of implementing some new code, can someone help me - do the field ID's change between the environments?
for example, we have a button that does a custom clone via a VF page and updates a lookup field. this field, do the ID's change between the different orgs or / and will salesforce auto correct this?
Thanks for any help in advance
I only said "SControl" because I looked at my list of prefixes and saw that "01N' meant SControl, completely misreading the actual ID. Regardless, yeah, you can just query for the value and use that if you have a decent way to reference it.
All Answers
Yes. Configuration-only sandboxes will most likely have different IDs for records. Only full-copy sandboxes will preserve the IDs.
hmmm...
a normal field is the following
in a config sandbox a field ID is 00N20000001CdTh
in the full sandbox the field ID is 00N20000001CdTh
In the production instance is 00N20000001CdTh
Lookup fields look like the following
config 00ND0000003jGJ2
full 00NL0000000JtOB
production 00ND0000003jGJ2
so i need some advice. If i am building some VF that uses the field ID and the _lkid to fill the lookup, should i just deploy from the config sandbox to production? or is there a way to match everything up between config / full / production?
Well the IDs depend on what you're doing with the data. If you have a record in Production and refresh the Full sandbox, the ID will be the same. If you create a record in both after the refresh, they will have different IDs.
If you're coding a VisualForce page with an ID in it, you're doing it wrong. If it's an SControl, you should be able to query for the ID of the SControl in your controller class, then expose that ID as a property to your VisualForce page.
apologies, there is an apex class doing the work.
having a look at the clients full sandbox the last refresh was over a year ago so i will suggest they refresh it then i will re-deploy from dev to full and then check.
Thanks for the help
I only said "SControl" because I looked at my list of prefixes and saw that "01N' meant SControl, completely misreading the actual ID. Regardless, yeah, you can just query for the value and use that if you have a decent way to reference it.
Its not the record ID thats become disjointed, its the actual ID of the lookup field. config and prod are the same, full is different.
Yeah, but the methodology should still get you what you need, right?
yeah i guess, i will give it a go