日期:2014-05-17  浏览次数:20806 次

asp.net 网站测试 DBHelper.cs 提示我查询的列明无效
前台页面 visa.com ;程序页面  nation.aspx.cs ;.bll  Td_CountryManager.cs ;
.DAL    Td_CountryService.cs ;    DBHelper.cs  

程序    
1  前台页面 visa.com 
 <ul>
            <asp:Repeater ID="Repeatergjc" runat="server">
            <ItemTemplate>
            
            <li><p id="qqgj"><a href='nation_<%#Eval("CouEname") %>.html'><%#Eval("CouName") %></a></p><p id="qqprice">¥<%#Eval("CouPrice")%>起</p><div class="clear"></div></li>
          
           </ItemTemplate>
            </asp:Repeater>
        
        
       
        </ul>

2 后台程序nation.aspx.cs
 protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            string get = Request.QueryString["id"].ToString();
           
            string[] array = get.Split('_');
            string  id = array[1];
            // 你提交过来的是国家的拼音了,这个地方就不能把收到的编号设置为int格式了,否则肯定是会报错的
            cont = Td_CountryManager.GetTd_CountryByCouEname(id);
            //签证大区
            string sql = string.Format("select * from td_region where countryid={0}", id);
            Repeaterdq.DataSource = Td_RegionManager.SelectAllTd_RegionsBySql(sql);
            Repeaterdq.DataBind();
            //签证类型
            string qzzl = "";
            sql = string.Format("select visaname from td_visa where visaregionid in(select regionid from td_region where countryid={0})and visatype=1  group by visaname", id);
            DataTable table = DBHelper.GetTable(sql);
            foreach (DataRow row in table.Rows)