in

CodeSmith Community

Your Code. Your Way. Faster!

Patch: FilterType Enhancement

Last post 05-02-2008 9:47 AM by CitizenBane. 0 replies.
Page 1 of 1 (1 items)
Sort Posts: Previous Next
  • 05-02-2008 9:47 AM

    • CitizenBane
    • Top 50 Contributor
    • Joined on 10-30-2007
    • Grand Rapids, MI
    • Posts 81
    • Points 1,285

    Patch: FilterType Enhancement

    I've created a patch that adds an SqlFilterType to our strongly typed filter based on the discussion here:
    http://community.codesmithtools.com/forums/p/5677/30760.aspx

    Basically, you will be able to filter your where clause by using each individual word or a phrase of words.

    By default, it will use SqlFilterType.Word, the same functionality that was used before the changes to prevent bugs in legacy code.

    Example usage:

    <data:AirportCodeDataSource ID="AirportCodeDataSource1" runat="server" SelectMethod="GetPaged" EnablePaging="true" EnableSorting="true">
        <Parameters>
            <data:SqlParameter Name="WhereClause" UseParameterizedFilters="false">
                <Filters>
                    <data:AirportCodeFilter Column="CountryCode" ControlID="ddlCountryList" />
                    <data:AirportCodeFilter Column="City" ControlID="txtSearch" ComparisionType="Contains" FilterType="Phrase"  />
                </Filters>
            </data:SqlParameter>
        </Parameters>
    </data:AirportCodeDataSource>

    Cheers,
    CB

    Edit: I'm still not sure whether or not "FilterType" should be the right word here... anyone have suggestions?

     

    I'm outside ur box, shiftin' ur paradigm.
    • Post Points: 5
Page 1 of 1 (1 items)
Copyright © 2007 CodeSmith Tools, LLC
Powered by Community Server (Commercial Edition), by Telligent Systems