Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
DB Engine
SQL ServerMSDESQL Server CE
Services
Analysis (Data Mining)Analysis (OLAP)DTSIntegration ServicesNotification ServicesReporting Services
Programming
CLRConnectivitySQLXML
Other Technologies
ClusteringEnglish QueryFull-Text SearchReplicationService Broker
General
Data WarehousingPerformanceSecuritySetupSQL Server ToolsOther SQL Server Topics
DirectoryUser Groups
Related Topics
MS AccessOther DB ProductsMS Server Products.NET DevelopmentVB DevelopmentJava DevelopmentMore Topics ...

SQL Server Forum / Other Technologies / Replication / December 2006

Tip: Looking for answers? Try searching our database.

S2K to SQL Everywhere - Dynamic Filters

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Ming Yeung - 20 Dec 2006 00:45 GMT
Things I got to work
SQL2K, Merge Publication -> SQL Everywhere (I used the interface in SQL2K5
to do this Subscribe,  can anyone show me how to do it in C# 2005 code???)

SQL2k Merge Publication with Dynamic filters(i.e SUSER_SNAME) -> To Another
instance of SQL2k

What I would like to know is how to I get dynamic filters/dynamic snapshots
on rows to work with SQL Everywhere and is this even supported?

Also can I do this programmatically?
Glenn Gailey [MS] - 26 Dec 2006 03:03 GMT
Here is the C# code to create a SQL Server Compact Edition (formerly known as
SQL Server Everywhere and SQL Server Mobile) programmatically with hostname
filtering:

       SqlCeReplication repl;

       try
       {
           // Instantiate and configure SqlCeReplication object.
           //
           repl = new SqlCeReplication();
           repl.InternetUrl = "http://www.websyncurl.com/sqlcesa30.dll";
           repl.InternetLogin = internetLogin;
           repl.InternetPassword = internetPassword;
           repl.Publisher = publisher;
           repl.PublisherSecurityMode = SecurityType.NTAuthentication;
           repl.PublisherDatabase = publisherDatabase;
           repl.Publication = publication;
           repl.Subscriber = subscriber;
           repl.SubscriberConnectionString = "Data Source=MyDatabase.sdf";
           repl.HostName = hostname;

           // Create a local SQL Server Compact database and subscription.
           //
           repl.AddSubscription(AddOption.CreateDatabase);

           // Initialize the subscription.
           //
           repl.Synchronize();
       }
       catch (SqlCeException)
       {
           // Handle errors here
           //
       }

For more info, see these topics :

http://msdn2.microsoft.com/en-us/library/ms171908.aspx
http://msdn2.microsoft.com/en-us/library/ms365205.aspx

Signature

Glenn Gailey [MS]

SQL Server User Education

This posting is provided "AS IS" with no warranties, and confers no rights.

> Things I got to work
> SQL2K, Merge Publication -> SQL Everywhere (I used the interface in SQL2K5
[quoted text clipped - 7 lines]
>
> Also can I do this programmatically?
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.