<asp:SqlDataSource ID="SqlDataSource1" runat="server"
ConnectionString="<%$ ConnectionStrings:ConnectionString %>"
SelectCommand="SELECT ProductName, ProductPrice FROM Product WHERE (@type LIKE '%' + @seach + '%')">
<SelectParameters>
<asp:QueryStringParameter Name="type" QueryStringField="type" />
<asp:QueryStringParameter Name="seach" QueryStringField="search" />
</SelectParameters>
</asp:SqlDataSource>
The problem is cannot get any return results which all because @type, if I change the @type to ProductName, its works fine, because I want the @type value become dynamic value that can choose by user, and I'll pass it by using queryString. How can I solve this kind of problem?