on 02-04-2012 12:01 PM
Hello Experts,
I have 2 tables - Countries(with a single column - Country) and Cities(with a single column - City).
I have a DataService which is returning all Countires with all Cities as country-city pairs.
What I want to archive is when a selection made in Countries table (also multiple selection possible), than Cities table is filtered just to the cities belonging to countries selected.
How do I do that in VC without hitting DataService every time country is selected (as all data is already available during a single call)? Maybe first store data to DataShare element and than somehow trigger filtering based on the country selection, but than how do I pass countries selected to a filter?
Thanks for your answers!
Best Regards,
Artsiom Anichenka
I have found solution myself. If anyone interested, here I have descibed solution in this post:
http://forums.sdn.sap.com/email!default.jspa?messageID=11061570
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Roberto,
here is the description from the link in my previous post:
on design board I have:
- Table with with userIDs (DataStore is connected to this table via select event, so currently selected user is always stored)
- DataShare with all the user-role pairs
- out port of DataShare is connected to a Filter (where the filtering is done based on UserID stored in DataStore, described above)
- out port of the Filter is connected to Table where the roles of the selected user need to be displayed
What I need is when the user is selected in the first table, it's roles should be displayed in second table. I can achieve it with adding a button to first table with custom action and than specifing this action on the connection between DataShare and Filter.
just replace user-roles with countries-cities.
The main trick here is that the Filter is executing with a custom action which is fired with a button click.
Please let me know if it now clear to you.
Hello Artsiom,
thank you for the details. One question: do you know if is it possible to specify a formula into the filter operator?
I mean: from the output of the data service I defined a filter before to show all the rows in a table. And I'd like to filter all the data through a variable called "Channel". To filter these data I'd like to have a filter with the following formula IF(STORE@Channel=='B2B', B2B, B2C).
Usually in a filter there are predefined conditions like Equal "Text" or Starts with "Text" but I'm not able to specify a complex formula. Do you know if is it possible?
Regards, Roberto
User | Count |
---|---|
84 | |
25 | |
12 | |
9 | |
6 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.