I have applied filters on articles in SQL Merge Replication and syncing the data using MergeSynchronizationAgent via Web Synchronization. The data is syncing as per the applied filters from publisher to subscriber. Similarly when anything is changed on subscriber that is syncing to publisher correctly and if the data at subscriber does not lie under applied filter on publisher, that is automatically deleting from subscriber database.
All this is working well if I am syncing daily. Problem starts when I initiate a sync after a weekend, or after couple of days. Everything in the sync works except the data which should now be deleted from subscriber as it does not fulfill the applied filter criteria.
I actually have filter applied based on GetDate(), which means as soon as the next day starts and I initiate a sync, the data from the previous day should be deleted automatically from subscriber. Even in this, the publisher to subscriber direction syncing is fine i.e. the previous day's data does not sync to subscriber. But this should work the other way (subscriber to publisher) as well i.e. the last days data from subscriber should be deleted too. This is happening correctly if I am syncing daily, but not happening if I have a gap of days (like weekend) in syncing.