Transactional Replication with a Twist

  • I have two databases in a stock trading company that will use replication to sync data. The propose method will be Transactional Replication at 1min intervals.

    MAIN- Main Database (Located at Head Office)

    This database contains all trading and admin and performance data.

    SUB - Trading Database (Located at Johannesburg Stock Exchange)

    This database contains only live trades that are currently in the market.

    I will use replication to sync data from SUB to MAIN with replication. Everyday 100s of trade data records are inserted on SUB on daily basis. This data need to be sync to MAIN where it will be processed for admin and performance statistics. After a Trade has been closed, all its data needs to be removed from Thor. This means that SUB will contain limited data, which will ensure very small high speed trading database.

    Here is my question:

    I will delete this "old" data on SUB after I have synced it to MAIN. But because I'm using the Transactional method of Replication, I fear when I sync again the log will state that I deleted data on SUB and thus delete it on MAIN.

    SO how can I remove the data on SUB and not worry about it being deleted on MAIN due to the Transactional method.

    [font="Courier New"]-----------------------------------------------------------------------------------------------------------------------
    😀 Arguing with Programmers are like wrestling a pig in mud, soon you realize the pig is enjoying it. 😀
    -----------------------------------------------------------------------------------------------------------------------[/font]

  • I was thinking towards something in the line:

    Temporarily Disable Logging to Transaction Log

    Executing the DELETE statements but ensuring that it doesn't get written to the log.

    [font="Courier New"]-----------------------------------------------------------------------------------------------------------------------
    😀 Arguing with Programmers are like wrestling a pig in mud, soon you realize the pig is enjoying it. 😀
    -----------------------------------------------------------------------------------------------------------------------[/font]

  • Will there be other deletes on SUB that you will want replicated to MAIN? If not you can adjust your articles to not replicated delete commands.

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply