Results 1 to 3 of 3
  1. #1
    Join Date
    Dec 2012

    Unanswered: problem in refresh the destination table (replication)

    i have two program (App1 And App2) on two seperate system.on App1 there is a database named DB1 and on App2 there is a database named DB2.on DB1 i create a table named Table_1 .i define replication for DB1 to push publication (for table_1) .i define DB2 as a subscriber to recive all changes on [DB1].[Table_1]. every thing is ok but just one thing. when App1 and App2 both are running if i change the contents of [DB1].[Table_1] this change only shown if one time i exit from App2 and rerun it . how can i refresh App2 without rerun it?
    a frind said to me it is posible with trigger.but how? i dont know how can i define a trigger for this reason . or any way that exist for this reason.

  2. #2
    Join Date
    Jan 2013
    Woodland Hills, CA
    pooya1072, when you say App2, is this a client app? In other words, is it a separate application? If it's a client app, it's up to the app to interrogate the tables to refresh the view it's presenting to the user. If your replication is setup correctly, you should be able to see the most recent rows in table 1 also being in table 2.

    It sounds like you may have a latency issue. In other words, the data in table 1 doesn't get replicated over to table 2 in a timely manner. Even if it does get replicated over immediately, it's still up to the application to re-pull the data.

    Your friend is correct, you could setup a trigger in table one that copies the data over to table 2, but again, you'd still have to code the app so that it periodically refreshes its view based on data that's in table 2. Hope this helps.

  3. #3
    Join Date
    Jun 2003
    Provided Answers: 1
    Don't follow your friend's advice. Do not use a trigger to copy data from one system to another.
    Debug your replication issue.
    If it's not practically useful, then it's practically useless.

    blindman "sqlblindman"

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts