Hi,

I've been trying sync with SQL Server CE with no success. The next lines are
a guide about the description of the problem:

- The AddSubscription works ok. No exceptions, and the MYSQLCE.SDF file is
well created. So, I suposse the connection parameters are ok. You can see
the code below (elimitated the exception handling).

- When executing this code as a response to a button click, the PDA stands
"in limbo" in the replNw.Synchronize() line. It's necessary to reset the
device to restore it.

- I can access the url thru the iexplore in the PDA without problems getting
the "SQL Server CE Server Agent" message.

- I followed all the steps to create and publish a database in SQL Server
2000. The snapshot is created, and the publication has been tested with
normal (non SQL Server CE) subscribers. IIS and SQL Server 2000 are in the
same machine. ActiveSync and the physical connection to the PDA are in other
machine.

How could I trace the problem?.

...

SqlCeReplication replNW = new SqlCeReplication();

replNW.ExchangeType = ExchangeType.BiDirectional;

replNW.InternetUrl = "http://XXX.XXX.XXX.XXX/sscesa20.dll";

replNW.InternetLogin = "";

replNW.InternetPassword = "";

replNW.Distributor = "MYSERVER";

replNW.DistributorLogin = "sa";

replNW.DistributorPassword = "";

replNW.Publisher = "MYSERVER";

replNW.PublisherDatabase = "MYSQLCE";

replNW.Publication = "PubMYSQLCE";

replNW.PublisherSecurityMode = SecurityType.DBAuthentication;

replNW.PublisherLogin = "sa";

replNW.PublisherPassword = "";

replNW.Subscriber = "SubMYSQLCE";

replNW.SubscriberConnectionString = "Data Source="+@"Storage
Card\MYSQLCE.sdf";


//replNW.AddSubscription(AddOption.CreateDatabase);

replNW.Synchronize();

replNW.Dispose();

...

Thanks in advance,

Augusto.

Re: No synchronization in SQL Server CE by M

M
Wed Apr 21 04:32:37 CDT 2004

Augusto,

I've been messing around with Replication a while back, and my problem was
that it needed a GUID field in the DB table and i had to set the indexes in
a correct manner.

Perhaps that could also be your problem, you are having the same problem
that i encountered a while back.

you might check it out.

Greetz,
Marc


"Augusto Afonso" <aafonso@ids-sa.es> schreef in bericht
news:uy58rShJEHA.4052@TK2MSFTNGP11.phx.gbl...
> Hi,
>
> I've been trying sync with SQL Server CE with no success. The next lines
are
> a guide about the description of the problem:
>
> - The AddSubscription works ok. No exceptions, and the MYSQLCE.SDF file is
> well created. So, I suposse the connection parameters are ok. You can see
> the code below (elimitated the exception handling).
>
> - When executing this code as a response to a button click, the PDA stands
> "in limbo" in the replNw.Synchronize() line. It's necessary to reset the
> device to restore it.
>
> - I can access the url thru the iexplore in the PDA without problems
getting
> the "SQL Server CE Server Agent" message.
>
> - I followed all the steps to create and publish a database in SQL Server
> 2000. The snapshot is created, and the publication has been tested with
> normal (non SQL Server CE) subscribers. IIS and SQL Server 2000 are in the
> same machine. ActiveSync and the physical connection to the PDA are in
other
> machine.
>
> How could I trace the problem?.
>
> ...
>
> SqlCeReplication replNW = new SqlCeReplication();
>
> replNW.ExchangeType = ExchangeType.BiDirectional;
>
> replNW.InternetUrl = "http://XXX.XXX.XXX.XXX/sscesa20.dll";
>
> replNW.InternetLogin = "";
>
> replNW.InternetPassword = "";
>
> replNW.Distributor = "MYSERVER";
>
> replNW.DistributorLogin = "sa";
>
> replNW.DistributorPassword = "";
>
> replNW.Publisher = "MYSERVER";
>
> replNW.PublisherDatabase = "MYSQLCE";
>
> replNW.Publication = "PubMYSQLCE";
>
> replNW.PublisherSecurityMode = SecurityType.DBAuthentication;
>
> replNW.PublisherLogin = "sa";
>
> replNW.PublisherPassword = "";
>
> replNW.Subscriber = "SubMYSQLCE";
>
> replNW.SubscriberConnectionString = "Data Source="+@"Storage
> Card\MYSQLCE.sdf";
>
>
> //replNW.AddSubscription(AddOption.CreateDatabase);
>
> replNW.Synchronize();
>
> replNW.Dispose();
>
> ...
>
> Thanks in advance,
>
> Augusto.
>
>
>
>