You need to sign in to do that
Don't have an account?
SFDave_126
Unable to retrieve metadata via ANT Migration Tool with no warinings
I'm trying to retrieve metadata about two Standard Objects and for some reason, I'm not getting any output from the ANT Migration Tool to troubleshoot. I have the following files defined:
build.xml
package.xml
build.xml
<project name="Sample usage of Salesforce Ant tasks" default="test" basedir="." xmlns:sf="antlib:com.salesforce"> <property file="build.properties"/> <property environment="env"/> <!-- Setting default value for username, password and session id properties to empty string so unset values are treated as empty. Without this, ant expressions such as ${sf.username} will be treated literally. --> <condition property="sf.username" value=""> <not> <isset property="sf.username"/> </not> </condition> <condition property="sf.password" value=""> <not> <isset property="sf.password"/> </not> </condition> <condition property="sf.sessionId" value=""> <not> <isset property="sf.sessionId"/> </not> </condition> <taskdef resource="com/salesforce/antlib.xml" uri="antlib:com.salesforce"> <classpath> <pathelement location="ant-salesforce.jar" /> </classpath> </taskdef> <!-- See what happens here --> <target name="retrieveSOQL"> <sf:retrieve username="${sf.username}" password="${sf.password}" sessionId="${sf.sessionId}" serverurl="${sf.serverurl}" retrieveTarget="../output" unpackaged="package.xml"/> </target> </project>
package.xml
<?xml version="1.0" encoding="UTF-8"?> <Package xmlns="http://soap.sforce.com/2006/04/metadata"> <types> <members>Account</members> <members>Opportunity</members> <name>CustomObject</name> </types> <version>41.0</version> </Package>When I run 'ant -p retrieveSOQL', I get the following output with no information in my '..\output' directory:
Buildfile: C:\Users\test_user\Desktop\AntProjectFolder\salesforce\build.xml Main targets: Other targets: retrieveSOQL Default target: testI have the correct username/password specified in my 'build.properties' file so I know that's not the issue. Any ideas?
https://developer.salesforce.com/forums#!/feedtype=SINGLE_QUESTION_DETAIL&dc=Developer_Forums&criteria=ALLQUESTIONS&id=9060G000000MVrtQAG