You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »


When running your Agent for a DataSync integration with MS SQL Server, a directive in the agent.xml configuration file named <force_preparedstatement_reload> has its value set to true by default so that SQL statements are batched together to prevent primary key violation exceptions. You can turn off this functionality, or stop reloading prepared SQL statements, by changing the value of this directive to false according to the procedure described below.

Prerequisites


(warning) First, you will need to install a DataSync Agent configured to share data to an MS SQL Server database.

(warning) You will also need to create a ServiceNow dynamic share with an update trigger or create a ServiceNow bulk share.

Stop reloading prepared SQL statements

To stop reloading prepared SQL statements for your DataSync integration to an MS SQL Server database, follow these steps:


Access your agent.xml configuration file

Navigate to the directory where you saved your agent.xml file when installing your DataSync Agent.

Change the <force_preparedstatement_reload> directive's value to false

Open your agent.xml file in a text editing application. Then, locate the <force_preparedstatement_reload> directive and change its value to false per the example shown below:

<?xml version="1.0" encoding="ISO-8859-1" standalone="no"?>
<config>
<agent>
<share/>
<subscribe>
<task instances="4">
<task_name>ivan_test_subscribe</task_name>
<message_connection password="encrypted:vlOtU71yu8N/EFIJH85SSBtaIt7qEEfvqiqft9VZyYE=" queue="psp.out.replicator.test_2" use_basic_consume="true" user="admin">amqps://test.perspectium.net</message_connection>
<instance_connection password="encrypted:vlOtU71yu8N/EFIJH85SSPN9aF0P5/YViVwPEVFcGW4=" user="admin">https://mycompany.service-now.com>
<handler>com.perspectium.replicator.sql.SQLSubscriber</handler>
<decryption_key>The cow jumped over the moon and the sun</decryption_key>
<database_type>mysql</database_type>
<database_server>localhost</database_server>
<database_port>3306</database_port>
<database_user>root</database_user>
<database_password/>
<database_parms>characterEncoding=UTF-8 &amp; useSSL=false</database_parms>
<database_max_column_size>251</database_max_column_size>
<database>psp_repl</database>
<temporal>
<columns>
<column column_type="93" column_size="32" type="from">psp_from</column>
<column column_type="93" column_size="32" type="to">psp_to</column>
</columns>
<max_datetime>2030-12-31 00:00:00</max_datetime>
</temporal>
</task>
</subscribe>
<max_reads_per_connect>4000</max_reads_per_connect>
<polling_interval>5</polling_interval>
<skip_message_set_processing/>
</agent>
</config>

Save your agent.xml file

Save the changes you made to your agent.xml file and close the file.



  • No labels