+ Start a Discussion
Ravi_SFDCRavi_SFDC 

Salesforce DX - Need help on Scratch Org

I have default scratch org in my Visual Studio Code which has modified code now I would like to push the changes to a direct ORG. Any help or suggestion would be highly appreciated.

  
Best Answer chosen by Ravi_SFDC
Raj VakatiRaj Vakati
I gave Reference .. You can do it both and the steps in remains same .. ( from Scrath or to any org using mdapi )

if you deploy using the  mdapi Commands you can able to specify the target org
 
https://developer.salesforce.com/docs/atlas.en-us.sfdx_cli_reference.meta/sfdx_cli_reference/cli_reference_force_mdapi.htm


-u | --targetusername TARGETUSERNAME

All Answers

Ravi_SFDCRavi_SFDC
I have default scratch org in my Visual Studio Code which has modified code now I would like to push the changes to a different ORG. Any help or suggestion would be highly appreciated.
 
Raj VakatiRaj Vakati
You can able to do it easily using metadata  

 https://www.jitendrazaa.com/blog/salesforce/using-salesforcedx-sfdx-with-non-scratch-orgs/

or you can able to do it using package also 

https://developer.salesforce.com/docs/atlas.en-us.sfdx_dev.meta/sfdx_dev/sfdx_dev_build_mdapi_deploy.htm
Ravi_SFDCRavi_SFDC
Thank you, Raj. I would need for the scratch org for PROD, but not for the non-scratch org. As the non-scratch orgs are for the sandboxes. Please, correct. 
Raj VakatiRaj Vakati
I gave Reference .. You can do it both and the steps in remains same .. ( from Scrath or to any org using mdapi )

if you deploy using the  mdapi Commands you can able to specify the target org
 
https://developer.salesforce.com/docs/atlas.en-us.sfdx_cli_reference.meta/sfdx_cli_reference/cli_reference_force_mdapi.htm


-u | --targetusername TARGETUSERNAME
This was selected as the best answer
Ravi_SFDCRavi_SFDC
Thank you, Raj for the valuable info. Would try with mdapi and if needed anything additional will get back to you.
Raj VakatiRaj Vakati
Thanks 
Raj VakatiRaj Vakati
Is its working ??