DataTable table = new DataTable(); table.Columns.Add("Id", typeof(int)); table.Columns.Add("Detail", typeof(string)); DataRow row = table.NewRow(); row["Id"] = 1; row["Detail"] = "Item 1"; table.Rows.Add(row); row = table.NewRow(); row["Id"] = 1; row["Detail"] = "Item 2"; table.Rows.Add(row); int count = table.AsEnumerable().Count(r => row.Field<int>("Id") == 1);In your case, something like this might work:
string product = "SomeProductID"; int count = table.AsEnumerable().Count(r => row.Field<string>("Product_Number") == product);But, like the other suggestions, it may be simpler/better to do this in the initial query.