Select columns order by

Hi,
my table is exg(phone_no,com_date)
Records are like
1111 01-oct-2004
2222 01-oct-2004
3333 02-oct-2004
1111 05-oct-2004
1111 08-oct-2004
3333 09-oct-2004
Is there any select qeuery to get the report like
1111 01-oct-2004
1111 05-oct-2004
1111 08-oct-2004
3333 02-oct-2004
3333 09-oct-2004
2222 01-oct-2004
Regards
balu

I agree with Andrew, it is not clear what you are trying to do here, but this replicates your desired output given your sample data.
SQL> SELECT * FROM exg
  2  ORDER BY mod(phone_no,2) desc, phone_no, com_date;
  PHONE_NO COM_DATE
      1111 01-Oct-2004
      1111 05-Oct-2004
      1111 08-Oct-2004
      3333 02-Oct-2004
      3333 09-Oct-2004
      2222 01-Oct-2004
6 rows selected.TTFN
John

Similar Messages

  • Report Does Not Follow Select Column Order

    Hi all,
    Apex 2.2 on 10gXE
    I always encounter this problem, the display column on report does not follow the select column sequence order in the "region source".
    It is very tedious clicking the up/down arrow one-by-one in the "report attributes" especially if the display columns are plenty like 40 columns.
    Is there a fix/patch or alternative tips for this bug?
    Thanks a lot,
    Edited by: 843228 on May 24, 2011 10:32 PM

    Apex 2.2 on 10gXEStart by upgrading from this old unsupported version.
    >
    I always encounter this problem, the display column on report does not follow the select column sequence order in the "region source".
    It is very tedious clicking the up/down arrow one-by-one in the "report attributes" especially if the display columns are plenty like 40 columns.
    Is there a fix/patch or alternative tips for this bug?
    >
    This is not a bug. APEX maintains the original column order of the report. This avoids problems downstream in areas like the processing of <tt>g_fnn</tt> arrays in declarative tabular forms, where the assigned arrays are column-order dependent.
    APEX 4.x fixes column ordering bugs that could lead to report corruption, and includes drag-and-drop column ordering in the new tree view in addition to the up/down arrow re-ordering.
    If you really want column order to follow that in the source query, the workaround is to create a new report using the modified query.

  • Select * columns order

    Is it possible, that "SELECT *" returns records, where columns are
    ordered in a different order, than the order they were
    positioned/specified when table was created?
    For example, lets assume that table T contains columns c1,c2,..c10.
    Can this be possible, that the * (asterisk) shows the columns in a
    different orderm the c1 and c10 changed their position for example:
    query:
    "SELECT * FROM T"
    results:
    c10, c2, c3, .., c9, c1.
    I think you anderstood my question now.
    The sql-standard doesn't tell about it nothing, but i have heard that
    "selesct *" can produce columns in a random order in some situations.
    Notice, that i'm not talking about "ORDER"-operator. I have heard that if one make a table with plenty of columns and adds plenty of indexes and constraints to the columns, then "select *" really will produce mistery column order.
    Thank you for answering,
    Regards.

    FWIW I suspect that block structure is not a factor either.
    Consider
    SQL> CREATE VIEW v AS SELECT * FROM emp;
    View created.
    SQL> desc emp
    Name                          Null?    Type
    EMPNO                         NOT NULL NUMBER(4)
    ENAME                                  VARCHAR2(10)
    JOB                                    VARCHAR2(9)
    MGR                                    NUMBER(4)
    HIREDATE                               DATE
    SAL                                    NUMBER(7,2)
    COMM                                   NUMBER(7,2)
    DEPTNO                                 NUMBER(2)
    SQL> desc v
    Name                          Null?    Type
    EMPNO                         NOT NULL NUMBER(4)
    ENAME                                  VARCHAR2(10)
    JOB                                    VARCHAR2(9)
    MGR                                    NUMBER(4)
    HIREDATE                               DATE
    SAL                                    NUMBER(7,2)
    COMM                                   NUMBER(7,2)
    DEPTNO                                 NUMBER(2)
    SQL> WITH accounting_emp  AS (SELECT * FROM v WHERE deptno = 10)
      2     , accounting_dept AS (SELECT * FROM dept WHERE deptno = 10)
      3  SELECT *
      4  FROM   ( SELECT * FROM accounting_dept )
      5*      , ( SELECT * FROM accounting_emp );
    DEPTNO DNAME          LOC           EMPNO ENAME      JOB         MGR HIREDATE    SAL  COMM DEPTNO
        10 ACCOUNTING     NEW YORK       7782 CLARK      MANAGER    7839 09-JUN-81  2450           10
        10 ACCOUNTING     NEW YORK       7839 KING       PRESIDENT       17-NOV-81  5000           10
        10 ACCOUNTING     NEW YORK       7934 MILLER     CLERK      7782 23-JAN-82  1300           10
    3 rows selected.This returns rows in a consistent (if apparently undocumented) order, which seems to be something like:
    * Tables/views in FROM list
    * SELECT list
    * SELECT list within views in FROM list
    * SELECT list of subquery factoring clause
    * ALL_TAB_COLUMNS.COLUMN_ID (for tables and views)
    * ALL_TYPE_ATTRS.ATTR_NO for attributes of object types
    If it did not, it would break many valid PL/SQL constructions as others have mentioned, including %ROWTYPE , UPDATE ... SET ROW, INSERT ... VALUES [record], and INSERT without column list. This type of failure will be familiar to those developing invoker rights packages, since the table found at runtime could have columns in a different order than the one compiled against, which will produce effects such as values appearing in the wrong attributes of %ROWTYPE records.

  • Column order in a select * query

    Suppose I have 256 columns in a table and if I query select * from  tablename ,what will the column order in the result.Will this be always same as order as in created statement?

    If the columns were all in the original CREATE TABLE statement, then, yes, the ordering of columns in SELECT * FROM will match the order from the CREATE TABLE statement.
    If columns were added after the initial create, then the original columns will come first (in their order) and then the added columns (in their order), etc.
    In the real world, it is a very bad practice to use SELECT * and have expectations about the ordering of the columns. Consider this scenario:
    Table T was created and implemented in production a year ago with columns A, B, C
    A project started up three months ago and added column D but the project is stalled in development. So in development T had columns A, B, C, D
    Later, another project started up and added columns E and F. Unlike the other project, it has progressed to Test. and Production. So in Development the table has columns A, B, C, D, E, F. In test and production the table has columns A, B, C, E, F.
    Now that stuck project has progressed to Test and Production. Now T has columns A, B, C, E, F, D in test and production but still A, B, C, D, E, F in development.
    Until someone notices and decides to fix it (where and how?)
    Be very, very careful about using SELECT *.

  • How can i give a parameter to user to select the column order in runtime

    Select * from emp  ;
    in parameter form for i need to create a parameter so the user can select whatever the column order he required.
    where is should write the order by clause

    Hi,
    In Reports Use Lexical Parameter instead of Bind Parameter and write order by in After Param Form...
    Here you find more details...
    https://forums.oracle.com/thread/669325
    Hope this will solve your issue..
    Regards,
    Soofi

  • How to set the column order of a sealed column in a custom Content Type for the new item form NewDocSet.aspx?

    Dear SharePoint Developers,
    Please help.
    I need to know How to set the column order of a sealed column in a custom Content Type for the new item form NewDocSet.aspx?
    I think this is a "sealed column", whatever that is, which is  shown in SPD 2013 as a column of content type "document, folder, MyCustomContentType".
    I know when I set the column order in my custom Content Type settings page, it is correct.
    But, when I load the NewDocSet.aspx page, the column order that I set in the settings page is NOT used for this "sealed column" which is bad.
    Can you help?
    Please advise.
    Thanks.
    Mark Kamoski
    -- Mark Kamoski

    Hi,
    According to your post, my understanding is that you want to set the column order of a sealed column in a custom Content Type for the new item form NewDocSet.aspx.
    Per my knowledge, if you have Content Type management enabled for the list or library (if you see a list of content type with the option to add more), the display order of columns is set for each content type.
    Drill down into one of them and you'll see the option under the list of columns for that content type.
    To apply the column order in the NewDocSet.aspx page, you need to:
    Select Site Settings, under Site Collection Administration, click Content type publishing. In the Refresh All Published
    Content Types section, choose Refresh all published content types on next
    update.
    Run two timer jobs(Content Type Hub, Content Type Subscriber) in central admin(Central Administration--> Monitoring--> Review timer jobs).
    More information:
    http://sharepoint.stackexchange.com/questions/95028/content-types-not-refreshing-on-sp-online
    Best Regards,
    Linda Li
    Linda Li
    TechNet Community Support

  • Is that important column order in a query with row_number function

    Hi folks,
    I am using Oracle 11g R2 on HP-UX machine.
    I have 2 types of query with row_number and I think they are same but output of each of them are different. I changed only column order in query2.
    Query 1 :
    (SELECT
    "LOOKUP_INPUT_SUBQUERY"."CONTRACT_SK" "CONTRACT_SK",
    "LOOKUP_INPUT_SUBQUERY"."SIMCARD_SK" "SIMCARD_SK"
    FROM (
    SELECT row_number ()
    OVER (
    PARTITION BY "R_CON_SUBS_SIMCARD_LK".
    "CONTRACT_SK"
    ORDER BY
    "R_CON_SUBS_SIMCARD_LK"."START_DATE" DESC,
    "R_CON_SUBS_SIMCARD_LK"."SEQ_NUM" DESC NULLS LAST) /* EXPRESSION_3.OUTGRP1.SIRA */
    "SIRA",
    "R_CON_SUBS_SIMCARD_LK"."CONTRACT_SK" "CONTRACT_SK",
    "R_CON_SUBS_SIMCARD_LK"."SIMCARD_SK" "SIMCARD_SK"
    FROM "SRC_OZRDS"."R_CON_SUBS_SIMCARD_LK" "R_CON_SUBS_SIMCARD_LK")
    "LOOKUP_INPUT_SUBQUERY"
    WHERE ("LOOKUP_INPUT_SUBQUERY"."SIRA" = 1))
    Output of this like that :
    CONTRACT_SK SIMCARD_SK
    1     1
    1     3
    1     4
    1     5
    1     6
    1     11
    1     12
    1     14
    1     15
    1     16
    Query 2 :
    (SELECT
    "LOOKUP_INPUT_SUBQUERY"."CONTRACT_SK" "CONTRACT_SK",
    "LOOKUP_INPUT_SUBQUERY"."SIMCARD_SK" "SIMCARD_SK"
    FROM (
    SELECT
    "R_CON_SUBS_SIMCARD_LK"."CONTRACT_SK" "CONTRACT_SK",
    "R_CON_SUBS_SIMCARD_LK"."SIMCARD_SK" "SIMCARD_SK",
    row_number ()
    OVER (
    PARTITION BY "R_CON_SUBS_SIMCARD_LK".
    "CONTRACT_SK"
    ORDER BY
    "R_CON_SUBS_SIMCARD_LK"."START_DATE" DESC,
    "R_CON_SUBS_SIMCARD_LK"."SEQ_NUM" DESC NULLS LAST) /* EXPRESSION_3.OUTGRP1.SIRA */
    "SIRA"
    FROM "SRC_OZRDS"."R_CON_SUBS_SIMCARD_LK" "R_CON_SUBS_SIMCARD_LK")
    "LOOKUP_INPUT_SUBQUERY"
    WHERE ("LOOKUP_INPUT_SUBQUERY"."SIRA" = 1))
    Output of this like that:
    2     874812
    7     70097256
    8     18734091
    9     158024
    10     815397739
    13     22657919
    19     83177779
    20     82579529
    22     5829949
    23     35348926
    25     3865978
    I expected the second output, because there are lots of contract sk but there is one contract_sk in first query result. i did not get the point. What is the problem ?

    user8649469 wrote:
    I changed only column order in query2.So what else do you expect? If you order, for example, by last name, fist name don't you think rows will be returned in a different order (and therefore same row will have different row number) than ordering by first name, last name?
    SY.

  • Column order in SQL Query (PL/SQL function returning a query)

    Hi,
    when I define a PL/SQL function returning a query inside a region, I often find that the column order is arbitrarily changed.
    How do I enforce the column order ?
    Bye,
    Flavio

    I removed the 11th column called service_name from this dynamic query: and now the report says: report error:
    ORA-01403: no data found. I messed around with the Headiuns Type. It was set to Custom. I changed it to Column Names. There is no difference.
    I am not sure how to fix?
    declare topqry varchar2(32000);
    whereqry varchar2(32000);
    finalqry varchar2(32000);
    var_status varchar2(100);
    division_status varchar2(50);
    office_status varchar2(1000);
    user_status varchar2(1000);
    overdue_status varchar2(1000);
    begin
    if :P10_FALLBACK = 'All' then
    var_status:= ' and vp.status in (''FA'',''FBA'',''FBI'',''25%'',''50%'',''90%'',''Closed'') ';
    elsif :P10_FALLBACK = 'Active' then
    var_status:= ' and vp.status in (''FA'',''25%'',''50%'',''90%'',''FBA'') ';
    elsif :P10_FALLBACK = 'FB' then
    var_status:= ' and vp.status in (''FBA'',''FBI'') ';
    elsif :P10_FALLBACK = 'Closed' then
    var_status:= ' and vp.status in (''Closed'') ';
    elsif :P10_FALLBACK = 'Inactive' then
    var_status:= ' and vp.status in (''FBI'') ';
    end if;
    if :P10_DIVISION = 'All' then
    division_status:= ' and vp.vms_division in (''News'',''Ad Services'') ';
    elsif :P10_DIVISION = 'News' then
    division_status:= ' and vp.vms_division in (''News'') ';
    elsif :P10_DIVISION = 'Ad' then
    division_status:= ' and vp.vms_division in (''Ad Services'') ';
    end if;
    if :P10_OFFICE = '%' then
    office_status:= ' and OFFICE_ID in (select office
    from VMS_OFFICE_ACCESS
    where user_id = lower(:P0_user) ) ';
    else
    office_status:= ' and OFFICE_ID in :P10_OFFICE ';
    end if;
    if :P10_LIMIT_USER = '%' then
    user_status := ' and SALESPERSON in (select first_name || '' '' || last_name
    from VMS_PROSPECT_users u
    join vms_office_access o
    on u.office_id = OFFICE
    where o.user_id = lower(:P0_USER) ) ';
    else
    user_status:= ' and SALESPERSON in (:P10_LIMIT_USER ) ';
    end if;
    if :P10_SHOW_OVERDUE = 'Show' then
    overdue_status:= ' and target_close_date <= sysdate ';
    var_status:= ' and vp.status in (''25%'',''50%'',''90%'',''FBA'') ';
    else
    overdue_status:= ' and FIRST_APPOINTMENT between
    nvl(to_date(:P10_FIRST_APPT_START, ''mm/dd/yyyy''),FIRST_APPOINTMENT) and
    nvl(to_date(:P10_FIRST_APPT_END,''mm/dd/yyyy''),FIRST_APPOINTMENT) ';
    end if;
    topqry := 'SELECT OFFICE_ID ,vp.PROSPECT_ID ,ENTRY_DATE ,ACCOUNT , NEXT_CONTACT_DATE ,ACTION_STEP ,
    TARGET_CLOSE_DATE ,vp.STATUS ,SALESPERSON ,vp.SALES_TYPE ,service_name , FIRST_APPOINTMENT ,MODIFY_DATE ,EST_ANNUAL_REVENUE ,EST_INCREMENTAL_REVENUE ,
    pi.NOTES , pi.SALES_TYPE ,pi.STATUS ,Contact ,Origin_Source FROM VMS_PROSPECTING_ITEMS pi right outer join VMS_PROSPECTS vp on vp.PROSPECT_ID = pi.PROSPECT_ID left outer join VMS_SERVICES vs on vs.service_ID = pi.service_ID where 1 = 1 ';
    whereqry := ' and (not exists (select *
    from VMS_PROSPECTING_ITEMS i3
    where vp.prospect_id = i3.prospect_id)
    or exists (select *
    from VMS_PROSPECTING_ITEMS i2
    where i2.order_id = pi.order_id
    and active = ''Y'' )) and instr(upper(ACCOUNT),upper(nvl(:P10_ACCOUNT,ACCOUNT))) > 0 ';
    whereqry := whereqry || var_status || division_status || office_status || user_status || overdue_status;
    finalqry := topqry || whereqry;
    return finalqry ;
    end;

  • Select columns from table for display in alvgrid.

    Hi all,
    i have the following:
    i do select a tablename and pass it as a parameter. then this table is loaded into an internal table and displayed in an alv-grid.
    what i now want to do is a step  between the both:
    after the internal table with its structure is loaded, i want to display the field columns and i want them to be selectable so that in the next step the alv - grid is selected only with the selected columns ( just now it allways runs with all columns - even the not needed ).
    Any ideas for that would be appreciated. Is there some tutorial on that or some sample ?

    hi
    chk this sample code:
    *REPORT  zdemo_alvgrid                 .
    TABLES:     ekko.
    type-pools: slis.                                 "ALV Declarations
    *Data Declaration
    TYPES: BEGIN OF t_ekko,
      ebeln TYPE ekpo-ebeln,
      ebelp TYPE ekpo-ebelp,
      statu TYPE ekpo-statu,
      aedat TYPE ekpo-aedat,
      matnr TYPE ekpo-matnr,
      menge TYPE ekpo-menge,
      meins TYPE ekpo-meins,
      netpr TYPE ekpo-netpr,
      peinh TYPE ekpo-peinh,
    END OF t_ekko.
    DATA: it_ekko TYPE STANDARD TABLE OF t_ekko INITIAL SIZE 0,
          wa_ekko TYPE t_ekko.
    *ALV data declarations
    data: fieldcatalog type slis_t_fieldcat_alv with header line,
          gd_tab_group type slis_t_sp_group_alv,
          gd_layout    type slis_layout_alv,
          gd_repid     like sy-repid,
          gt_events     type slis_t_event,
          gd_prntparams type slis_print_alv.
    *Start-of-selection.
    START-OF-SELECTION.
    perform data_retrieval.
    perform build_fieldcatalog.
    perform build_layout.
    perform build_events.
    perform build_print_params.
    perform display_alv_report.
    *&      Form  BUILD_FIELDCATALOG
          Build Fieldcatalog for ALV Report
    form build_fieldcatalog.
    There are a number of ways to create a fieldcat.
    For the purpose of this example i will build the fieldcatalog manualy
    by populating the internal table fields individually and then
    appending the rows. This method can be the most time consuming but can
    also allow you  more control of the final product.
    Beware though, you need to ensure that all fields required are
    populated. When using some of functionality available via ALV, such as
    total. You may need to provide more information than if you were
    simply displaying the result
                  I.e. Field type may be required in-order for
                       the 'TOTAL' function to work.
      fieldcatalog-fieldname   = 'EBELN'.
      fieldcatalog-seltext_m   = 'Purchase Order'.
      fieldcatalog-col_pos     = 0.
      fieldcatalog-outputlen   = 10.
      fieldcatalog-emphasize   = 'X'.
      fieldcatalog-key         = 'X'.
    fieldcatalog-do_sum      = 'X'.
    fieldcatalog-no_zero     = 'X'.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'EBELP'.
      fieldcatalog-seltext_m   = 'PO Item'.
      fieldcatalog-col_pos     = 1.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'STATU'.
      fieldcatalog-seltext_m   = 'Status'.
      fieldcatalog-col_pos     = 2.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'AEDAT'.
      fieldcatalog-seltext_m   = 'Item change date'.
      fieldcatalog-col_pos     = 3.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'MATNR'.
      fieldcatalog-seltext_m   = 'Material Number'.
      fieldcatalog-col_pos     = 4.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'MENGE'.
      fieldcatalog-seltext_m   = 'PO quantity'.
      fieldcatalog-col_pos     = 5.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'MEINS'.
      fieldcatalog-seltext_m   = 'Order Unit'.
      fieldcatalog-col_pos     = 6.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'NETPR'.
      fieldcatalog-seltext_m   = 'Net Price'.
      fieldcatalog-col_pos     = 7.
      fieldcatalog-outputlen   = 15.
      fieldcatalog-datatype     = 'CURR'.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
      fieldcatalog-fieldname   = 'PEINH'.
      fieldcatalog-seltext_m   = 'Price Unit'.
      fieldcatalog-col_pos     = 8.
      append fieldcatalog to fieldcatalog.
      clear  fieldcatalog.
    endform.                    " BUILD_FIELDCATALOG
    *&      Form  BUILD_LAYOUT
          Build layout for ALV grid report
    form build_layout.
      gd_layout-no_input          = 'X'.
      gd_layout-colwidth_optimize = 'X'.
      gd_layout-totals_text       = 'Totals'(201).
    gd_layout-totals_only        = 'X'.
    gd_layout-f2code            = 'DISP'.  "Sets fcode for when double
                                            "click(press f2)
    gd_layout-zebra             = 'X'.
    gd_layout-group_change_edit = 'X'.
    gd_layout-header_text       = 'helllllo'.
    endform.                    " BUILD_LAYOUT
    *&      Form  DISPLAY_ALV_REPORT
          Display report using ALV grid
    form display_alv_report.
      gd_repid = sy-repid.
      call function 'REUSE_ALV_GRID_DISPLAY'
           exporting
                i_callback_program      = gd_repid
                i_callback_top_of_page   = 'TOP-OF-PAGE'  "see FORM
                i_callback_user_command = 'USER_COMMAND'
               i_grid_title           = outtext
                is_layout               = gd_layout
                it_fieldcat             = fieldcatalog[]
               it_special_groups       = gd_tabgroup
                it_events               = gt_events
                is_print                = gd_prntparams
                i_save                  = 'X'
               is_variant              = z_template
           tables
                t_outtab                = it_ekko
           exceptions
                program_error           = 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.
    endform.                    " DISPLAY_ALV_REPORT
    *&      Form  DATA_RETRIEVAL
          Retrieve data form EKPO table and populate itab it_ekko
    form data_retrieval.
    select ebeln ebelp statu aedat matnr menge meins netpr peinh
    up to 10 rows
      from ekpo
      into table it_ekko.
    endform.                    " DATA_RETRIEVAL
    Form  TOP-OF-PAGE                                                 *
    ALV Report Header                                                 *
    Form top-of-page.
    *ALV Header declarations
    data: t_header type slis_t_listheader,
          wa_header type slis_listheader,
          t_line like wa_header-info,
          ld_lines type i,
          ld_linesc(10) type c.
    Title
      wa_header-typ  = 'H'.
      wa_header-info = 'EKKO Table Report'.
      append wa_header to t_header.
      clear wa_header.
    Date
      wa_header-typ  = 'S'.
      wa_header-key = 'Date: '.
      CONCATENATE  sy-datum+6(2) '.'
                   sy-datum+4(2) '.'
                   sy-datum(4) INTO wa_header-info.   "todays date
      append wa_header to t_header.
      clear: wa_header.
    Total No. of Records Selected
      describe table it_ekko lines ld_lines.
      ld_linesc = ld_lines.
      concatenate 'Total No. of Records Selected: ' ld_linesc
                        into t_line separated by space.
      wa_header-typ  = 'A'.
      wa_header-info = t_line.
      append wa_header to t_header.
      clear: wa_header, t_line.
      call function 'REUSE_ALV_COMMENTARY_WRITE'
           exporting
                it_list_commentary = t_header.
               i_logo             = 'Z_LOGO'.
    endform.
          FORM USER_COMMAND                                          *
          --> R_UCOMM                                                *
          --> RS_SELFIELD                                            *
    FORM user_command USING r_ucomm LIKE sy-ucomm
                      rs_selfield TYPE slis_selfield.
    Check function code
      CASE r_ucomm.
        WHEN '&IC1'.
      Check field clicked on within ALVgrid report
        IF rs_selfield-fieldname = 'EBELN'.
        Read data table, using index of row user clicked on
          READ TABLE it_ekko INTO wa_ekko INDEX rs_selfield-tabindex.
        Set parameter ID for transaction screen field
          SET PARAMETER ID 'BES' FIELD wa_ekko-ebeln.
        Sxecute transaction ME23N, and skip initial data entry screen
          CALL TRANSACTION 'ME23N' AND SKIP FIRST SCREEN.
        ENDIF.
      ENDCASE.
    ENDFORM.
    *&      Form  BUILD_EVENTS
          Build events table
    form build_events.
      data: ls_event type slis_alv_event.
      call function 'REUSE_ALV_EVENTS_GET'
           exporting
                i_list_type = 0
           importing
                et_events   = gt_events[].
      read table gt_events with key name =  slis_ev_end_of_page
                               into ls_event.
      if sy-subrc = 0.
        move 'END_OF_PAGE' to ls_event-form.
        append ls_event to gt_events.
      endif.
        read table gt_events with key name =  slis_ev_end_of_list
                               into ls_event.
      if sy-subrc = 0.
        move 'END_OF_LIST' to ls_event-form.
        append ls_event to gt_events.
      endif.
    endform.                    " BUILD_EVENTS
    *&      Form  BUILD_PRINT_PARAMS
          Setup print parameters
    form build_print_params.
      gd_prntparams-reserve_lines = '3'.   "Lines reserved for footer
      gd_prntparams-no_coverpage = 'X'.
    endform.                    " BUILD_PRINT_PARAMS
    *&      Form  END_OF_PAGE
    form END_OF_PAGE.
      data: listwidth type i,
            ld_pagepos(10) type c,
            ld_page(10)    type c.
      write: sy-uline(50).
      skip.
      write:/40 'Page:', sy-pagno .
    endform.
    *&      Form  END_OF_LIST
    form END_OF_LIST.
      data: listwidth type i,
            ld_pagepos(10) type c,
            ld_page(10)    type c.
      skip.
      write:/40 'Page:', sy-pagno .
    endform.
    **reward if helpful
    regards,
    madhu

  • Interactive report column order not working properly

    Hi All,
    Can anyone help me with this situation:
    Example:
    1)
    First of all I created a interactive report with this simple query
    Select 1 col_A, 2 Col_D from dual
    2)Later I modified the query like this
    Select 1 col_A, 1 col_C, 2 Col_D from dual
    But when I run the report the new column added appear in the end?
    I already tryed to reorganize the column order in the navigator menu, but the issue remains.
    Any ideas?
    Thanks

    Hi,
    Login to APEX builder. Run your page.
    Select columns from report action menu and save default layout.
    Regards,
    Jari

  • Strange graphical glitch in Select Columns

    I've noticed a strange graphical glitch in the Select Columns region of an interactive report when using IE7 or 8.
    When a column is selected (other than the first or last) and sent to the Bottom or Top the change doesn't actually show until the mouse is moved over the Display in Report List. If the Apply button is clicked, then the column ordering is set correctly.
    I'm using Apex 3.1 and was wondering if anyone else has noticed.
    Thanks,
    Simon

    alright.. once again a nvidia isssue... the nv driver does paint it correctly

  • BUG: SQL Developer 1.5.3 CSV export column order broken

    There's a bug in the 1.5.3 release of SQL Developer regarding data export. This bug re-orders the column order in the data export to be alphabetically sorted. This produces mangled CSV files if used on a table or a view.
    This is a critical bug to me since I need to produce lots of ad-hoc data CSV export files. I'm staying with SQL Developer 1.5.0.53 (53.38) for now as it doesn't have this problem.
    This is the same bug as present in Jdeveloper 11.1 as described in my post here: BUG: Jdev 11.1.1.0.0 -- DB table data export column order is not preserved
    Quoted from that post:
    When I connect to Oracle database, get the table list, right click on the table and select 'Export Data'->csv. The dialog box opens with three tabs: Format, Columns, Where. The column order displayed in both tabs Columns and Where is alphabetic. Because alphabetic ordering re-arranges columns from their initial ordering in the table, this screws up CSV export because columns are not in their intended order. This same problem occurs when I try to export data from views to generate a CSV file with a particular column order.
    Please open/check bug report if it's already open.
    Thanks!

    This happens with all of the export options for tables or views if you right click from the connections tab table list. If I pull it up in the main window and go to the data tab, I can then right click and it will keep the column id order for some of the views and tables. But not all.
    I am running 1.5.3 Build Main 5783 on a Windows XP Professional Service Pack 3 platform

  • How to make a field under Selection column in DataSource from dimmed to ...

    We try to make an InfoObject shows up in Data Selection of an InfoPackage to restrict the data load based on the range of this InfoObject.  In order to do this, we will have to go to the source system to run RSA6 to edit the datasource to make this field checked under the Selection column.  However when we get to the screen, find this field's Selection column is dimmed.  Is there anyway to make it from dimmed to editable that it can be checked?
    Thanks

    hi Kevin,
    try to check table ROOSFIELD, fill OLTPSOURCE with your datasource name and OBJVERS 'A', what's the value for SELECTION ? you may change the value with 'X'.
    use abap code :
    UPDATE ROOSFIELD SET   SELECTION = 'X'
                   WHERE OLTPSOURCE   = 'datasource name'   AND OBJVERS = 'A'.
    can i know your datasource name (if it's business content) ?
    Properties of a DataSource Field
    If a request for a DataSource is scheduled in the Business Information Warehouse, selection conditions are specified across certain fields. The property that determines whether a selection in BW using a field
    is possible or required is established in the DataSource in the Source System.
    In addition, the visibility of the field in BW can be set.
    A field that is not visible (or that is hidden) cannot be transferred into the transfer structure.
    Definition of the individual values:
    'A': Field is hidden in OLTP and BW, property cannot be changed  the customer.
    'M': The DataSource requires a selection across this field before it is able to extract data (Required field for the generation of a request); property cannot be changed by the customer
    'X': The Data Source can select across this field. The customer can change selections and visibility (the field is currently visible and selectable, compare with 'P', '3')
    '1': Pure selection field for the DataSource. The customer can change the selection, but not the visibility (the field is currently selectable , compare with '2').
    '2': Pure selection field for the DataSource. The customer can change the selection, but not the visibility (field is currently no selectable, compare with '1').
    '3': The DataSource can select across this field. The customer can change selection and visibility (the field is currently not visible not selectable, compare with 'P', 'X')
    '4': The DataSource cannot select across this field. The customer can change visibility (the field is currently not visible, compare with ' ')

  • Design a single template for multiple reports with different column order

    Hi,
    I need to migrate the existing reports from SQL Server Reporting Services to Crystal Report 2008, and the column order in the report is very important to the clients since clients have existing code to ingest these reports into their database. Now I want to create a single template with lot of parameters for all reports. My question is how I might use one template to create multiple reports with different column orders in the reports?
    For example, client A has the following column order in their report: firstName, LastName, DateBirth, SSN. Client B has the following column order in their report: SSN, DateBirth, LastName, FirstName. Can I use one template to create these multiple reports?
    Thanks in advance.

    -As I mentioned you can find Template Field object in Insert menu of crystal report Designer 2008.
    As soon as you select Template Field object you will be able to see a box beside ur mouse cursor. Drag and drop this box at required place. Now when you place this object in report you will get some thing like this "<TemplateField1>" listed under Formula Fields tree. Double click "<TemplateField1>" formula to add your conditions.
    -I have not tested it for large amount of Customers. However as the number of customer increases the number of conditions will get increased.
    For the customer that want the same ordering of columns you can put those customers under one condition.
        for Example...
              if(?Client in ['clientA','clientA']) then
                        <TableName>.<Field>......
    -What do you mean be 40 columns? Do you mean 40 fields or you want to show 40 columns in report? Please elaborate.
    Regards,
    Amrita
    Edited by: Amrita Singh on May 21, 2009 7:54 AM

  • Changed column order not applied to interactive report

    Hi,
    I've changed column order for interactive report.
    But it is not applied.
    How can I solve this issue?
    Thanks,
    Guy

    Hi Guy
    It depends on where you have changed the column order. If you change the column order using the 'Select Columns' function when you click on the 'Wheel of Magic', then it should work.
    If you are changing the column order from the Interactive Reports Attributes page then this will only affect the column order for non displayed items and the single row view.
    I hope that helps
    Shunt

Maybe you are looking for

  • Windows 8 Trackpad Not Working - Other Solutions Didn't Help

    Hello all, I recently installed Windows 8 Pro 64-bit on my Mid '09 MacBook. I had Windows 7 and 8 installed before and working, so I know it is compatible. Unfortunately, my trackpad does not work at all; No clicking, moving, nothing. I tried other s

  • Why can't I download my old purchases?

    I had recently had my blackberry 9900 stolen so i switched back to my 9780 and when i logged back into my blackberry app world account it had olny shown the previously downloaded apps from this bold and not the one that was stolen even though they we

  • Upgrade 11.5.10.2 to R12

    HI, We are planning to upgrade from 11.5.10.2 to 12.1.3 .. My doubts are : 1. need to take license ? 2. need to download Oracle E-Business Suite Release 12.1.1 Media Pack for Linux x86 from edelivery? 3.Then upgrade to 12.1.3 Share any good doc ... T

  • HT3281 Frustrations with searching iTunes for podcasts

    Does anyone actually find the iTunes store search useful and/or intuitive? 1. Why would ANYONE want to search for a keyword across podcasts, albums, songs, apps, itunes U, collections etc etc all at once?? Ok, maybe include that feature for completel

  • [b]New in Oracle[/b]

    Hi Im Arshad here, i have Installed the oracle 8i The standard Edition on windown 2000 Server. i have connected to SQL plus easily. Im now confused how to open the Enterprise Managaer for Oracle *i, Is there Any console of Oracle Enterprise for Stand