B
Bobby Edward
I have an xsd dataset. I created a simple query called GetDataByUserId. I
can preview the data fine!
I created a very simple BLL function that calls it and returns a datatable.
When I run the code I get....
=======================
Server Error in '/MyCompanyMyProject' Application.
Failed to enable constraints. One or more rows contain values violating
non-null, unique, or foreign-key constraints.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.
Exception Details: System.Data.ConstraintException: Failed to enable
constraints. One or more rows contain values violating non-null, unique, or
foreign-key constraints.
Source Error:
Line 2366: End If
Line 2367: Dim dataTable As dsUsers.myoptionsDataTable = New
dsUsers.myoptionsDataTable
Line 2368: Me.Adapter.Fill(dataTable) <==== LINE IS IN RED!
Line 2369: Return dataTable
Line 2370: End Function
Source File: c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET
Files\MyCompanyMyProject\7eeeedcd\743a3129\App_Code.zobkgcsa.15.vb Line:
2368
=======================
Any idea why?
I verified all the data, that no pk/fk are violated, etc... Even when I
turn 'enforce constraints' off in the xsd dataset properties it still fails.
can preview the data fine!
I created a very simple BLL function that calls it and returns a datatable.
When I run the code I get....
=======================
Server Error in '/MyCompanyMyProject' Application.
Failed to enable constraints. One or more rows contain values violating
non-null, unique, or foreign-key constraints.
Description: An unhandled exception occurred during the execution of the
current web request. Please review the stack trace for more information
about the error and where it originated in the code.
Exception Details: System.Data.ConstraintException: Failed to enable
constraints. One or more rows contain values violating non-null, unique, or
foreign-key constraints.
Source Error:
Line 2366: End If
Line 2367: Dim dataTable As dsUsers.myoptionsDataTable = New
dsUsers.myoptionsDataTable
Line 2368: Me.Adapter.Fill(dataTable) <==== LINE IS IN RED!
Line 2369: Return dataTable
Line 2370: End Function
Source File: c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET
Files\MyCompanyMyProject\7eeeedcd\743a3129\App_Code.zobkgcsa.15.vb Line:
2368
=======================
Any idea why?
I verified all the data, that no pk/fk are violated, etc... Even when I
turn 'enforce constraints' off in the xsd dataset properties it still fails.