2 dropdownboxs, filtering second off the the value in first

Hello,
This seem logically simple to me, I had 1 dropdownbox that filters the results of the other dropdownbox
Was using the model filter but was unable to get it working with how I have my dropdownboxs setup, then I tried using a formatter but again wasn't able to get it working.
I created a separate version of my dropdownboxs using binditems and was able to kind of filter the second box, instead of how I have them done below but had issues with the keys being saved to the model.
Anyone have any idea currently how to get it work with how I have it setup?
        var oDropdownBox1 = new sap.ui.commons.DropdownBox({
            selectedKey: "{division}",
            items: {
                path: "/divisions",
                template: new sap.ui.core.ListItem({
                    text: "{divisiondesc}",
                    key: "{division}"
        var oDropdownBox2 = new sap.ui.commons.DropdownBox({
            selectedKey: "{bus_unit}",
            items: {
                path: "/bunits",
                template: new sap.ui.core.ListItem({
                    text: "{busunitdesc}",
                    key: "{busunit}"
        oTable.addColumn(new sap.ui.table.Column({
            label: new sap.ui.commons.Label({
                text: "Divs",
                required: true
            template: oDropdownBox1,
            width: "150px",
            hAlign: "Center"
        oTable.addColumn(new sap.ui.table.Column({
            label: new sap.ui.commons.Label({
                text: "Bus"
            template: oDropdownBox2,
            width: "150px",
            hAlign: "Center"
oTable.bindRows("/entries");
The table is bound to the entries node, and in the entries node is division and bus_unit for the actual value displayed in the table and saved for the entry.
Then the list items of the 2 columns are bound to their correct nodes, i.e. "/division" and "/bunits". To filter the listitems of bunits I use"division" . Both "divisions" and "bunits" have division on them, so it should quite simple to filter the second box :/.
This is quite simple logically but can't seem to get it to act how I want!
Any help would be appreciated. Thanks!

To be honest, I would have expected it to work in the following way:
            var oTable = new sap.ui.table.Table()
                .addColumn(new sap.ui.table.Column({
                    label: new sap.ui.commons.Label({
                        text: "Division"
                    template: new sap.ui.commons.DropdownBox({
                        selectedKey: "{tablemodel>division}",
                        items: {
                            path: "metadatamodel>/divisions",
                            template: new sap.ui.core.ListItem({
                                text: "{metadatamodel>divisiondesc}",
                                key: "{metadatamodel>division}"
                .addColumn(new sap.ui.table.Column({
                    label: new sap.ui.commons.Label({
                        text: "Business Unit"
                    template: new sap.ui.commons.DropdownBox({
                        selectedKey: "{tablemodel>bus_unit}",
                        items: {
                            path: "metadatamodel>/bunits",
                            template: new sap.ui.core.ListItem({
                                text: "{metadatamodel>busunitdesc}",
                                key: "{metadatamodel>busunit}"
                            filters: [new sap.ui.model.Filter("division", sap.ui.model.FilterOperator.EQ, "{tablemodel>division}")]
                .bindRows("tablemodel>/");
(See also the full example on JSBin)
As you can see, I have two models, one for the table data ("tablemodel"), and one specifically for the dropdown items ("metadatamodel")
In the second dropdown, you see I have set a filter on field 'division' which is being filtered on the current 'tablemodel>division' value, but for some reason I couldn't get it to filter properly... it appears as if the value binding in the filter is not "ready" and thus filters on a non-existing value.
If you replace the filter value "{tablemodel>division}" with "div1" for example, then the filter obviously works, but then it's not dynamic anymore... So yeah, I am now curious to see it working too
BTW, if it were outside a table then it wouldn't be a problem; the problem is definitely with the dynamic filter binding with dynamic table data

Similar Messages

  • Regarding round off the value in adf table

    HI All,
    My Requirement:
    i have to round off the value after decimal in adf column before saving to data base.
    Excample : 1234.67 = 1235
    34567.89=34568
    34567.34= 34567
    i am using jdeveloper 11.1.1.3.0
    Please can you give code using converter or any other strategy.
    Thanks & Regards,
    Madhu

    1. First of all you asked for rounding off, taking the integer part is not rounding off.
    2. As per the documentation
    integerOnly      boolean      Yes      Flag specifying whether only the integer part of the value will be formatted and parsed. Default value is false.if i can understand correctly pertains to formatting only.
    3. You can create a custom faces converter and add it to faces config.xml http://docs.oracle.com/javaee/1.4/tutorial/doc/JSFDevelop4.html . So that you do not have to write it in code.
    4. If only integer is to be allowed why don't you change the data type to long or int instead of number

  • Sub totals based off the value of a dimension

    Hi,
    I have a requirement to apply sub totals to a dimension at certain levels of a hierarchy.
    From what we've implemented, the typical Level-Based Hierarchy has been replaced by a Flat Hierarchy, so instead of accounts appearing at different levels and in different columns (I.E Level 31, Level 30, Level 29 ... ), they appear in 1 single column. A seperate column called Node Depth determines the level at which these accounts sit.
    Essentially, I just want to show sub totals for values 2 and 3 in the Node Depth column.
    Is there a way to do this in OBIEE? I've only been able to get ALL subtotals to appear.
    Thanks

    Hi Chris,
    You can either use the FILTER...USING... function in answers or you can create distinct, filtered LTSs in the RPD which will then represent your node depth. I.e. you'd have, in your example, 8 LTSs with differing fragmentation content of "Node Depth" = 1 ... = 8

  • Filtering based on the value in a Input Box?

    Is it possible to filter a gallery based on something I enter into an input box?
    If so what is the syntax for the command I need?
    Right now I am trying Filter(UF_Football_Roster, Number =) and then I have no idea what to put after the equals sign.
    Thanks for the help!

    Hi Philip,
    Yes. Assuming Number is a column in the table_UF_Football_Roster, and assuming you added an input text visual named InputText1, here is the syntax:
    Filter(UF_Football_Roster, Number = InputText1!Text)
    If the value in the Number column are stored as numbers you may need to use the function
    Value:
    Filter(UF_Football_Roster, Number = Value(InputText1!Text))

  • How to fix the value of first column in the JTable in java swing for every

    Hi ,
    I have a swing page that have table panel in which there is a table of size 7x4 now when I click on the perticulat row then that row data will displayin the table like that the selected row become the second column in the new table and the fist column of this table will remain constant for all the entry but the second column update according to the roe which is selected .How it is possible .
    Thanks in Advace,
    anu

    One thing you can do is to prevent the user from editing that column and programatically supply the values of that column yourself.
    JTable table = new JTable() {
       public boolean isCellEditable(int row, int col) {
           if(col == 0) {
              return false;
           return super.isCellEditable(row, col);
    };This allows you to prevent the user from editing the column information so you can supply some sort of a default value for the column always
    ICE

  • Why I cannot turn off the iPad at first attempt?

    I got my iPad few weeks back (32GB + 3G).
    The only strange thing I encounter so far is may be 4 out of 5 times, when I tried to turn off the iPad, it will jump back to the lock screen again.
    On the second attempt then I can turn off the iPad.
    What could be the problem? should I send in for a replacement?

    HI and welcome to Apple Discussions...
    Perhaps you have an app running. Try force quitting.
    Press and hold the Sleep/Wake button and the Home button at the same time for at least ten seconds, until you see the Apple logo.
    If that doesn't make a difference, reset your iPad. Press and hold the Sleep/Wake button and the Home button at the same time for at least ten seconds until you see the Apple logo.
    Make sure your iPad software is up to date. Connect the iPad to your computer. Launch iTunes if it doesn't open automatically. Under the Summary tab click: Check for Update
    Carolyn

  • VISA Read Losing Characters off the end of the output string

    Hi,
    So I am writing a VI to take an output string of data from an ardunio Uno and parsing it. I am using the Read Visa vi to grab the string from output of the device. In the end I will be connecting a device that actually gives value in this type of string  format : (#80212164,2289,2292,2296,2300,2328,2289,2297,2290,2300,2308,2292,2295,2298,2289,22,24,0*).
    So after a large number of loops, the program starts to drop the last few characters of the string that it outputs. So the string output from Visa Read will read something like (#80212164,2289,2292,2296,2300,2328,2289,2297,2290,2300,2308,2292,2295,2298,2289,22,24,). The only way to fix this problem after it has occured is to completely close labview (all the way). Once I open it again and start running the program, all is fine in the world.
    Anyone ever have this issue? I have been trying to debug this in different ways and the only weird symptom that I have other than the Visa Read function losing a few characters of the string is the fact that looking at the Bytes at Port after I Visa Read, is that it starts showing five bytes instead of zero. 
    attached is my most recent attempt at solving this issue. 
    Note:  The Ardunio outputs a string of this format every 2 seconds with the values being incrimental over a specified range.(#80212164,2289,2292,2296,2300,2328,2289,2297,2290,2300,2308,2292,2295,2298,2289,22,24,0*) 
    Solved!
    Go to Solution.
    Attachments:
    Ardunio(StringOutput).vi ‏36 KB

    So i did a long data collect and It looks like ever 43minutes and 24 seconds the system goes from cutting off the last 5 characters to not cutting off the last 4 characters.
    As I cant see how Labview would be causing that, I am going to try and dig into the Ardunio and solve that issue... hopefully when thats done I can simplfy my code like you guys pointed out.
    Thanks!
    Attachments:
    overnight_11_18.csv ‏3001 KB
    Overnight.png ‏146 KB

  • Formatting amount to 2 decimal places without rounding the value

    Hi 
    My requirement is to format the amount field, when I am using the simple type and setting the format as ###,##0.00 then it is rounding off the value.  Foe example say the amount is 3,567.236 in this case it rounds it off to 3,567.24 which I do not want we want the value to display as 3,567.23.  Does anyone have any idea how this can be achieved.
    Thank you
    Regards,
    Preet

    Use the following :
    BigDecimal bigDecimalh = new  BigDecimal("22.335642");
              bigDecimalh = bigDecimalh.setScale(2, BigDecimal.ROUND_DOWN);
    Regards,
    Himanshu

  • InDesign becomes unresponsive when editing text off the network. Techs are flummoxed!

    Recently my InDesign (CS6 running on Windows 7 Pro 64 bit, 8gb ram) has become almost totally unresponsive when I go to open and edit a file off the company network. Our techs have no idea what is going on and are considering having to re-build my profile as a last resort as we have tried everything else.
    A bit more of a descriptoin of the problem: When I go to edit an InDesign file off the server it first takes longer than normal to load but eventually does. You can scroll up and down the pages, move and resize boxes, place new pictures but as soon as you try to do anything text based (edit new text or make a new text box) the whole program freezes to the point you have to task manager out and kill it. It is not a corupt file because if I copy the file directory with all links over on to my computers local hard disk the file works totally fine it is only when editing over the network and when edouble clicking to edit text.
    What we have done to try and fix the problem:
    Reinstal InDesign - No effect
    Cleared the preferences (shift + ctrl + alt + windows key on InDesign startup) - No effect
    Our techs have tried editing my profile registry to no avail and we are all compleatly at a loss to what is going on. There are several other instances of the program across the company (mainly versions 5.5 and one other 6) and they all work fine editing files straight off the network.
    Anyone have any idea what it could be, such a specific problem being only when it is editing text based areas? The techs dont want to have to re-build my profile as it is a lot of back end work to do to be able to re-instate it straight away.
    Many thanks in advance for any insights into the issue

    So we have finally fixed the issue and are currently cracking out the bubbly!
    It turned out to be the network path shotcut I was using to access the shared drive where I was editing the files from. I work for a restaurant so we have a shared drive where each site can access their files, this is where the food menu files reside and I had created a shortcut that, although accessed the correct area did it using a path which had a double backslash in it.
    The true path for the shared drive is  \\hm\mydocs\restaurant\menufile.indd and this is the shortcut I was using to open the file up from. For all other files like Word, Excel, even other Adobe programs like PSE10, and Lightroom it seems to work fine. For some reason InDesign does not like this path with the double backslash in. As soon as I changed the shortcut path to just m:\ (the letter of the shared drive on the network) everything was working again and we can all sleep, it was driving us mental. Re-installed windows, InDesign created a new network user profile the works.
    I hope this may help someone else in a similar situation in the future

  • Write Off Quantity and value

    hi,
    How do I write off the value and quantity for the stocks?
    For stock materials we do the physical inventory - entering count adjust qty and posting adjust vale . But how can I adjust for value only articles?

    Hi,
    That will be easy for you to post MI10 document .This will write of the quantity and value of that quantity.
    If you want to change the standard price of the material post a MR21 document.
    Regards,

  • I need to cut 5 seconds off a movie I made!!!

    Please someone help me.. I admit not very smart when it comes to pc's.. I made a movie with my camera and downloaded it into my computer.. I need to cut the last 5 seconds off the movie.. God bless and please help!!!

    Hi, Please try:    http://www.avs4you.com/AVS-Video-Editor.aspx?gclid=CPaEgcCFj8cCFQRvvAod598HJg   http://www.iskysoft.us/lp/video-editor-win/?gclid=COngit2Fj8cCFYGWvQod5ZwLFA I tested the first one few years back (older version). I don't what more/less it has now. Good luck.

  • How to upgrade the second dropdownbox when selecting the values of the first ?

    Hello everyone, I am new to programming. Tell me, please, how to automatically load the new values in the second dropdownbox, depending on the choice of the values in the first dropdownbox ?

    There is an example here...
    http://www.scriptsrus.talktalk.net/Run%20Action.htm

  • I want to get the values from the second hiphen only

    Hey Guys,
    I have one column and the data like this
    col1 = 'AI463-901-001'
    Now,
    I want to get the values from the second hiphen only(any no. of values).
    Please can any one help me on this .
    Thanks in advance!
    Regards,
    -LK

    you have a mistake
    you result is -001
    this is right
      select substr('AI463-901-001',instr('AI463-901-001','-',1,2)+1) from dual;
      -- @user11928732 -  if you are using Oracle Database 11g, ttry this please
    with data as
      (select  'AI463-901-001'from dual)
      select substr(str,instr(str,'-',1,2)+1) from data;
      select substr(<YOUR COLUMN>,instr(<YOUR COLUMN>,'-',1,2)+1) from <YOUR TABLE>;result is : 001
    Edited by: Mahir M. Quluzade on May 3, 2011 5:37 PM

  • When using my ipad air it keeps coming off the page I'm on or app and going back to the home screen. Also when using my ipad the screen will go white with a black apple icon in the middle for about 20 seconds then it makes a ping

    When using my ipad air it keeps coming off the page I'm on or app I am using and going back to the home screen. Also when using my ipad the screen will go white with a black apple icon in the middle for about 20 seconds then it makes a ping sound and goes to the home screen. Could anyone help please. Thank you :-)

    Read here:
    http://help.apple.com/ipad/8/#/iPad9a245e3e

  • Filters 'OR' function not passing the values to the sql

    Hi,
    I am facing an issue with the 'OR' function on the filters that are used in the reports.
    The report needs to fetch all the records on the three tables as the user enters the value in the dashboard prompts.
    eg: [   update_dt_A1 is prompted
    and user_name_A1 is prompted ]
    or
    [    update_dt_B1 is prompted
    and user_name_B1 is prompted ]
    or
    [    update_dt_C1 is prompted
    and user_name_C1 is prompted ]
    The values entered in the dashboard prompt gets passed to the filter, but the vaules are not passed over to the SQL that runs on the database, hence the reports shows all values and does not reflect the values entered.
    When the 'OR' function is replaced with 'AND' the values get passed to the SQL.
    Can anyone help on what is the issue on the filters?
    Thanks

    Here is how my Filters are set up
    Vendor Name is Prompted
    AND
    Vendor Number is Prompted
    AND
    [   [Last_update_date_Vendor is prompted
    AND
    User_name_Vendor is prompted]
    OR
    [Last_update_date_Site is prompted
        AND
        User_name_Site is prompted]
    OR
    [Last_update_date_Bank is prompted
        AND
        User_name_Bank is prompted]
    The values from the dashboard prompts gets passed to the filter, but the sql that runs does not take the values in the where clause.

Maybe you are looking for

  • Creation of Order from copying existing order in B2B

    Hello Folks, Do we need to do the copying control setting in SAP CRM GUI and also any specific setting in SHOP MANAGEMENT PROFILE for copying exiting transaction on B2B screen? Regards

  • Reorder photos in album

    Does anyone know how to reorder photos in an album in iPhoto for iOS?

  • Export Sales Order Cycle for Country-IN

    Hai, Can anyone give me complete sales cycle of "Export sales order" - What extra config settings need to be maintained. It would be more helpful, if anyone gives detailed info including transactions ( eg:LC BOND, Bill of Lading, Creation/Utilization

  • Schedule a sender JDBC adapter

    Can I schedule my sender JDBC adapter to execute and pick up row at 2pm everyday? I see an option of poll intervals but not sure how to schedule. Any ideas? Thanks, Venkat.

  • Choice of software component in certification exam

    Hello everyone, I have just completed the SAP MM Solution Academy and am planning to take the ceritication exam this month. I was wondering if choosing the software component (R/3, ECC 5.0, ECC 6.0) has any effect in the exam. Thanks and regards, Hal