I'm new to C# and am having a problem with databases, specifically updating a table with dataset contents. No exceptions are being thrown, the update method tells me one row is affected but there is nothing in the table! Code below, your help is appreciated.

RSSDataSet.NewsItemRow newRow = rSSDataSet.NewsItem.NewNewsItemRow();
newRow.title = "a";
newRow.description = "a";
newRow.link = "a";
newRow.dateAcquired = DateTime.Now;
newRow.channelID = 1;

this.rSSDataSet.NewsItem.Rows.Add(newRow);                         
                
int result = this.newsItemTableAdapter.Update(this.rSSDataSet.NewsItem);
                
// Alternatively
newsItemTableAdapter.Insert("aa", "a", "a", DateTime.Now, 1);

You would like to insert some data to Database, from DataSet, am i correct?
Can i see the code which creates and populates the dataSet?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.