In my program, i implemented a simple database search that takes in a string (name or part of the name) and returns the corresponding details:
string nameSearch = textBox1.Text;
DataRow[] resultRows;
resultRows = ds1.Tables["Lecturers"].Select("Name='" + nameSearch + "'");
But i’m not getting the expected results unless i type in the ENTIRE NAME correctly. How can i modify the ‘Select()’ to get results when i input only a part of the name?
A quick check of DataTable.Select on MSDN leads you to DataColumn.Expression…