Query for how to display unique rows in a table

Can i have a query for displaying unique rows in a table.

use d query
select distinct col1,col2... from table ;

Similar Messages

  • QUERY FOR HOW TO ACCESS NEXT ROW WHILE IN CURRENT ROW

    Hi, can you please make a oracle sql query for the following.
    My Data in table dt0attlog:
    ID  staffid  logdt          login                        logout       
    01  aw101    01.12.11   01.12.11 08.30   
    01  aw101    01.12.11                             01.12.11 10.30   
    01  aw101    01.12.11   01.12.11 11.40   
    01  aw101    01.12.11                            01.12.11 14.30   
    01  aw101    01.12.11   01.12.11 15.00   
    01  aw101    01.12.11                             01.12.11 17.45   
    01  aw102    01.12.11   01.12.11 19.20   
    01  aw102    01.12.11                               01.12.11 20.30   
    01  aw102    01.12.11   01.12.11 21.50   
    01  aw102    01.12.11                             01.12.11 23.10   
    01  aw102    01.12.11   01.12.11 23.20   
    01  aw102    02.12.11                          02.12.11 07.00   
    01  aw102    02.12.11   02.12.11 18.00
    01  aw102    03.12.11                        03.12.11 04.30
    01  aw103    01.12.11   01.12.11 09.40 
    01  aw104    01.12.11                         01.12.11 18.00   
    My required output:
    ID  staffid      logdt      login                    logout                diff-in-seconds   
    01  aw101    01.12.11   01.12.11 08.30    01.12.11 10.30  7200
    01  aw101    01.12.11   01.12.11 11.40    01.12.11 14.30  10200
    01  aw101    01.12.11   01.12.11 15.00    01.12.11 17.45  9900
    01  aw102    01.12.11   01.12.11 19.20    01.12.11 20.30  4200
    01  aw102    01.12.11   01.12.11 21.50    01.12.11 23.10  4800
    01  aw102    01.12.11   01.12.11 23.20    02.12.11 07.00  27600
    01  aw102    02.12.11    02.12.11 18.00    03.12.11 04.30  37800
    01  aw103    01.12.11   01.12.11 09.40
    01  aw104    01.12.11              01.12.11 18.00
    Here record aw102 & dt. 01.12.11 / 02.12.11, it should shows the next day out in
    the current date ie. 01.12.11.
    thanks and await your great help please.

    the followings are the testcase
    SQL> create table dt0device (
      2     deviceid varchar2(15),
      3     staffid varchar2(10),
      4     logdt  date,
      5      in_out_flag varchar2(3));
    Table created.
    SQL>  insert into dt0device values('01','aw101',to_date('01.12.2011 08:30','DD/MM/RRRR HH24.MI'),'IN');
    1 row created.
    SQL>   insert into dt0device values('01','aw101',to_date('01.12.2011 10:30','DD/MM/RRRR HH24.MI'),'OUT');
    1 row created.
    SQL>   insert into dt0device values('01','aw101',to_date('01.12.2011 11:40','DD/MM/RRRR HH24.MI'),'IN');
    1 row created.
    SQL>   insert into dt0device values('01','aw101',to_date('01.12.2011 14:30','DD/MM/RRRR HH24.MI'),'OUT');
    1 row created.
    SQL>   insert into dt0device values('01','aw101',to_date('01.12.2011 15:00','DD/MM/RRRR HH24.MI'),'IN');
    1 row created.
    SQL>   insert into dt0device values('01','aw101',to_date('01.12.2011 17:45','DD/MM/RRRR HH24.MI'),'OUT');
    1 row created.
    SQL>
    SQL>   insert into dt0device values('01','aw102',to_date('01.12.2011 19:20','DD/MM/RRRR HH24.MI'),'IN');
    1 row created.
    SQL>   insert into dt0device values('01','aw102',to_date('01.12.2011 20:30','DD/MM/RRRR HH24.MI'),'OUT');
    1 row created.
    SQL>   insert into dt0device values('01','aw102',to_date('01.12.2011 21:50','DD/MM/RRRR HH24.MI'),'IN');
    1 row created.
    SQL>   insert into dt0device values('01','aw102',to_date('01.12.2011 23:10','DD/MM/RRRR HH24.MI'),'OUT');
    1 row created.
    SQL>   insert into dt0device values('01','aw102',to_date('01.12.2011 23:20','DD/MM/RRRR HH24.MI'),'IN');
    1 row created.
    SQL>   insert into dt0device values('01','aw102',to_date('02.12.2011 07:00','DD/MM/RRRR HH24.MI'),'OUT');
    1 row created.
    SQL>   insert into dt0device values('01','aw102',to_date('02.12.2011 18:00','DD/MM/RRRR HH24.MI'),'IN');
    1 row created.
    SQL>   insert into dt0device values('01','aw102',to_date('03.12.2011 04:30','DD/MM/RRRR HH24.MI'),'OUT');
    1 row created.
    SQL>
    SQL>   insert into dt0device values('01','aw103',to_date('01.12.2011 09:40','DD/MM/RRRR HH24.MI'),'IN');
    1 row created.
    SQL>   insert into dt0device values('01','aw104',to_date('01.12.2011 18:00','DD/MM/RRRR HH24.MI'),'OUT');
    1 row created.
    SQL>  create table dt0attlogdevice
      2     ( staffid   varchar2(10),
      3       logdt date,
      4       login  date,
      5       logout date);
    Table created.
    SQL>   insert into dt0attlogdevice  select staffid,logdt,
      2              decode(in_out_flag,'IN',logdt,null) login,
      3              decode(in_out_flag,'OUT',logdt,null) logout
      4       from dt0device;
    16 rows created.
    SQL> select staffid,to_char(logdt,'DD/MM/RR') logdt, to_char(login,'DD/MM/RR HH24.MI') login,
      2  to_char(logout,'DD/MM/RR HH24.MI') logout
      3  from dt0attlogdevice;
    STAFFID    LOGDT    LOGIN          LOGOUT                                      
    aw101      01/12/11 01/12/11 08.30                                             
    aw101      01/12/11                01/12/11 10.30                              
    aw101      01/12/11 01/12/11 11.40                                             
    aw101      01/12/11                01/12/11 14.30                              
    aw101      01/12/11 01/12/11 15.00                                             
    aw101      01/12/11                01/12/11 17.45                              
    aw102      01/12/11 01/12/11 19.20                                             
    aw102      01/12/11                01/12/11 20.30                              
    aw102      01/12/11 01/12/11 21.50                                             
    aw102      01/12/11                01/12/11 23.10                              
    aw102      01/12/11 01/12/11 23.20                                             
    STAFFID    LOGDT    LOGIN          LOGOUT                                      
    aw102      02/12/11                02/12/11 07.00                              
    aw102      02/12/11 02/12/11 18.00                                             
    aw102      03/12/11                03/12/11 04.30                              
    aw103      01/12/11 01/12/11 09.40                                             
    aw104      01/12/11                01/12/11 18.00                              
    16 rows selected.
    ===
    from the above table , I want to generate ouput as below:
    staffid  logdt      login             logout          diff-in-seconds   
    aw101    01.12.11   01.12.11 08.30    01.12.11 10.30  7200
    aw101    01.12.11   01.12.11 11.40    01.12.11 14.30  10200
    aw101    01.12.11   01.12.11 15.00    01.12.11 17.45  9900
    aw102    01.12.11   01.12.11 19.20    01.12.11 20.30  4200
    aw102    01.12.11   01.12.11 21.50    01.12.11 23.10  4800
    aw102    01.12.11   01.12.11 23.20    02.12.11 07.00  27600
    aw102    02.12.11   02.12.11 18.00    03.12.11 04.30  37800
    aw103    01.12.11   01.12.11 09.40
    aw104    01.12.11              01.12.11 18.00
    Here record aw102 & dt. 01.12.11 / 02.12.11, it should shows the next day out in
    the current date ie. 01.12.11.
    I dont know how to make query for the above output.
    please help me.

  • How to display particular ROW of a table control in display/change mode

    Hi,
    Can we make particular ROW in a table control display mode or editable mode depending upon the conditions?.
    Any inputs..
    Rgds,
    Lakshmiraj

    Hi,
    Yes it is possible. check the follwoing code for help.
    *&  Include           Z101954_ASSIGNMENT1I01
    *&      Module  VALIDATE_SALES_ORG  INPUT
          text
    MODULE validate_sales_org INPUT.
    SELECT SINGLE zvkorg FROM vbak INTO zvbak-zvkorg
    *WHERE zvbeln = zbookhdr-zvbeln.
    IF sy-subrc <> 0.
       MESSAGE 'INVALID AIRLINE ID INPUT' TYPE 'I'.
       CALL SCREEN 1000.
    ENDIF.
    ENDMODULE.                 " VALIDATE_SALES_ORG  INPUT
    *&      Module  USER_COMMAND_1001  INPUT
          text
    MODULE user_command_1001 INPUT.
      var3 = 1.
      IF sy-ucomm <> 'SAVE'.
        PERFORM material_check.
        IF sy-subrc <> 0.
          MESSAGE 'ENTER THE CORRECT MATERIAL NUMBER' TYPE 'I'.
        ELSE.
          SELECT SINGLE zmaktx zmeins zwaerk zstprs FROM zmara
            INTO CORRESPONDING FIELDS OF it_salesitems
             WHERE zmatnr = it_salesitems-zmatnr.
          SELECT SINGLE zwerks zlgort FROM zorg
            INTO CORRESPONDING FIELDS OF it_salesitems
            WHERE zvkorg = wa_salesorder-zvkorg
             AND zvtweg = wa_salesorder-zvtweg
             AND zspart = wa_salesorder-zspart.
          it_salesitems-znetwr = it_salesitems-zstprs * it_salesitems-zbrgew.
         MODIFY it_salesitems FROM it_salesitems  INDEX sy-tabix.
          MOVE-CORRESPONDING it_salesitems TO temp_salesitems.
          APPEND temp_salesitems.
          REFRESH it_salesitems.
        ENDIF.
      ENDIF.
    LOOP AT temp_salesitems.
      if it_salesitems-pick = 'X'.
               LOOP AT SCREEN.
             IF screen-name EQ 'DETAIL'.
               screen-input = 1.
               MODIFY SCREEN.
             ENDIF.
           ENDLOOP.
           endif.
           endloop.
      CASE sy-ucomm.
        WHEN 'SAVE'.
          PERFORM check_ship_to_party.
          IF sy-subrc <> 0.
            MESSAGE 'ENTER THE CORRECT SHIP TO PARTY ' TYPE 'I'.
          ELSE.
            PERFORM check_payer.
            IF sy-subrc <> 0.
              MESSAGE 'ENTER THE CORRECT PAYER' TYPE 'I'.
            ELSE.
              PERFORM check_bill_to_party.
              IF sy-subrc <> 0.
                MESSAGE 'ENTER THE CORRECT BILL TO PARTY' TYPE 'I'.
              ELSE.
                wa_salesorder-zernam = sy-uname.
                MOVE-CORRESPONDING wa_salesorder TO zvbak.
                MODIFY zvbak.
                LOOP AT it_salesitems.
                  it_salesitems-zvbeln = wa_salesorder-zvbeln.
                  MOVE-CORRESPONDING it_salesitems TO zvbap.
                  MODIFY zvbap.
                ENDLOOP.
                IF sy-subrc = 0.
                  MESSAGE 'THE DATA IS SAVED SUCCESSFULLY' TYPE 'I'.
                  CLEAR wa_salesorder.
                  REFRESH it_salesitems.
                  REFRESH temp_salesitems.
                  IF sy-tcode = 'ZVA01'.
                    CALL SCREEN '1000'.
                  ELSE.
                    CALL SCREEN '1003'.
                  ENDIF.
                ENDIF.
              ENDIF.
            ENDIF.
          ENDIF.
        WHEN 'DETAIL'.
          CALL SCREEN '1002'.
        WHEN 'BACK'.
          IF sy-tcode = 'ZVA03'.
            CLEAR wa_salesorder.
            CALL SCREEN '1003'.
          ELSE.
            PERFORM pop_up.
          ENDIF.
        WHEN 'EXIT'.
          IF sy-tcode = 'ZVA03'.
            LEAVE PROGRAM.
          ELSE.
            PERFORM pop_up.
          ENDIF.
        WHEN 'CANCEL'.
          IF sy-tcode = 'ZVA03'.
            CLEAR wa_salesorder.
            CALL SCREEN '1003'.
          ELSE.
            PERFORM pop_up.
          ENDIF.
      ENDCASE.
    ENDMODULE.                 " USER_COMMAND_1001  INPUT
    *&      Module  input_help_sold_to_party  INPUT
          text
    MODULE input_help_sold_to_party INPUT.
      SELECT zkunag FROM zvbak INTO CORRESPONDING FIELDS OF TABLE
        itab.
      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
        EXPORTING
      DDIC_STRUCTURE         = ' '
          retfield               = 'ZKUNAG'
      PVALKEY                = ' '
         dynpprog               = sy-cprog
         dynpnr                 = '1000'
         dynprofield            = 'ZKUNAG'
      STEPL                  = 0
      WINDOW_TITLE           =
      VALUE                  = ' '
         value_org              = 'S'
      MULTIPLE_CHOICE        = ' '
      DISPLAY                = ' '
      CALLBACK_PROGRAM       = ' '
      CALLBACK_FORM          = ' '
      MARK_TAB               =
    IMPORTING
      USER_RESET             =
        TABLES
          value_tab              = itab
      FIELD_TAB              =
      RETURN_TAB             =
      DYNPFLD_MAPPING        =
    EXCEPTIONS
      PARAMETER_ERROR        = 1
      NO_VALUES_FOUND        = 2
      OTHERS                 = 3
      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    ENDMODULE.                 " input_help_sold_to_party  INPUT
    *&      Form  pop_up
          text
    -->  p1        text
    <--  p2        text
    FORM pop_up .
      CALL FUNCTION 'POPUP_TO_CONFIRM'
        EXPORTING
      TITLEBAR                    = ' '
      DIAGNOSE_OBJECT             = ' '
          text_question               = 'DO YOU WANT TO SAVE THE ORDER?'
         text_button_1               = 'YES'(001)
         icon_button_1               = ' '
         text_button_2               = 'No'(002)
         icon_button_2               = ' '
         default_button              = '1'
         display_cancel_button       = 'X'
         userdefined_f1_help         = ' '
      START_COLUMN                = 25
      START_ROW                   = 6
      POPUP_TYPE                  =
      IV_QUICKINFO_BUTTON_1       = ' '
      IV_QUICKINFO_BUTTON_2       = ' '
    IMPORTING
         answer                      = ans
    TABLES
      PARAMETER                   =
    EXCEPTIONS
      TEXT_NOT_FOUND              = 1
      OTHERS                      = 2
      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
      CASE ans.
        WHEN '001'.
          PERFORM check_ship_to_party.
          IF sy-subrc <> 0.
            MESSAGE 'ENTER THE CORRECT SHIP TO PARTY ' TYPE 'I'.
          ELSE.
            PERFORM check_payer.
            IF sy-subrc <> 0.
              MESSAGE 'ENTER THE CORRECT PAYER' TYPE 'I'.
            ELSE.
              PERFORM check_bill_to_party.
              IF sy-subrc <> 0.
                MESSAGE 'ENTER THE CORRECT BILL TO PARTY' TYPE 'I'.
              ELSE.
                wa_salesorder-zernam = sy-uname.
                MOVE-CORRESPONDING wa_salesorder TO zvbak.
                MODIFY zvbak_101954.
                temp_salesitems-zvbeln = wa_salesorder-zvbeln.
                MOVE-CORRESPONDING temp_salesitems TO zvbap.
                MODIFY zvbap.
                IF sy-subrc = 0.
                  MESSAGE 'THE DATA IS SAVED SUCCESSFULLY' TYPE 'I'.
                  CLEAR wa_salesorder.
                  REFRESH it_salesitems.
                  REFRESH temp_salesitems.
                  IF sy-ucomm = 'EXIT'.
                    LEAVE PROGRAM.
                  ENDIF.
                  IF sy-tcode = 'ZVA01'.
                    CALL SCREEN '1000'.
                  ELSE.
                    CALL SCREEN '1003'.
                  ENDIF.
                ENDIF.
              ENDIF.
            ENDIF.
          ENDIF.
        WHEN '002'.
          IF sy-tcode = 'ZVA01'.
            CLEAR wa_salesorder.
            REFRESH it_salesitems.
            REFRESH temp_salesitems.
            CALL SCREEN '1000'.
          ELSE.
            CLEAR wa_salesorder.
            REFRESH it_salesitems.
            REFRESH temp_salesitems.
            CALL SCREEN '1003'.
            CLEAR ans.
          ENDIF.
      ENDCASE.
    ENDFORM.                    " pop_up
    *&      Module  USER_COMMAND_1002  INPUT
          text
    MODULE user_command_1002 INPUT.
    IF sy-datar = 'X'.
       PERFORM material_check.
       IF sy-subrc <> 0.
         MESSAGE 'ENTER THE CORRECT MATERIAL' TYPE 'I'.
       ELSE.
         SELECT SINGLE zmaktx zmeins zwaerk zstprs FROM zmara_101954
         INTO CORRESPONDING FIELDS OF wa_salesitems
           WHERE zmatnr = wa_salesitems-zmatnr.
         wa_salesitems-znetwr =  wa_salesitems-zstprs * wa_salesitems-zbrgew.
       ENDIF.
       var = 1.
    ENDIF.
      IF sy-ucomm = 'BACK'.
        LOOP AT temp_salesitems.
          MODIFY temp_salesitems FROM wa_salesitems .
        ENDLOOP.
        it_salesitems-pick = ' '.
        CALL SCREEN '1001'.
      ENDIF.
    ENDMODULE.                 " USER_COMMAND_1002  INPUT
    *&      Module  USER_COMMAND_1000  INPUT
          text
    MODULE user_command_1000 INPUT.
      CASE sy-ucomm.
        WHEN 'NEXT'.
          SELECT * FROM zt001k_101954 INTO CORRESPONDING FIELDS OF
            temp_salesorder WHERE
            zvkorg = wa_salesorder-zvkorg AND
            zvtweg = wa_salesorder-zvtweg AND
            zspart = wa_salesorder-zspart.
          ENDSELECT.
          IF sy-subrc = 0.
            CALL SCREEN '1001'.
          ELSE.
            MESSAGE 'Invalid Data Entered' TYPE 'I'.
            CALL SCREEN '1000'.
          ENDIF.
      ENDCASE.
    ENDMODULE.                 " USER_COMMAND_1000  INPUT
    *&      Module  USER_COMMAND_1003  INPUT
          text
    MODULE user_command_1003 INPUT.
      IF sy-ucomm = 'NEXT'.
       IF sy-datar = ' '.
         MESSAGE 'ENTER PURCHASE ORDER NUMBER' TYPE 'I'.
         CALL SCREEN 1000.
        IF NOT wa_salesorder-zvbeln CO '0123456789'.
          MESSAGE 'PURCHASE ORDER NUMBER IS NOT IN THE EXPECTED FORMAT' TYPE 'I'.
          CALL SCREEN '1003'.
        ENDIF.
        var3 = 0.
        CALL SCREEN '1001'.
      ENDIF.
    ENDMODULE.                 " USER_COMMAND_1003  INPUT
    *&      Module  input_help_sales_order  INPUT
          text
    MODULE input_help_sales_order INPUT.
      SELECT zvbeln FROM zvbak_101954 INTO CORRESPONDING FIELDS OF TABLE
      itab1.
      CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
        EXPORTING
      DDIC_STRUCTURE         = ' '
          retfield               = 'ZVBELN'
      PVALKEY                = ' '
         dynpprog               = sy-cprog
         dynpnr                 = '1003'
         dynprofield            = 'ZVBELN'
      STEPL                  = 0
      WINDOW_TITLE           =
      VALUE                  = ' '
         value_org              = 'S'
      MULTIPLE_CHOICE        = ' '
      DISPLAY                = ' '
      CALLBACK_PROGRAM       = ' '
      CALLBACK_FORM          = ' '
      MARK_TAB               =
    IMPORTING
      USER_RESET             =
        TABLES
          value_tab              = itab1
      FIELD_TAB              =
      RETURN_TAB             =
      DYNPFLD_MAPPING        =
    EXCEPTIONS
      PARAMETER_ERROR        = 1
      NO_VALUES_FOUND        = 2
      OTHERS                 = 3
      IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    ENDMODULE.                 " input_help_sales_order  INPUT
    *&      Module  back_command  INPUT
          text
    module back_command input.
    *if sy-ucomm = 'SAVE' OR 'BACK' OR 'DETAIL' OR 'EXIT' OR 'CANCEL'.
    *endif.
    endmodule.                 " back_command  INPUT
    Regards
    Rajesh Kumar

  • ADF Faces Query Panel: How to display master data in detail table?

    Before stating the question, here is the background:
    I've a Fusion ADF (model/viewController) app that includes 2 tables with a master-detail relationship. The master table stores error numbers and associated levels of logging severity; the detail table stores the actual message text. These need to be separate, related tables because the requirement is that message text for a given error number can vary by product release.
    Messages are added in a bounded task flow; data for the master table entered in 1 fragment, data for the detail table in a 2nd page fragment. In the app, the Entity Objects for these tables are related with a foreign key association and have a composition association. This was done because the error numbers are generated in an Oracle DB sequence, and from what i have read that is a way in a task flow to have ADF put the number generated for the master table into the related key of the child table.
    The question is this:
    I need to create an ADF query panel with a table that searches on the detail DB table. However, i also need to use a couple of fields from the master DB table in both the query and in the ADF table. In addition, I need to add the ability for the user to edit either the master or detail record for the row he/she selects in the ADF table. I know how to create a view that would display the info i need; however, i have not been able to figure out how to obtain the keys for the selected ADF table row and pass them to the task flows that would edit.
    The master table has a numeric primary key. The detail table primary key consists of a foreign key to the master key and also a release number.
    I'm new to ADF and have been struggling with how to do this: i've a workaround that is functional but too klunky to be a permanent solution. So, could someone point me to some information on how to accomplish this?
    Versions: JDeveloper 11.1.1.4, ADF Business Components 11.1.1.59.23
    Thanks for your help!

    Thanks. I tried this out, but ran into an issue in that the detail table has 2 keys - a foreign key to the master primary key, and a 2nd key that uniquely distinguishes the detail. So i tried various things centered around using the SetCurrentRowWithKey operation and trying to obtain the selected ADF table row using an EL OF #{data.<pageDef>.<Iterator>.currentRowKeyString}; however i could not get the detail record for the selected row to display.
    I did find another approach that worked - I am wondering, is there anything problematic with this approach?:
    1. Create a VO joining the Master and Detail tables, with the Detail table being updatable.
    2. Made sure the applicable attributes were defined as keys.
    3. Add a query panel w/table using this VO.
    4. Create an ADF form based on the VO, showing the updatable fields.
    5. Create a bounded task flow with the following set on the Behavior tab:
    a. Share data controls with calling task flow
    b. Always Begin Transaction
    I specifically am wondering whether "Share data controls with calling task flow" has any negative implications or gotchas to handle. The doc at http://download.oracle.com/docs/cd/E21764_01/web.1111/b31974/taskflows_parameters.htm#ADFFD1693 doesn't suggest so, but just wanted to double-check before I go down this path.

  • How to display four rows in one table and the rest in another table?

    Hello everybody,
    I am trying to solve a problem that I cannot find any direct answers to.  In essence the problem goes like this:
    1) I want to populate two tables from xml data.
    2) The first table should only diplay the first four rows of data.
    3) The second table should display the rest of the rows (starting from row 5).
    I can create the first table so that it only shows up to the first four rows.
    I cannot find a way to set up the second table so that it shows the rest of the rows starting at row 5.
    To illustrate the problem I have attached my livecycle template file with the two table definitions and the corresponding xml data.  If you put these two files in the same directory and open the pdf file using LiveCycle designer you should see what I mean. (The table with column heading 'Item List 2' shows all of the records in the xml file when I only want it to show records 5 and 6)
    Some other niggling issue I have come up against is the data displays differently when I open the pdf file with Adobe Acrobat pro and then use the Forms/manage form data/import data menu to bind that xml file.  ( For some the 'Item List 2' table does not display any data)  Does anybody know why that is occurring?
    Any help on this would be very much appreciated because it will help me get past a significant issue I am running into with a complex form I am trying to build for a client of mine.
    Note:  I am using Adobe Acrobat Pro version 9 and the Adobe Livecycle is version 8.2.1
    Thanks in advance.
    Geoff.

    Hi,
    First solution is you can play with predicates:
    val value = 4
    var items= Ref(xfa.resolveNodes(concat("$record.itemsCollection.item.[itemNumber>""",value,"""]")))
    after that you will have to use addInstance and assign all fields by scripting. It is hard way.
    Second solution you can simply hide unneccessary rows by putting initialise script on item row:
    if (this.index <4){this.presence = "hidden" }
    Hope this helps.
    Paul Butenko

  • How to display first row value returened from a query as checked as default in a report

    How to display first row value returned from a query as checked as default in a report
    Example
    Parameter 1
    Paramerter2
    ABD
    x(checked)
    Test
    DEF
    JMG
    Mudassar

    Hi Mudassar,
    The issue is caused by the order in which the parameters appear in the report data tab can be difference between our report execution and it failing. In other words, “Parameter2” is execution before parameter “A” due to this issue. We can adjust the parameter’s
    order to solve the issue.
    If “Parameter2” is parameter “A”, we cannot use that expression. Because fields cannot be used in report parameter expression, if we want to display the first value returned from a query as default value, we have to fill the “Specify values” text box with
    the specific value in Default Values dialog box.
    Regards,
    Alisa Tang
    Alisa Tang
    TechNet Community Support

  • How to display alternate row colors in struts form?

    hi,
    I am using struts lib to display data in jsp page.
    <logic:iterate id="result" name="listofPorjetcts" indexId = "i">
    <tr>
    <td ><bean:write name="result" property="projectName"/></td>
    </tr>
    how to display alternaternate row colors ?
    any one can help?

    hey i not sure abt structs, what i did for jsp was using a boolean.
    declare boolean red=true;
    <tr
    <%
    if(red){%>
    class="red" >
    <%
    red=false;
    }else{%>
    class="white">
    <%
    red=true;
    %>
    take note that the class is a predefined css. I think u can use style="background-color:#red "
    You can seearch the web for more info.

  • How can i update rows  in a table based on a match from a select query

    Hello
    How can i update rows in a table based on a match from a select query fron two other tables with a update using sqlplus ?
    Thanks Glenn
    table1
    attribute1 varchar2 (10)
    attribute2 varchar2 (10)
    processed varchar2 (10)
    table2
    attribute1 varchar2 (10)
    table3
    attribute2 varchar2 (10)
    An example:
    set table1.processed = "Y"
    where (table1.attribute1 = table2.attribute1)
    and (table1.attribute2 = table3.attribute2)

    Hi,
    Etbin wrote:
    Hi, Frank
    taking nulls into account, what if some attributes are null ;) then the query should look like
    NOT TESTED !
    update table1 t1
    set processed = 'Y'
    where exists(select null
    from table2
    where lnnvl(attribute1 != t1.attribute1)
    and exists(select null
    from table3
    where lnnvl(attribute2 != t1.attribute2)
    and processed != 'Y'Regards
    EtbinYes, you could do that. OP specifically requested something else:
    wgdoig wrote:
    set table1.processed = "Y"
    where (table1.attribute1 = table2.attribute1)
    and (table1.attribute2 = table3.attribute2)This WHERE clause won't be TRUE if any of the 4 attribute columns are NULL. It's debatable about what should be done when those columns are NULL.
    But there is no argument about what needs to be done when processed is NULL.
    OP didn't specifically say that the UPDATEshould or shouldn't be done on rows where processed was already 'Y'. You (quite rightly) introduced a condition that would prevent redo from being generated and triggers from firing unnecessarily; I'm just saying that we have to be careful that the same condition doesn't keep the row from being UPDATEd when it is necessary.

  • How to display records into a non table base block..

    Hi,
    Can anybody help me how to display records into a non table base block....
    Find below is my coding but it only display the last record in the first line
    in the block.
    PROCEDURE CREATE_CARTON_QUESTION IS
    CURSOR car_c IS
    select /*+ rule */ question_id, question_description
    from WHOP.QADB_QUESTIONS
    where question_category = 'Carton'
    and question_active_flag = 'Y';
    v_found VARCHAR2(10);
    v_status boolean;
    v_error      varchar2(150);
    v_count number;
    car_r car_c%rowtype;
    begin
    begin
    select count(*) into v_count
    from WHOP.QADB_QUESTIONS
    where question_category = 'Carton'
    and question_active_flag = 'Y';
         exception
         when no_data_found then
         v_count := 0;
    end;
    if v_count > 0 then
    for car_r in car_c loop
    ---populating carton questions
    :la_carton.carton_question_id     := car_r.question_id;
    :la_carton.carton_question_answer     := 'N';
    :la_carton.carton_error_details     := null;
    :la_carton.attribute2          := car_r.question_description;
    end loop;
    end if;
    end;
    Thanks in advance.
    Regards,
    Jun

    Hi SNatapov,
    Thanks for you reply but still I get this error...
    FRM-40737 Illegal restricted procedure GO_BLOCK in WHEN-VALIDATE-ITEM trigger.
    Please note that I call that program unit in the last field of my control block inside when-validate-item trigger the questions should be display in la_carton block which is my non-base table block.
    Find below is the code....
    begin
    go_block('la_carton');
    first_record;
    for car_r in car_c loop
    ---populating carton questions
    :la_carton.carton_question_id := car_r.question_id;
    :la_carton.carton_question_answer := 'N';
    :la_carton.carton_error_details := null;
    :la_carton.attribute2 := car_r.question_description;
    next_record;
    end loop;
    end;
    Hoping you can help me this problem...
    Thanks in advance.
    Regards,
    Jun

  • How to identify migrated rows on a table

    Hi, folks,
    I'm wondering how to identify migrated rows on a table.
    I understand that ANALYZE generates data into CHAINED_ROWS. The Oracle document implies that this table has both CHAINED ROWS and MIGRATED ROWS. FYI:
    http://download-west.oracle.com/docs/cd/B19306_01/server.102/b14231/general.htm#sthref1881
    But how can I tell migrated rows from chained rows.
    Thanks!
    Alex

    im also not looking to ExporttoExcel feature on ADF just copy all the records displayed on a table
    im also not looking to ExporttoExcel feature on ADF just copy all the records displayed on a table ,
    Hi you can set the property( exportedRows) of exportListener
    you can limit the number of rows to download
    chekout documentaion
    ADF RichClient API - af:exportCollectionActionListener

  • How to compare two rows from two table with different data

    how to compare two rows from two table with different data
    e.g.
    Table 1
    ID   DESC
    1     aaa
    2     bbb
    3     ccc
    Table 2
    ID   DESC
    1     aaa
    2     xxx
    3     ccc
    Result
    2

    Create
    table tab1(ID
    int ,DE char(10))
    Create
    table tab2(ID
    int ,DE char(10))
    Insert
    into tab1 Values
    (1,'aaa')
    Insert
    into tab1  Values
    (2,'bbb')
    Insert
    into tab1 Values(3,'ccc')
    Insert
    into tab1 Values(4,'dfe')
    Insert
    into tab2 Values
    (1,'aaa')
    Insert
    into tab2  Values
    (2,'xx')
    Insert
    into tab2 Values(3,'ccc')
    Insert
    into tab2 Values(6,'wdr')
    SELECT 
    tab1.ID,tab2.ID
    As T2 from tab1
    FULL
    join tab2 on tab1.ID
    = tab2.ID  
    WHERE
    BINARY_CHECKSUM(tab1.ID,tab1.DE)
    <> BINARY_CHECKSUM(tab2.ID,tab2.DE)
    OR tab1.ID
    IS NULL
    OR 
    tab2.ID IS
    NULL
    ID column considered as a primary Key
    Apart from different record,Above query populate missing record in both tables.
    Result Set
    ID ID 
    2  2
    4 NULL
    NULL 6
    ganeshk

  • Display distinct rows from Oracle table without using "DISTINCT" keyword.

    How to retrieve distinct rows from oracle table without using 'DISTINCT' keyword in SQL?
    Thanks in advance.
    Mihir

    Welcome to the forum.
    Besides GROUP BY you can use UNIQUE instead of DISTINCT as well, but that's probably not wanted here ;) , and the ROW_NUMBER() analytic:
    SQL> create table t as
      2  select 1 col1 from dual union all
      3  select 1 from dual union all
      4  select 2 from dual union all
      5  select 3 from dual union all
      6  select 4 from dual union all
      7  select 4 from dual;
    Table created
    SQL> select col1 from t;
          COL1
             1
             1
             2
             3
             4
             4
    6 rows selected
    SQL> select distinct col1 from t;
          COL1
             1
             2
             3
             4
    SQL> select unique col1 from t;
          COL1
             1
             2
             3
             4
    SQL> select col1 from t group by col1;
          COL1
             1
             2
             3
             4
    SQL> select col1
      2  from ( select col1
      3         ,      row_number() over (partition by col1 order by col1) rn
      4         from   t
      5       )
      6  where rn=1;
          COL1
             1
             2
             3
             4

  • How to display all rows in the report in one page in Oracle APEX 3.2

    Friends -
    We are using Oracle Applications Express 3.2 on oracle database 10.2.0.5 on solaris environment.
    One of our report contains total no of rows 50000. when we ran report by default it is showing 15 and i can go search and change display no of rows to different numbers and click go.
    My question is it possible to display all 50000 rows during first time report launching without going to change rows. Is there any option that we can set how many number of rows that we can display during report design.
    Please advise
    VSH

    Hello VSH,
    >> My question is it possible to display all 50000 rows during first time report launching without going to change rows
    As vee pointed out it is possible, however the question you need to ask yourself is is it wise?
    Bear in mind that displaying 50,000 rows on a single HTML page means a lot of code that must be loaded by the client browser all at once. What it will do to your page loading time? Browser memory? Network bandwidth? Also, do you really believe that it is effective to let an end user look for a specific row among 50,000 rows?
    Regards,
    Arie.
    &diams; Please remember to mark appropriate posts as correct/helpful. For the long run, it will benefit us all.
    &diams; Author of Oracle Application Express 3.2 – The Essentials and More

  • How to display 30 rows in a report

    Hi
    I am using apex.oracle.com to Generate one report.
    report contains 30 rows and tried alot to display all rows without clicking next.
    how i can get this.
    thanx in advance.
    Chanran

    Thanx for your reply mini,
    i am showing some settings in report attributes
    report template  template:1.standard
    pagination scheme -mo pagination selected-
    enable partial page refresh yes
    display point bottom right
    number of rows 20
    but this is not working same problem i am facing
    regards
    Chanran
    Edited by: Chandu on 19-Oct-2011 06:37

  • OBIEE - answers - How to display to rows in one?

    I have problem with QA_RESULTS table - exactly with correct display results
    How can I display two rows in one?
    Example:
    data 1, name
    2009-03-01, john
    2009-03-05, john
    2009-03-02, ann
    2009-03-04, ann
    I would like to see:
    data 1, name , data 2
    2009-03-01, john , 2003-03-05
    2009-03-02, ann , 2009-03-04
    Regards,
    js

    hi..
    i don't think this can be done..
    but try to put the name column in first place and in column properties mention suppression values.. as it won't repeat the values for each row...
    keep your date column in second position.
    so that it appears like.. for each name there would be 2 dates up and down
    just try...

Maybe you are looking for

  • Black background behind icons

    My husband upgraded my 3GS iPhone to OS 4 and now my photo is behind my icons. I don't like the way this looks as it makes it hard for me to differentiate my icons from the photo. How can I get the plain black background back? I liked being able to s

  • Getting ORA-00600, CSS-00152, CSS-00120 When Using csscan

    I am getting this error when running CSScan. The solution in metalink says to purge recycle bin. Is this the windows recycle bin or some oracle's internal recycle bin. Purging windows recycle bin did not help. https://metalink.oracle.com/metalink/pls

  • Po rel. strategy

    Hi, In p.o rel. strategy we have the three stage release status. First  A( say) will rel. then B then C. we have released  lot of p.o in the same manner. Now we want to change the rel.status to two step. That means A will release then B will rel.the

  • I download ios8 I can't use my song for ringtone and other ringtone it is not loud and I miss call

    I Download ISO 8 and I can't use the song for my ringtone , but it vibrate and I can't hear the phone rings . Other ringtone it is not loUd

  • BizTalk EDI Diassembler Pipeline Issue.

    Hi All, I am using BizTalk EDI Pipeline to diassemble an input EDIFACT D93A message. The message has IMD(Item Description) segment with a space between (: and Cream bar)like below and it is failing in the validation. IMD+F++::: Cream Bar soap 4-pk' Q