Currently i am working and using a filter function for my search however i not sure how to do it using a query

the sql statement is

cmd.CommandText = select * from tblcustomer where customerName like "'& textbox1.text &'"

I no there is some bits missing but i am not sure what they are could you please help as the filter function is proving to be slightly in effective

i am usig vb and sql

We can probably give more help if you can be more specific as to the type of search. Lacking that, it looks as if you are on the right track. SQL uses "%" and "_" for wildcarding. A good explanation with examples can be found here.

iv gt this far with the code
just not sure how it ends

Dim con As New SqlConnection
        Dim cmd As New SqlCommand

        con.ConnectionString = ("")

        cmd.Connection = con

        cmd.CommandText = "select * from tblCustomer where customerName like @field1 "
        cmd = New System.Data.SqlClient.SqlCommand(cmd.CommandText, con)
        With cmd
            .Parameters.AddWithValue("@field1", Tsearch.Text)
        End With

This question has already been answered. Start a new discussion instead.