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

Filtering non mapped fields

1 Answer 29 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Miquel Frances Sitja
Top achievements
Rank 1
Miquel Frances Sitja asked on 21 May 2010, 10:25 AM
Hi there.

I added a new field to my entity not mapped to Database, when i displayed the field using RadGrid, i have no problem, i assigned the value and is displayed sucessfully, the problem is when i try to filter the value..., I'm created a combo box into the filter, but when the selectindex changed:

 

<telerik:RadScriptBlock ID="RadScriptBlock3" runat="server">

 

 

<script type="text/javascript">

 

 

function StatusIndexChanged(sender,args) {

 

 

var tableView=$find("<%# ((GridItem)Container).OwnerTableView.ClientID %>");

 

tableView.filter(

"NivelAdecuacion",args.get_item().get_value(),"EqualTo");

 

}

 

</script>

 

 

</telerik:RadScriptBlock>

 


An error is throw: The member XXX.NivelAdecuacion not admit SQL Conversion.

I supose that is due to the field is not mapped into Database table, is an added field, can anybody tell me how to solve this, please...

Thanks in advance

1 Answer, 1 is accepted

Sort by
0
Yavor
Telerik team
answered on 26 May 2010, 01:31 PM
Hello Miquel Frances Sitja,

In order to make sure that the filtering is handled properly, the data must reside in the original datasource, which is used to populate the grid with data. You can either add it to the original datasource, or add a separate column to the datatable passed to the grid in the NeedDataSource event handler.
I hope this information helps.

Kind regards,
Yavor
the Telerik team

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 Public Issue Tracking system and vote to affect the priority of the items.
Tags
Grid
Asked by
Miquel Frances Sitja
Top achievements
Rank 1
Answers by
Yavor
Telerik team
Share this question
or