<target>.PrimaryKey Merge Error

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Running a VB.Net console application that uses data from a VB.Net webservice.
Both the data sent and received are accessed with strongly-typed datasets.

With dsMapping
ds = WS.WorkOrdersForReprint(StoreId)
.EnforceConstraints = False
.Merge(ds)
End With

The above generates this error message at the Merge statement:

"<target>.PrimaryKey and <source>.PrimaryKey have different Length."

The key length is 1 (one column) and type is integer for both ds and
dsMapping.

This works except for one table. Any ideas as to what is wrong and how to
correct?

Thanks.
 
Are you sure that they don't differ fot that table?
And why do you use Lenght on int?
 
Both target and source keys are the same length and data type.

I don't use the length -- that was an observation.
 
Back
Top