Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Import/Export (DTS) and Replication (2000)
 Urgent help with replication and data filtering

Author  Topic 

Giorgio
Starting Member

7 Posts

Posted - 2007-09-27 : 06:59:25
Hi,

I have a transactional replication with 2 subscribers and I want to filter the data to one of the subscribers but I cannot do it with the row filtering options on replication because it doesn't allow join filters which are only allowed on merge replications so how can I do that with transactional?
If you look below an example of tables I have, I am trying to publish only the data that have the COnline set to 1 on table C but want to do a join on Table D and E so that only the records on Tables C, D and E have COnline set to 1 will be published. I hope you understand what I mean.
How can I do this? Please provide me with clear example or instructions if possible.

Thanks so much

I have a table C with

CID(id) Cname(varchar) COnline(bit)
1 Name1 1
2 Name2 0
3 Name3 1
4 Name4 1

Then I have Table D with

DID(CID) DAge(int) Dreport(bit) Daddress(varchar)
1 20 1 address1
2 34 1 address2
3 25 0 address3
4 41 0 address4

Then I have Table E with

EID(CID) ESS1(text) ESS2(text) ESS3(text)
1 a lot text a lot text a lot text
2 a lot text a lot text a lot text
3 a lot text a lot text a lot text
4 a lot text a lot text a lot text

rmiao
Master Smack Fu Yak Hacker

7266 Posts

Posted - 2007-09-28 : 01:07:27
Can you create a view for that then replicatre the view?
Go to Top of Page

Giorgio
Starting Member

7 Posts

Posted - 2007-09-28 : 04:11:14
If I replicate the view then the data is not replicated! Sorry I really don't understand what you mean by replicating a view! A view has no data it has just Transact SQL. And I have data in another 10 tables to be replicated.
Go to Top of Page

rmiao
Master Smack Fu Yak Hacker

7266 Posts

Posted - 2007-09-28 : 22:57:54
Then need set filter in all related tables.
Go to Top of Page

Giorgio
Starting Member

7 Posts

Posted - 2007-09-29 : 06:10:45
If you read well my first post I mentioned that I cannot set filters because transactional replication do not support join filters!
The filter has to be based on Column COnline from Table A so I cannot do joins on any other tables!!
Go to Top of Page

Giorgio
Starting Member

7 Posts

Posted - 2007-09-29 : 06:11:23
Can anybody help me please?!
Go to Top of Page

rmiao
Master Smack Fu Yak Hacker

7266 Posts

Posted - 2007-09-29 : 22:17:13
That's why need set filter on all related table without join. If you really need join filter, then have to change replication type.
Go to Top of Page

Giorgio
Starting Member

7 Posts

Posted - 2007-10-01 : 04:50:26
Thanks for trying to help but if you read my posting again you will see that I said that I have a transactional replication and I also said that I cannot apply join filters because only merge replication will allow that.
I cannot change the replication otherwise I would have done it already and I would not have posted here asking for help!!

quote:
Originally posted by rmiao

That's why need set filter on all related table without join. If you really need join filter, then have to change replication type.

Go to Top of Page

rmiao
Master Smack Fu Yak Hacker

7266 Posts

Posted - 2007-10-01 : 23:02:25
You can't do things that sql doesn't support, either go around it or forget it.
Go to Top of Page

Giorgio
Starting Member

7 Posts

Posted - 2007-10-02 : 04:33:56
rmiao, I always say to people that if you don't know then don't say that it is not possible!
I know that it is possible because transactional replication can be setup to allow DTS therefore if DTS can be done before the data is published then that means data can be filtered! I just don't know how to do it and that's why I am asking if someone knows how to do it...
Thanks for trying to help anyway...

Can someone tell me how to use DTS on Transactional replication to filter records horizontally by using joins?


quote:
Originally posted by rmiao

You can't do things that sql doesn't support, either go around it or forget it.

Go to Top of Page
   

- Advertisement -