Check out the article "New DataSet Features in Visual Studio 2005" at
http://msdn.microsoft.com/vbasic/def...wdtastvs05.asp
Although a TableAdapter can have multiple Fill commands, there is only one
set of update commands that are executed when the TableAdapter's Update
method is called. These are generated automatically, based on the
TableAdapter's main query. The query that is defined when the TableAdapter is
first created is considered the main query for the TableAdapter. If any
subsequently defined queries return a schema that is different that the main
query's schema, the designer will warn you about it with a message box.
Alternatively, if you modify the schema of the main query, Visual Studio will
go and modify your other queries to match that schema.
"Mike" wrote:
Dear Group,
When I add a DataTable to a Typed Dataset, and a TableAdapter to the
DataTable, I am able to create methods to send updates directly to the
database (GenerateDBDirectMethods), however when my TableAdapter Fill SQL
contains a WHERE clause which looks up a field from another joined table,
the Fill works perfectly, but I cannot Insert, Update or Delete using the
TableAdapter.
Does anyone know why this is?
I don't want to return ALL the data and then filter the results, I need to
do this within the WHERE clause.
I'm binding the DataTable to a DataGridView.
Many thanks in advance!
Mike