Quantcast
Channel: SQL Server Database Engine forum
Viewing all articles
Browse latest Browse all 12963

sql quiry

$
0
0

             query = "SELECT DISTINCT  number FROM  tableName  ";
    con.Open();
                    SqlDataAdapter da = new SqlDataAdapter(query, con);
                    DataSet ds = new DataSet();
                    da.Fill(ds);
                    if (ds.Tables[0].Rows.Count != 0)
                    {
                        CheckBoxList1.DataSource = ds;
                        CheckBoxList1.DataTextField = "number";
                        CheckBoxList1.DataValueField = "number";
                        CheckBoxList1.DataBind();
                    }

this is working fine but the problem is that .i want to show number name which is saved in another table  "table 2",

i am using this checkbox for only filtering

let me know plz is there any solution??


Sms


Viewing all articles
Browse latest Browse all 12963

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>