function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
glorgeglorge 

Force.com IDE: How do you deal with username differences between sandboxes?

Hi All, 

 

I'm trying to use the Force.com IDE to deploy an Email Alert from one sandbox ("stage") to another sandbox ("test").  This email alert references a specific user in our system: "jondoe@gmail.com".  

 

However - in our stage sandbox, this user's name is represented at "jondoe@gmail.com.stage", and in our test sandbox he is "jondoe@gmail.com.test".  Therefore, when I try to deploy this email alert from stage to test, I get an error saying that "User jondoe@gmail.com.stage".  

 

Has anyone figured out an effective way to deal with this issue using the Force.com IDE? 

 

Thanks,

Greg 

JonPJonP

You may want to use the Force.com Migration Tool for Ant to do this deployment.  It's a command line tool that lets you perform independent Retrieve and Deploy operations.  So you could Retrieve from one organization, edit the files locally, and Deploy to a second organization--without the IDE behavior where saving a file writes it back to the source organization.

 

Another option, using the IDE, would be to put a project into Offline Mode (right-click > Force.com > Work Offline), make your changes, and deploy using the Deploy to Server wizard.  Once that's done, you can leave Offline Mode, then Refresh from Server to undo your temporary changes.

 

Jon

salesforce.com Product Manager