Error creating Data Source

Hi,

I'm using SQL and C# Express Editions to create a standalone DB app. I have created a minimal DB with keys and indexes on 23 tables and can view the diagram in SQL SMSE. All is good (I think). However, when I try to create a new Data Source using the Data Source Creation Wizard in Visual C#, I receive this dialog:

"Failed to add relation(s). Unexpected error."

When I look (with designer) at the dataset that was created, I see only 6 of the approx 30 relations that existed in the original DB. All datatables are present but the relations were not created.

Am I correct in assuming the Visual C# diagram created for the app should be the same as in the DB Or do I manually use designer to add the missing relations

I found reference to "MissingSchemaAction.AddWithKey" which apparently will add the relations but the Data Source Creation Wizard seems to overwrite any change I make so no joy here.

Obviously I'm a newbie so will really appreciate any help...TIA.

Sturdy



Answer this question

Error creating Data Source

  • Shawnh

    Issue resolved...BLUSH...I said I am a newbie. Darned if I didn't have two DB with the same name. It's been a long day.

    Sturdy


  • Error creating Data Source