using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Data.OleDb;
using System.Text;
public partial class order : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        string OleDbcmd = @"SELECT book_info.book_name, order_book.num, order_book.price, order_info.orderTime, order_info.payMode, order_info.orderID
FROM book_info, order_info, order_book, user_info
WHERE book_info.book_ID=order_book.book_ID AND order_book.orderID=order_info.orderID And user_info.userID=order_info.userID And user_info.userName=@name";
        OleDbConnection conn = DB.connstr();
        OleDbDataAdapter sda = new OleDbDataAdapter(OleDbcmd, conn);
        OleDbParameter pt = new OleDbParameter("name", OleDbType.VarChar, 20);
        pt.Value = Session["user"].ToString();
        sda.SelectCommand.Parameters.Add(pt);
        DataSet ds=new DataSet();
        sda.Fill(ds);
        this.gvOd.DataSource = ds;
        this.gvOd.DataBind();
    
        
       
    }
}
