I have a dataset that I first do a FillSchema(dataset, SchemaType.Mapped, "Table") on, and yet it still throws System.Data.MissingPrimaryKeyException when I do a dataset.tables("Table").Rows.Find(key).

The column is marked as a primary key in the table and the sql statement is just "SELECT * FROM tableName"

Anybody have any idea why this can happen?

P.S. Sorry if I didn't give enough info, but I am patching together someone else's mess, so I haven't gotten a chance to read it all yet.

-Thanks

Re: Can't find primary key by William

William
Sat Jul 24 09:55:50 CDT 2004

When you say 'the table', do that mean on the DB Side, or is that a PK
Defined client side on the Datatable?

--
W.G. Ryan MVP Windows - Embedded

Have an opinion on the effectiveness of Microsoft Embedded newsgroups?
Let Microsoft know!
https://www.windowsembeddedeval.com/community/newsgroups
"Devin" <Devin@discussions.microsoft.com> wrote in message
news:9BAAD646-14FC-4325-A4A3-98B6F2C31DF7@microsoft.com...
> I have a dataset that I first do a FillSchema(dataset, SchemaType.Mapped,
"Table") on, and yet it still throws System.Data.MissingPrimaryKeyException
when I do a dataset.tables("Table").Rows.Find(key).
>
> The column is marked as a primary key in the table and the sql statement
is just "SELECT * FROM tableName"
>
> Anybody have any idea why this can happen?
>
> P.S. Sorry if I didn't give enough info, but I am patching together
someone else's mess, so I haven't gotten a chance to read it all yet.
>
> -Thanks