D
Deecrypt
My issue is that I am communicating data between a website and a
webservice using datasets. The datasets created by filling the
datasets with results of queries using the DataAdapter. My problem is
that for some reason, the fill method seems to miss out on exactly one
row from the database even though that row still conforms to the query
criteria. Regardless of how many rows are selected as a result of the
query, only the last row logically present in the table is not copied
into the dataset. Below is my code. May be there is something I am
overlooking.
//Assign the type and destination of the database being queried
string source = "Provider = Microsoft.JET.OLEDB.4.0;data source
= C:\\leedsuni\\mscproject\\seconddemo\\snomedepr.mdb;";
//Initialise string representing the query to search the
database
string query = "SELECT * FROM abdominalpainassessmentrecords
WHERE assessment_id = " + assessmentIDTextBox.Text + "";
//This dataset represents what has just been edited and saved
in the aap database
OleDbDataAdapter aapDataAdapter = new OleDbDataAdapter(query,
source);
DataSet aapDataSet = new DataSet();
aapDataAdapter.Fill(aapDataSet,
"abdominalpainassessmentrecords");
I'm just wondering what would make the adapter miss one row that still
conforms to the query criteria. It just seems like a bug to me.
Thank you kindly
Khurram
webservice using datasets. The datasets created by filling the
datasets with results of queries using the DataAdapter. My problem is
that for some reason, the fill method seems to miss out on exactly one
row from the database even though that row still conforms to the query
criteria. Regardless of how many rows are selected as a result of the
query, only the last row logically present in the table is not copied
into the dataset. Below is my code. May be there is something I am
overlooking.
//Assign the type and destination of the database being queried
string source = "Provider = Microsoft.JET.OLEDB.4.0;data source
= C:\\leedsuni\\mscproject\\seconddemo\\snomedepr.mdb;";
//Initialise string representing the query to search the
database
string query = "SELECT * FROM abdominalpainassessmentrecords
WHERE assessment_id = " + assessmentIDTextBox.Text + "";
//This dataset represents what has just been edited and saved
in the aap database
OleDbDataAdapter aapDataAdapter = new OleDbDataAdapter(query,
source);
DataSet aapDataSet = new DataSet();
aapDataAdapter.Fill(aapDataSet,
"abdominalpainassessmentrecords");
I'm just wondering what would make the adapter miss one row that still
conforms to the query criteria. It just seems like a bug to me.
Thank you kindly
Khurram