1

How to get dynamic file name with name example "NameFileFormatYYYYMMDD.csv"? My code looks like this

<bean id="accountInsert"
    class="com.salesforce.dataloader.process.ProcessRunner"
    singleton="false">
    <description>accountInsert job gets the account record from the CSV file 
        and inserts it into Salesforce.</description>
    <property name="name" value="accountInsert"/>
    <property name="configOverrideMap">
        <map>
            <entry key="sfdc.debugMessages" value="true"/>
            <entry key="sfdc.debugMessagesFile" 
                value="C:\Users\EnrikoIr\dataloader\v47.0.0\samples\status\accountInsertSoapTrace.log"/>
            <entry key="sfdc.endpoint" value="https://login.salesforce.com"/>
            <entry key="sfdc.username" value="[email protected]"/>

            <entry key="sfdc.password" value="b96ff3a87e78db1eeb24c931ad7afab741f2e60f8220b89d05b047b2dff41468"/>
            <entry key="process.encryptionKeyFile" 
                value="C:\Users\EnrikoIr\dataloader\v47.0.0\bin\dataLoader.key"/>
            <entry key="sfdc.timeoutSecs" value="600"/>
            <entry key="sfdc.loadBatchSize" value="10"/>
            <entry key="sfdc.entity" value="Account"/>
            <entry key="process.operation" value="insert"/>
            <entry key="process.mappingFile" 
                value="C:\Users\EnrikoIr\dataloader\v47.0.0\bin\accountInsertMap.sdl"/>
            <entry key="dataAccess.name" 
                value="C:\Users\EnrikoIr\dataloader\v47.0.0\bin\insertAccounts*.csv"/>
            <entry key="process.outputSuccess" 
                value="C:\Users\EnrikoIr\dataloader\v47.0.0\bin\accountInsert_success.csv"/>
            <entry key="process.outputError" 
                value="C:\Users\EnrikoIr\dataloader\v47.0.0\bin\accountInsert_error.csv"/>
            <entry key="dataAccess.type" value="csvRead"/>
            <entry key="process.initialLastRunDate" 
                value="2005-12-01T00:00:00.000-0800"/>
        </map>
    </property>
</bean>

There's another workaround to create another task for rename file, but is it possible we put variable in dataAccess.name?

Thanks for help

1
  • 1
    were you able to find a solution to this ? Jan 3, 2021 at 14:46

1 Answer 1

0

If you're invoking the job via the command line in Windows, then you can specify parameters in the command line. To parameter for Data Access name is dataAccess.name. To learn more, check out the Data Loader Process Configuration Parameters page.

You must log in to answer this question.

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