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

Can Filter control handle expressions what compare two fields?

3 Answers 16 Views
Filter
This is a migrated thread and some comments may be shown as answers.
Svyatoslav Isayev
Top achievements
Rank 1
Svyatoslav Isayev asked on 07 Jan 2016, 09:50 PM
The common scenario for filter expression is that Column is compared to a value, ex. TransactionId=12345. But can you create an expression that would allow user to specify comparison of 2 fields instead, e.g. TransactionId=CurrentTransactionId?

3 Answers, 1 is accepted

Sort by
0
Maria Ilieva
Telerik team
answered on 12 Jan 2016, 03:12 PM
Hi Svyatoslav,

I would suggest you to revise the help topic below that elaborates on this matter:
http://docs.telerik.com/devtools/aspnet-ajax/controls/grid/functionality/filtering/how-to/operate-with-the-filterexpression-manually

Regards,
Maria Ilieva
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Svyatoslav Isayev
Top achievements
Rank 1
answered on 12 Jan 2016, 08:30 PM

Dear Maria,

 

The link that you suggested does not address the situation I'm talking about. I'll try to explain in more detail...

 

Let's say I have an entity represented by a table TestTable:

-----------------------------------------------------------------------------------------

|  TransactionId  |  AgreementId  |  CurrentTransactionId  |  Value  |

-----------------------------------------------------------------------------------------

|              15431  |            12        |                         15433   |        22 |

|              15432  |            12        |                         15432   |        22 |

|              15433  |            12        |                         15431   |        22 |

 

I want to allow user to build a filter that would correspond to the WHERE clause of the following SQL expression :

 

SELECT *

FROM TestTable

WHERE TestTable.TransactionId=TestTable.CurrentTransactionId

 

Is this something that can be done with Telerik's Filter control?

0
Maria Ilieva
Telerik team
answered on 18 Jan 2016, 07:25 AM
Hello,

Unfortunately the required functionality can not be achieved with the RadFilter control.
The suggested help topic demonstrates the filter expressions supported by Telerik syntax and you can apply the required SQL syntax per your need.

Regards,
Maria Ilieva
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
Filter
Asked by
Svyatoslav Isayev
Top achievements
Rank 1
Answers by
Maria Ilieva
Telerik team
Svyatoslav Isayev
Top achievements
Rank 1
Share this question
or