/// <summary>
        /// webform databae first
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>

        protected void Button1_Click(object sender, EventArgs e)
        {
            studentttEntities content = new studentttEntities();
            var query = from a in content.Set <studnet>().AsNoTracking()
                        join b in content.Set <city>().AsNoTracking() on a.cityid equals b.cityid
                        join c in content.Set <hobby>().AsNoTracking() on a.hobbyid equals c.hobbyid
                        where a.stuname == TextBox1.Text
                        select new
            {
                a.stuname,
                b.cityname,
                c.hobbyname
            };


            string sql = query.ToString();

            Label1.Text = sql;

            GridView1.DataSource = query.ToList();
            GridView1.DataBind();
        }
        protected void Button1_Click(object sender, EventArgs e)
        {
            studentttEntities content = new studentttEntities();
            ///linq 表达式 查询
            var students1 = from t in content.Set <studnet>().AsNoTracking()
                            where t.stuname == "hans"
                            select new { t.stuname, t.hobbyid, t.cityid };

            ///tolist 去 数据库 执行
            var query1 = students1.ToList();

            GridView1.DataSource = query1;
            GridView1.DataBind();

            ///lambda 表达式查询
            var students2 = content.studnet.Where(t => t.stuname == "hans")
                            .Select(t => new { t.stuname, t.hobbyid, t.cityid });

            var query2 = students2.ToList();

            GridView2.DataSource = query2;
            GridView2.DataBind();
        }