Environment
Domino/LEI 8.5.3 64Bit
MySQL 5.5 via ODBC
Problem
I am trying to calculate the text value of a rich text field as part of the Data Transformation in a Replication Job from Notes to SQL via ODBC. This is so we don’t have to stuff a new text field LEIPRScan on all documents with a text representation of the Rich Text field that already exists.
I was able to get the data (Text) from a Notes rich text field into a SQL text field using the Notes Connection: Data Transformation: Formula to Execute During Select field when referenced from a *Direct Transfer* job, and it worked, populating the target SQL field LEIPRScan with the text of the field:
SELECT @All;
FIELD LEIPRScan := @Trim(@Text(PRScan));
I copied that same code over to the Replication Job and it runs fine the first time, populating the new field on all the rows:
Error: *Replication Conflict* Action: Update at Connector B;
Mismatch in field 'LEIPRScan';
Record key values: LEIUnid = "00062FB052F3D1D288256AFF000D9EFC"
This is great. The records get updated. But the second time it runs, it errors out:
Activity started
Trace Statement: <SELECT LEIUnid, LEIForm, DealID, PRScan FROM press_release ORDER BY LEIUnid>, Connector 'SQL Target Press Release', Method -Select-
Trace Statement: <SELECT * FROM press_release WHERE 0=1>, Connector 'SQL Target Press Release', Method -Update-
Trace Statement: <UPDATE press_release SET LEIForm = ?, DealID = ?, PRScan = ? WHERE LEIUnid = ?>, Connector 'SQL Target Press Release', Method -Update-
Error: Update at Connector B affected no records (check for key precision mismatch)
Error: *Replication Conflict* Action: Update at Connector B;
Mismatch in field 'LEIPRScan';
Record key values: LEIUnid = "11A8E9BE105C3E0E8825663500777707"
Current record key values at the time of the replication error --
- Connector A record key values: LEIUnid = "11A8E9BE105C3E0E8825663500777707"
- Connector B record key values: LEIUnid = "11A8E9BE105C3E0E8825663500777707"
Activity Ended With An Error
If I drop and recreate the table from scratch, the job runs again and populates the data. If I remove the data from the target LEIPRScan field on the SQL side, the job runs and populates the data again. If I remove the Data Transformation commands, the job runs and removes the data from the LEIPRScan field on the SQL side, as expected. If I run the job again when data is populated in LEIPRScan on the SQL , it fails.
I am sure I am missing something obvious and there is a trivial way to make this happen within the Data Transformation of a Replication job.
Notes:
1. I am using Sort Order Meta Connectors on the LEIUnid field at both ends.
2. I am not using Timestamp Replication, but I think I may want to in the future.
3. I have the Notes Connection: Selection Options: Selected View: (LEIIndexView0) configured as a static with "Select By View with Allow View Creation/Overwrite (Replication Activity only)" checked.
Troubleshooting:
I have tried selecting the"Reduced precision comparison" setting on the Replication job | Data Options | Data Comparison and Trimming section as suggested in this thread:
http://www-10.lotus.com/ldd/eiforum.nsf/0/c9f79075f9d0bf9d852571e00050324f?OpenDocument
I have entered a Selected View: (LEIIndexView0) and have selected the Allow View Creation/Overwrite (Replication Activity only) option. I checked the design of the (LEIIndexView0) view and it is using the Field not a formula to populate the one LEIUnid column, both as suggested in this thread:
http://www-10.lotus.com/ldd/46dom.nsf/55c38d716d632d9b8525689b005ba1c0/74244f8f60e10b4785256a4c004579eb?OpenDocument
This thread has an interesting idea, that the key field value is null on either end and it's causing a problem. I found that there were docs that had a Null or nonexistent LEIUnid. I excluded those, reset the SQL database and got the same behavior on only the subset of docs that do have a LEIUnid defined:
http://www-10.lotus.com/ldd/eiforum.nsf/4d21f120f5a2cf4985256a150076d0d5/71cca3aa1cdd965a85256f790076c9ce?OpenDocument
Same error here, also using meta connectors and replication job, but no suggestions:
http://www-10.lotus.com/ldd/eiforum.nsf/b0e68a3b65340bf88525688e0074731b/8bf598c1eff7fed685256f0300780558?OpenDocument
Same error here, also using meta connectors, and replication job, suggestion was to remove the delete the reference to the view in the notes connection document and uncheck the box that allows overwrite of the view in the field selection tab, which I can’t do with my current setup, I need LEI to reference the view:
http://www-10.lotus.com/ldd/eiforum.nsf/b0e68a3b65340bf88525688e0074731b/b44750c21dcb5cfe85256ebf0053daca?OpenDocument
This is the same error going the other direction (Informix to Notes), but no suggestions:
http://www-10.lotus.com/ldd/eiforum.nsf/b0e68a3b65340bf88525688e0074731b/1e55bdc2a847985085256e5b0053e235?OpenDocument
Here is the same error that was only happening when a Sybase trigger was in place, removed it and the job ran fine:
http://www-10.lotus.com/ldd/eiforum.nsf/b0e68a3b65340bf88525688e0074731b/9d0f3d8d7cb02ed085256cdf007a496c?OpenDocument