Solved

cannot insert rows into Pulled table (RDA)

Posted on 2011-03-09
2
369 Views
Last Modified: 2013-12-27
hello,

I've setup a RDA (Remote Data Access) connection between a PocketPC(Windows CE 5.0) and a SQL Server 2008 Express. Everything works fine (the Pull and the Push), but I can't insert rows into the tables in the SQL Mobile 3.5 database. Pulled tables have Identity rows and Primary keys on the Identity row. I can update and delete rows, but when I try to insert, it give the following error: "A duplicate value cannot be inserted into a unique index. [Table name, Constraint name]"

Insert statement is: "INSERT INTO TB_prdModel(modDesc, catID) values ('test', 1)"

Table TB_prdModel have 3 rows: modID (PK, Identity), modDesc (nvarchar(100)), catID (int).

Anyone have an idea how to fix this please? thanks for your time and help

0
Comment
Question by:Dominic34
  • 2
2 Comments
 

Author Comment

by:Dominic34
ID: 35087200
seems the Identity value of the column is reset to 1 after the Pull. So, either I reset the Identity to the MAX value of all the tables or I change all my tables from INT Identity to GUID. What should I do?

GUID take a LOT more memory than INT and is a pain to work with (not really user-friendly). But INT Identity could cause problem when synchronizing with multiple clients.

What is the best way to sync tables using RDA ??
thanks
0
 

Accepted Solution

by:
Dominic34 earned 0 total points
ID: 35095976
Ok, I converted all INT Identity to GUID, now it works fine. thanks to myself for the answer.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

In this article we will discuss all things related to StageFright bug, the most vulnerable bug of android devices.
You should read OS supplied guidelines before developing. I can't stress that enough. The guidelines will help you understand the reasons mobile app developers do what they do.  Apple is very particular when they review appstore submissions.

820 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question