SqlCommand cmd = new SqlCommand("SELECT name,image1,Min(cost),MAX(cost) FROM sell,cpu WHERE cpu.name=sell.brand", con); SqlDataAdapter da = new SqlDataAdapter(cmd); DataTable dt = new DataTable(); da.Fill(dt); GridView1.DataSource = dt; GridView1.DataBind();
SqlCommand cmd = new SqlCommand("SELECT cpu.name,image1,Min(cost),MAX(cost) FROM sell,cpu WHERE cpu.name=sell.brand group by(cpu.name)", con);
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)