Salesforce and integration with SQL Server – part 3

SFSQL (1) As described in the previous posts, I’ve been working on a project which integrates data from Salesforce (SF) to Navision (NAV) manipulate and create new data, and then we needed to push it back to SF again.

To get all this to work together , there is a need for a local database in your SQL server, and in this case we call it LOCALSF – this is where all the stored procedures from DBAmp resides. But it is also the place for the local tables which is used to store data from the SF cloud storage.

Last post was about the creation of Insert / Update / Delete tables for SF data, so in order to i.e. insert data into the table Account – we need to have the table named Account_Insert in the database called LOCALSF.

After the table have been populated with new values, the stored procedure SF_BULKOPS need to be executed – this procedures manages the data transfer to and from LOCALSF and SF in the cloud.

exec SF_BulkOps @Operation = 'insert',
		@table_server = 'SFCLOUD',
		@load_table = 'Account_insert'

You need to set which operation that should be executed, and in this example, we are inserting values into Account from Account_insert and the operation is set to ‘insert’

After SF_BULKOPS has exe executed, we can have a look in the error attribute on the insert table – to see if everything went well – or something needs attention.

2014-12-02 15_50_05-lag Lead Functions.sql - DKCPHBI02ACS.SFDCBackEnd (REHFELD_KMN (257))_ - Microso

As you can see from the above screenshot, there was an attempt to insert 6 rows in Account, one was successful,  and the the last 5 was not inserted due to invalid email addresses. There could be someone looking at the table and solving issues, or there could be some sort of event that sends issues to a supporter.

Leave a Reply

2 comments

  1. Mark Huber says:

    I think I am missing something, what tool/tools do I need to be able to perform this? and how much do they cost?