Code:Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load If Not IsPostBack Then Dim CON As OdbcConnection Dim CMD As OdbcCommand Dim DTR As OdbcDataReader CON = New OdbcConnection("DSN=STOCK") CMD = New OdbcCommand("SELECT * FROM producten where pro_productnaam like 'c*'", CON) CON.Open() GridProducten.DataSource = CMD.ExecuteReader GridProducten.DataBind() CON.Close() End If End Sub
i want all products starting with "c" to be in my grid. I think i provided everything needed to execute this query... actually it does, but it doesn't return anything...and it should...
is it possible to use "like" in asp.net?
any idea what i could be doing wrong?


Reply With Quote