+ Start a Discussion
Sunil NandipatiSunil Nandipati 

Apex Data Loader Command Line Interface

How can i successfully connect to a remote server (SQL Server 2005). 

I created a system DSN connection and i am using the same.  My bean looks like this

 

<bean id="dbDataSource"
      class="org.apache.commons.dbcp.BasicDataSource"
      destroy-method="close">
    <property name="driverClassName" value="sun.jdbc.odbc.JdbcOdbcDriver"/>
    <property name="url" value="jdbc:odbc:FWDCRMOEP;databaseName=SFDCSTGCRM;selectMethod=cursor;"/>
    <property name="username" value="my_sql_username"/>
    <property name="password" value="my_sql_password"/>
</bean>

 ... and my error looks like this

 

11281 [CompanyMasterProcess] ERROR com.salesforce.dataloader.dao.database.DatabaseReader  - Database error encountered during setup of the database configuration: queryCompany.  Sql error: Invalid Fetch Size.
java.sql.SQLException: Invalid Fetch Size
 at sun.jdbc.odbc.JdbcOdbcStatement.setFetchSize(JdbcOdbcStatement.java:826)
 at org.apache.commons.dbcp.DelegatingStatement.setFetchSize(DelegatingStatement.java:276)
 at com.salesforce.dataloader.dao.database.DatabaseReader.setupQuery(DatabaseReader.java:140)
 at com.salesforce.dataloader.dao.database.DatabaseReader.open(DatabaseReader.java:109)
 at com.salesforce.dataloader.dao.database.DatabaseReader.open(DatabaseReader.java:97)
 at com.salesforce.dataloader.util.DAORowUtil.calculateTotalRows(DAORowUtil.java:59)
 at com.salesforce.dataloader.dao.database.DatabaseReader.getTotalRows(DatabaseReader.java:209)
 at com.salesforce.dataloader.action.AbstractLoadAction.<init>(AbstractLoadAction.java:83)
 at com.salesforce.dataloader.action.BasePartnerLoadAction.<init>(BasePartnerLoadAction.java:44)
 at com.salesforce.dataloader.action.UpsertAction.<init>(UpsertAction.java:47)
 at com.salesforce.dataloader.action.ActionFactory.getActionInstance(ActionFactory.java:77)
 at com.salesforce.dataloader.controller.Controller.executeAction(Controller.java:113)
 at com.salesforce.dataloader.process.ProcessRunner.run(ProcessRunner.java:130)
 at com.salesforce.dataloader.process.ProcessRunner.main(ProcessRunner.java:222)
11281 [CompanyMasterProcess] ERROR com.salesforce.dataloader.util.DAORowUtil  - Error Calculating Total Rows
com.salesforce.dataloader.exception.DataAccessObjectInitializationException: Database error encountered during setup of the database configuration: queryCompany.  Sql error: Invalid Fetch Size.
 at com.salesforce.dataloader.dao.database.DatabaseReader.setupQuery(DatabaseReader.java:148)
 at com.salesforce.dataloader.dao.database.DatabaseReader.open(DatabaseReader.java:109)
 at com.salesforce.dataloader.dao.database.DatabaseReader.open(DatabaseReader.java:97)
 at com.salesforce.dataloader.util.DAORowUtil.calculateTotalRows(DAORowUtil.java:59)
 at com.salesforce.dataloader.dao.database.DatabaseReader.getTotalRows(DatabaseReader.java:209)
 at com.salesforce.dataloader.action.AbstractLoadAction.<init>(AbstractLoadAction.java:83)
 at com.salesforce.dataloader.action.BasePartnerLoadAction.<init>(BasePartnerLoadAction.java:44)
 at com.salesforce.dataloader.action.UpsertAction.<init>(UpsertAction.java:47)
 at com.salesforce.dataloader.action.ActionFactory.getActionInstance(ActionFactory.java:77)
 at com.salesforce.dataloader.controller.Controller.executeAction(Controller.java:113)
 at com.salesforce.dataloader.process.ProcessRunner.run(ProcessRunner.java:130)
 at com.salesforce.dataloader.process.ProcessRunner.main(ProcessRunner.java:222)
Caused by: java.sql.SQLException: Invalid Fetch Size
 at sun.jdbc.odbc.JdbcOdbcStatement.setFetchSize(JdbcOdbcStatement.java:826)
 at org.apache.commons.dbcp.DelegatingStatement.setFetchSize(DelegatingStatement.java:276)
 at com.salesforce.dataloader.dao.database.DatabaseReader.setupQuery(DatabaseReader.java:140)
 ... 11 more
11281 [CompanyMasterProcess] FATAL com.salesforce.dataloader.process.ProcessRunner  - Database error encountered during setup of the database configuration: queryCompany.  Sql error: Invalid Fetch Size.

 

Plz advice.

saurabh_gupta28saurabh_gupta28

Hey,

 

I am facing the same problem,is there anyone to help me please