select items to be sync'd by newer modified date

mylesolsonmylesolson Posts: 3
Here's the story:

I have a saleslogix remote database = SLXRemoteDB and a master saleslogix DB = SalesLogixDB

I need to automate the generation of a sync script so that any data in the SLXRemoteDB will be selected to update SalesLogixDB only when the SLXRemoteBD date is newer than the SalesLogixDB.

There are thousands of items so manually going through and selecting them all by which one has a newer modify date isn't practical.

Can someone please help me?

Thanks

Comments

  • Brian DonahueBrian Donahue Posts: 6,590 Bronze 1
    Hello,

    You can implement this type of horizontal data filtering using SQL Toolkit. If you can use Visual Studio or another .NET Framework development environment, and have a fair grasp of programming in VB or C#, you could write a small program that can compare the date values and include/exclude records from the synchronization based on the values.

    Please let me know if you're interested... I can send an example of this very thing that I have written in C# and VB to your email address.
  • OK...I think i've got this somewhat figured out but I"m still missing a few steps.

    when i run:
    C:\Comparator>DataChooseRecords.exe /server1:computer /db1:SalesLogix /user1:sa /password1:password /server2:computer /db2:SLXRemote /user2:sa /password2:password

    I get an error regarding licensing to which I respond OK

    Then the application outputs to my cmd windows:
    Unhandled Exception: System.NullReferenceException: Object reference not set to
    an instance of an object.
    at RedGate.ToolkitChooseRecords.ChooseRecords.GenerateDataSyncScript(String sDBSourceServer, String sDBSourceName, Boolean bSourceIntegrated, String sDBSourceUser, String sDBSourcePassword, StringsDBTargetServer, String sDBTargetName, Boolean bTargetIntegrated, String sDBTargetUser, String sDBTargetPassword, SessionSettings enDataCompareOptions) at RedGate.ToolkitChooseRecords.ChooseRecords.Main(String[] args)

    It's the "differnt records" code i'm supposed to be using right?

    Help?!
  • Brian DonahueBrian Donahue Posts: 6,590 Bronze 1
    Hello,

    I am going to send you an email about this to avoid confusing people with information about a custom application.

    Thanks!
This discussion has been closed.