This is a migrated thread and some comments may be shown as answers.

"SQL" Like Where Clause FROM RadFilter

1 Answer 138 Views
Filter
This is a migrated thread and some comments may be shown as answers.
Michael
Top achievements
Rank 1
Michael asked on 01 Mar 2012, 03:51 PM
I remember a few releases ago I was able to get an "SQL" where clause from the filter criteria. Has this functionality been moved? I see the save settings option but I don't think my users will understand base64. I would love to be able to use the filter do generate custom reports.

1 Answer, 1 is accepted

Sort by
0
Tsvetina
Telerik team
answered on 06 Mar 2012, 10:39 AM
Hi Michael,

The RadFilter control exposes query providers for a number of different syntaxes, including SQL. You can use the ApplyExpressions server event to get an expression built using the required syntax:
protected void RadFilter1_ApplyExpressions(object sender, RadFilterApplyExpressionsEventArgs e)
{
    RadFilterSqlQueryProvider provider = new RadFilterSqlQueryProvider();
    provider.ProcessGroup(e.ExpressionRoot);
    Response.Write(provider.Result);
}

For more information on building filter expressions you can check out this help article:
http://www.telerik.com/help/aspnet-ajax/filter-building-expressions.html

All the best,
Tsvetina
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
Filter
Asked by
Michael
Top achievements
Rank 1
Answers by
Tsvetina
Telerik team
Share this question
or