Data table header facet with multiple components?

Hi,
I have a data table to which I wish to add buttons to change the sort order of the items displayed. However when I add the 'buttons' to the 'header' facet I get strange results - some components are shown, some are not, and the order they appear seems almost random.
Is the header / footer facet designed only for one component - or can I combine them somehow?
Code snippet is
<h:dataTable id="table" rowClasses="oddRow,evenRow" width="80%"
value="#{ControllerBean.orderedResults}" var="meet">
<h:column>
<f:facet name="header">
<h:commandLink action="#{ControllerBean.setOrder}">
<h:graphicImage value="/img/up.gif" style="border: 0px" />
<f:param name="order" value="up-title" />
</h:commandLink>
<h:outputText value="#{msgs.title}" />
<h:commandLink action="#{ControllerBean.setOrder}">
<h:graphicImage value="/img/down.gif" style="border: 0px" />
<f:param name="order" value="down-title" />
</h:commandLink>
</f:facet>
<h:outputText id="meetTitle"
value="#{meet.title}" />
</h:column>
etc..
So to be clear - I want a header that contains two graphic buttons separated by the text. When I run this code as is here, I get just the 'down' button, but by changing the order I can sometimes get the down button and the text......
Cheers
Reeling

Yes, you can place it in a panelGrid or panelGroup component.
The following is an excerpt from a book:
TIP: To place multiple components in a table header or footer, you must
group them in an h:panelGroup tag, or place them in a container component
with h:panelGrid or h:dataTable. If you place multiple components in a facet, only the
first component will be displayed.
Thus you could have something like:
               <f:facet name="header">
                    <h:panelGrid columns="1">
                         <h:outputText value="#{fields.recordings}" style="font-weight: bolder" />
                         <h:panelGroup>
                              <h:outputText value="#{fields.type}" style="font-weight: bolder"/>
                              <h:outputText value="#{fields.date}" style="font-weight: bolder"/>
                              <h:outputText value="#{fields.time}" style="font-weight: bolder"/>
                         </h:panelGroup>
                    </h:panelGrid>
               </f:facet>

Similar Messages

  • Dynamic SORT with multiple components

    Hi all,
    I want to sort an internal table in this way:
    SORT itab BY (component).
    This is not difficult if "component" contains the name of ONE column of itab. But - and here is my problem - how can I sort with multiple components?
    Like this:
    SORT itab BY (comp_1) (comp_2) ... (comp_N).
    The number of components (N) shall be flexible. It is not possible to concatenate the components into one string-variable. This causes an error ITAB_ILLEGAL_COMPONENT.
    Brillant would be a solution which also contains the sort-direction (ASCENDING or DESCENDING for each component like this:
    SORT itab BY (comp_1) (dir_1)
                 (comp_2) (dir_2)
                 (comp_N) (dir_N).
    Is there a way to do so?
    Thanks for all hints!
    Mathias

    Hi Matahias ...
    From ABAP help...
    SORT itab.
    Extras:
    1. ... BY f1 f2 ... fn
    2. ... ASCENDING
    3. ... DESCENDING
    4. ... AS TEXT
    5. ... STABLE
    The syntax check performed in an ABAP Objects context is stricter than in other ABAP areas. See Field symbols not allowed as sort criterion.
    Effect
    The entries in the internal table are sorted in ascending order using the key from the table definition (DATA, TYPES).
    Addition 1
    ... BY f1 f2 ... fn
    Effect
    Uses the sort key defined by the sub-fields f1, f2, ..., fn of the table itab instead of the table key. The fields can be of any type; even number fields and tables are allowed.
    You can also specify the sort fields dynamically in the form (name). If name is blank at run time, the sort field is ignored. If itab is a table with a header line, you can also use a field symbol pointing to the header line of itab as a dynamic sort criterion. A field symbol that is not assigned is ignored. If a field symbol is assigned, but does not point to the header line of the internal table, a runtime error occurs.
    If the line type of the internal table contains object reference variables as components, or the entire line type is a reference variable, you can use the attributes of the object to which a reference is pointing in a line as sort criteria (see Attributes of Objects as the Key of an Internal Table
    You can address the entire line of an internal table as the key using the pseudocomponent TABLE_LINE. This is particularly relevant for tables with a non-structured line type when you want to address the whole line as the key of the table (see also Pseudocomponent TABLE_LINE With Internal Tables).
    If you use one of the additions 2 to 5 before BY, it applies to all fields of the sort key by default. You can also specify these additions after each individual sort field f1, f2, ..., fn. For each key field, this defines an individual sort rule which overrides the default.
    Cheers
    Preetham

  • Segmentation fault error during data load in parallel with multiple rules

    Hi,
    I'm trying to do sql data load in parallel with multiple rules (4 or 5 rules, maybe), i'm getting a "segmentation fault" error. I tested 3 rules file and it worked fine. we're using Essbase system 9.3.2., with UDB (v8) as the sql data source. ODBC driver is DataDirect 5.2 DB2 Wire Protocol Driver (ARdb222). Please let me know if you have any information on this.
    thx.
    Y

    Hi Thad,
    I was wondering, if system is unicode or non unicode that should not matter the amount and currency field . As currencies are defined by SAP and it is in pure English at least a currency code part of 3 Chars. 
    Could this because of some incosistency of data ??
    I would like to know for Which currency  had some special characters it it in that particular record ??
    Hope that helps.
    Regards
    Mr Kapadia

  • Dynamic table header/footer on multiple pages stay original

    hi experts,
    i've got a form with a dynamic table. this means that i have a footerrow with mapped information if it should be visible or not. so the table can have from 1 to 40 columns.
    i did some scripting in the table's initialize section:
    loop over count of colums and set the headerrow, row1 and footerrow elements for index x to hidden.
    everything works out fine BUT if the data spans over multiple pages the headerrow on pages 2 to last is original again. means that the hiding of cells is not effective any more. same with footerrow (but here its fine at last page and original at  page 1 to last -1).
    i tried to hide cells again in layout:ready section for the other instances of the headerrow.
    cells got hidden, but the still visible cells didnt relocate to the left (if i hide it, there should be no space between staying cells).
    can anyone please give me a hint what i am missing here?
    does anyone have a simple sample for this task? its all about the header/footer for multiple pages!
    thanks a lot!
    daapoo

    When the footer goes to the 2nd page the page subform is incremented so you will have to reference the page subform as well. I suggest that you add a button (this is for a test only) to the footer subform and add the code app.alert(this.somExpression). Now render the form and make sure the footer stays on one page. Hit the button and take note of the someExpression. Now add enough rows to force the footer to a new page. Hit th ebutton again and take note of the changed somExpression. So to solve your problem you will have to find out which page your footer is on. and then construct your expression to incorporate this chane in expression. Note that the indexes are 0 based but the page numbering is 1 based.
    Hope that helps
    Paul

  • Siebel 8.1.1.8 upgrade from 8.1.1.0 - host with multiple components

    Hi all,
    I'm running some tests of an update from Siebel SIA 8.1.1.0 to 8.1.1.8 in preparation for a Production upgrade. Our entire estate is Windows based, currently running Windows Server 2008. The update is not working as I expected.
    On one machine I have the Gateway and a Siebel Server (Object Manager). On another machine, I have a Siebel Server (eDocument).
    - Upgrading the single server (eDocument) using the new OUI installer seems to work fine
    - Upgrading the host with Gateway AND Siebel Server (Object Manager) seems to fail - where a DLL exists in both Gateway AND Server (i.e. sssaadmn.dll), only the Gateway DLL gets updated
    The result is that the Siebel Server (Object Manager) on the same host as the Gateway fails to start, with 'cannot load xxx.dll' appearing throughout the server and component logs. The single server (eDocument) seems to start fine with all components showing as 'Running' and visible through srvrmgr.
    Has anyone performed an update with the 8.1.1.8 OUI based installers and had a similar problem? Any idea how to resolve?
    Thanks for your thoughts!
    Oli

    Hi all,
    Looks like OUI can't cope with files with the Windows 'read only' attribute set. It will simply skip them altogether, without error. :(
    Anyway, unsetting the read only attribute across the SBA81 folder, prior to running the upgrade, seems to have resolved the problem for us.
    Regards,
    Oli

  • Load data from a file with multiple record types to a single table-sqlldr

    We are using two datastores which refer to the same file. The file has 2 types of records header and detail.
    h011234tyre
    d01rey5679jkj5679
    h011235tyrr
    d01rel5678jul5688
    d01reh5698jll5638
    Can someone help in loading these lines from one file with only two data stores(not 2 separate files) using File to Oracle(SQLLDR) Knowledge Module.

    Hi,
    Unfortunately the IKM SQLDR doesn't have the "when" condition to be wrote at ctl file.
    If you wish a simple solution, just add an option (drop me a email if you want a LKM with this)
    The point is:
    With a single option, you will control the when ctl clause and, for instance, can define:
    1) create 2 datastores (1 for each file)
    2) the first position will be a column at each datastore
    3) write the when condition to this first column at the LKM in the interface.
    Does it help you?

  • Selecting data from data base tables into itab with multiple select queries

    Hi all,
           i am dealing with a situation where in there is 3 DB tables in all say
              1. ITAB - ZTBL_MAIN.
              2. DB table - ZTBL_SUB1.
              3. DB table - ZTBL_SUB2.
    ZTBL_MAIN contains feilds from both tables 2 and 3 so to choose some records from ZTBL_SUB1 into the ITAB a select query has been written as below.
    SELECT * FROM ZTBL_SUB1 INTO CORRESPONDING FIELDS OF TABLE ZTBL_MAIN
        WHERE <condition>.
    now i also want some feilds in main for each record to be filled from the other DB table for which if i use another select query after the above one in my report prog. say..
    SELECT * FROM ZTBL_SUB2 INTO CORRESPONDING FIELDS OF TABLE ZTBL_MAIN
        WHERE <condition>.
    then all the previous records are going to be erased..Kindly let me know a way in which i can implement the above implementation.
    Thanks&Rgds,
    Naveen M

    hi,
        Ur suggestions solved the syntax error. However my intial problem was not solved i.e., using the statement
    SELECT * FROM ztbl_sub2 APPENDING CORRESPONDING FIELDS OF TABLE ztbl_main FOR ALL ENTRIES IN ztbl_main
         WHERE <field1> =  ztbl_main-<field1>.
    creates or appends some more entries into the itab thats all.. But that is not what i am trying to implement.
    As explained before the first select query would have filled certain fields for all records in ztbl_main from ztbl_sub1.
    Now in the second select query i want to fill other fields of ztbl_main for all the records already fetched using first select query by using my where condition.
    The above select query that was suggested only creates new records in the table ztab_main but does not fill the fields of the records as i expected.
    how do i fullfil my requirment..
    kindly help.
    thnks & Rgds,
    Naveen M

  • UIX table and textInput with multiple rows

    JDev 9.0.5.2
    I created an input form with a messageTextInput which allows the user to enter in multiple lines of text with the ability to use the return key. When I edit the record, the messageTextInput displays the lines of text just as the user entered them with the correct spacing and returns.
    My question is how do I get the messageTextInput data to display properly in a UIX read only table?
    I am able to display it with a scroll bar but I would prefer for the field to be sized based on the amount of data to display without scroll bars.
    Thanks for any help.

    I tried this but the table would not use my new style. Here is what I have in my xss:<style selector=".DVTableBorder">
    <property name="border-width">0px 0px 0px 0px</property>
    </style>

  • UIPickerView and didSelectRow with multiple components problem

    If I spin two components at the same time in my picker I only get one call to didSelectRow....
    More specifically, if I spin one component and move another component no call is recieved until the first component stops spinning, and so the second component move is missed.
    I use this to update displayed data so it looks badly wrong. Is this yet another bug with the SDK?

    Hi,
    I have the same problem. Actually it is not so annoying in my application as it is only cosmetic. However my application was rejected by Apple because of this issue.
    I checked what would happen in the built-in alarm app if the hour and minute picker wheels are rolled at the same time... and both value are recorded. So there must be a programmatic solution to this problem and it is definitely not a bug of the SDK.
    It would be great if someone knows how to solve this.

  • BSP MVC with multiple components approaches

    Hello,
    I have developed in BSP with follows MVC. The BSP application had multiple subcontroller and one main controller. I had one model for each controller,
    but the models were "stored" on the level of the main
    controller.
    Is this the right way? Are there are other approaches?
    Regards & Thanks,
    Guido

    Hi,
    Do you mean to say that u have instantiated the subcontroller models in the main controller using the model data and assigning them to the views in ur subcontroller do_request method?If so it will work however a better approach is to instantiate one main model class (make different method in the model class to access the records from database)in the main controller and use it to assign to the view in the do_request method of the subcontroller.
    Hope this helps.
    Reward useful answers.
    Regards,
    Shrita.

  • Single data set, loaded once, with multiple xpath paths?

    All,
    Is it possible to load xml via a URL one time on a page
    request and then
    create mutliple datasets from that single call using
    different xpath
    expressions? sort of like doing a mega query then creating
    subsets of that
    query?
    something like:
    <root>
    <process type="1" blah="blah"/>
    <process type="1" blah="blah2"/>
    <process type="2" blah="blah3"/>
    </root>
    ds1 = new XMLDataSet(blah.cfm,"/root/process[@type=1]";
    ds2 = new XMLDataSet(blah.cfm,"/root/process[@type=2]";
    what i really need to do is make that cfm call one time per
    load.
    thanks for any help.
    Marc

    Surely. Sorry for not being more specific earlier.
    I'm currently using the tab widget. there are about 5 tabs
    total. each of
    those tabs represents a list of process in a given "status",
    like "running",
    "pending", etc. Currently, the way I create this is to run a
    big old query
    that gets ALL processes, and then I loop over that query,
    grouping on the
    Process Status, and create a tab for each status. I'm not
    using any
    spry:repeat regions or anything like that currently. In fact,
    the only spry
    i'm using at all is for the tab widget. the query is just a
    query that runs
    when the page loads. it's not doing any spry data loading
    with XMLDataSet or
    anything.
    However, I'd like to convert this process to using the
    XMLDataSet so that I
    can use the spry repeat regions. What I'd like, then, is to
    pass a cfm page
    as the XML param. this would return the same query i'm
    running now, except
    in xml format. I'd also like to pass the loadInterval param
    so that I can
    avail myself of the automatic data refreshing so that all of
    the tabs will
    have their content updated at the specified interval, as
    opposed to doing it
    with a page refresh which is how I do it now (which is just a
    brute force
    way of rerunning the query and recreating all html).
    so in the end what i end up with is 5 tabs, each representing
    a status,
    whose data comes from the same xml but whose tab content is a
    subset of that
    xml. the loadinterval then ensures that all tabs are updated
    at the
    appropriate frequency.
    how's that? clearer?
    thanks again!
    Marc
    "CristianC MARIN" <[email protected]> wrote
    in message
    news:erch4i$erv$[email protected]..
    > Hello Marc,
    >
    > Could you please describe me in more details what do you
    mean by reload
    > param and your exact use case to make sure I have the
    entire picture in
    > mind when I'll answer you?
    >
    > Cristian

  • Obtain Data Table header Dynamicaly

    Hi all,
    I have a requirment.
    user will give the name of a database table and all the field-header (i.e. Field labels) will be stored in a internal table.
    Is there any FM , suitable for that.
    Thanks in advance.
    Regards,
    Anirban

    Hello
    DB_GET_TABLE_FIELDS

  • JTable column with multiple components

    Hi,
    I have to use a List and a comobobox in a single column. How can i achieve this. It will be a great help if somebody can provide me some sample code.
    I know how to set a custom component for the entire column or entire row. So please provide me the code that may explain how can i add two different components to the single column?
    Thanks

    If it is display only, use cell renderer.
    If you do I/O or event dispatching, use cell editor.
    A Jpanel containing JList and JComboBox would be the component they return.
    Smells bad design, though.

  • Data binding with Multiple Filter

    Hi Experts,
    I am trying to do the data binding using filters with multiple values.
    ex: I am selecting the multiple values from list dialog and those i want to pass to odata service as a filters.
    name : abc
                   pqr
    I am looping on above and pushing it to array of filters.
         jQuery.sap.require("sap.ui.model.FilterOperator");
         var FilterOperator = sap.ui.model.FilterOperator;
         var filtersTerr =  new Array();
       for(i=0;i<name.length;i++){
      filterName = new sap.ui.model.Filter("FirstName", sap.ui.model.FilterOperator.EQ, name[i]);
      filter.push(filterName );
    this..getBinding("items").filter([filter],false);
    Final filter should be something $filter=FirstName='abc' or FirstName='pqr'.
    I have already looked into below discussions but somehow came to conclusion that array cannot be use with OR/AND.
    Odata Filter with OR
    http://scn.sap.com/thread/3462246
    http://scn.sap.com/thread/3560814
    Please let me know how this needs to be written.
    Thanks,
    Rahul

    Hi Rahul
    There are many ways.
    Filter for table
    var sRlUrl = "http://<host Name>/sap/opu/odata/sap/ZTWMP" ;
    var list = new sap.ui.model.odata.ODataModel( sRlUrl, false, "username", "pswd"); 
    list.setDefaultBindingMode(sap.ui.model.BindingMode.TwoWay);
    var iv_proID  = sap.ui.getCore().getElementById('input1').getValue();
    var iv_listNo = sap.ui.getCore().getElementById('input2').getValue();
    var iv_Matnr  = sap.ui.getCore().getElementById('input3').getValue();
    var iv_Po     = sap.ui.getCore().getElementById('input4').getValue(); 
    //... Set any Filters .. if reqd'
    var oFilter = new Array();
    var iCount = 0;
    if (iv_proID) {
    oFilter[iCount] = new sap.ui.model.Filter("abc", sap.ui.model.FilterOperator.EQ, sap.ui.getCore().getElementById('input1').getValue());
    iCount++;
    if (iv_listNo){
    oFilter[iCount] = new sap.ui.model.Filter("def", sap.ui.model.FilterOperator.EQ, sap.ui.getCore().getElementById('input2').getValue());
    iCount++;
    oFilter[iCount] = new sap.ui.model.Filter("PcTotal", sap.ui.model.FilterOperator.EQ,"HEADER" );
    iCount++;
    sap.ui.getCore().getElementById('T-POhdr-DR').setModel(list);
    //... Bind Rows with oData, with filters if any
    sap.ui.getCore().getElementById('T-POhdr-DR').bindRows({
    path: '/t_entity set/',
    filters: oFilter
    2 General filter
      OData.read({ requestUri: "http://<URL>:8001/sap/opu/odata/sap/ZTMP_ABC/Item?$filter=ID eq '"+ID+"' and DESC eq '"+Desc+"'", headers: { Accept: "application/json" } }, function (data, response) {
    if (data.results[0]) {
                     sap.ui.getCore().byId("oInput2").setText(data.results[0].<odata field to assign>;

  • Date picker not showing up in iOS Reader with multiple dates?

    Hi all,
    The date picker for iOS shows up for forms with a single date box. However, with multiple forms, the keyboard pops up instead of the date picker. It still handles correctly formatting-wise, but it's become a bit of hassle with having to type the date instead of simply filling out today. Is this a bug or by design?

    Hi jncasino,
    We are not able to reproduce this issue at our end. Could you please share the file having this issue to help us investigate and fix this issue?
    Thanks,
    -Shilpi

Maybe you are looking for