Interactive report coding

hi can i know the coding for interactive report

Hi ,
Have a look at this Interactive ALV report.
REPORT ZZ_22038_22098_002 NO STANDARD PAGE HEADING LINE-SIZE 650
MESSAGE-ID ZZ_9838 .
TYPE-POOLS: SLIS.
*type declaration for values from ekko
TYPES: BEGIN OF I_EKKO,
EBELN LIKE EKKO-EBELN,
AEDAT LIKE EKKO-AEDAT,
BUKRS LIKE EKKO-BUKRS,
BSART LIKE EKKO-BSART,
LIFNR LIKE EKKO-LIFNR,
END OF I_EKKO.
DATA: IT_EKKO TYPE STANDARD TABLE OF I_EKKO INITIAL SIZE 0,
WA_EKKO TYPE I_EKKO.
*type declaration for values from ekpo
TYPES: BEGIN OF I_EKPO,
EBELN LIKE EKPO-EBELN,
EBELP LIKE EKPO-EBELP,
MATNR LIKE EKPO-MATNR,
MENGE LIKE EKPO-MENGE,
MEINS LIKE EKPO-MEINS,
NETPR LIKE EKPO-NETPR,
END OF I_EKPO.
DATA: IT_EKPO TYPE STANDARD TABLE OF I_EKPO INITIAL SIZE 0,
WA_EKPO TYPE I_EKPO .
*variable for Report ID
DATA: V_REPID LIKE SY-REPID .
*declaration for fieldcatalog
DATA: I_FIELDCAT TYPE SLIS_T_FIELDCAT_ALV,
WA_FIELDCAT TYPE SLIS_FIELDCAT_ALV.
DATA: IT_LISTHEADER TYPE SLIS_T_LISTHEADER.
declaration for events table where user comand or set PF status will
be defined
DATA: V_EVENTS TYPE SLIS_T_EVENT,
WA_EVENT TYPE SLIS_ALV_EVENT.
declartion for layout
DATA: ALV_LAYOUT TYPE SLIS_LAYOUT_ALV.
declaration for variant(type of display we want)
DATA: I_VARIANT TYPE DISVARIANT,
I_VARIANT1 TYPE DISVARIANT,
I_SAVE(1) TYPE C.
*PARAMETERS : p_var TYPE disvariant-variant.
*Title displayed when the alv list is displayed
DATA: I_TITLE_EKKO TYPE LVC_TITLE VALUE 'FIRST LIST DISPLAYED'.
DATA: I_TITLE_EKPO TYPE LVC_TITLE VALUE 'SECONDRY LIST DISPLAYED'.
INITIALIZATION.
V_REPID = SY-REPID.
PERFORM BUILD_FIELDCATLOG.
PERFORM EVENT_CALL.
PERFORM POPULATE_EVENT.
START-OF-SELECTION.
PERFORM DATA_RETRIEVAL.
PERFORM BUILD_LISTHEADER USING IT_LISTHEADER.
PERFORM DISPLAY_ALV_REPORT.
*& Form BUILD_FIELDCATLOG
Fieldcatalog has all the field details from ekko
FORM BUILD_FIELDCATLOG.
WA_FIELDCAT-TABNAME = 'IT_EKKO'.
WA_FIELDCAT-FIELDNAME = 'EBELN'.
WA_FIELDCAT-SELTEXT_M = 'PO NO.'.
APPEND WA_FIELDCAT TO I_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-TABNAME = 'IT_EKKO'.
WA_FIELDCAT-FIELDNAME = 'AEDAT'.
WA_FIELDCAT-SELTEXT_M = 'DATE.'.
APPEND WA_FIELDCAT TO I_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-TABNAME = 'IT_EKKO'.
WA_FIELDCAT-FIELDNAME = 'BUKRS'.
WA_FIELDCAT-SELTEXT_M = 'COMPANY CODE'.
APPEND WA_FIELDCAT TO I_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-TABNAME = 'IT_EKKO'.
WA_FIELDCAT-FIELDNAME = 'BUKRS'.
WA_FIELDCAT-SELTEXT_M = 'DOCMENT TYPE'.
APPEND WA_FIELDCAT TO I_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-TABNAME = 'IT_EKKO'.
WA_FIELDCAT-FIELDNAME = 'LIFNR'.
WA_FIELDCAT-NO_OUT = 'X'.
WA_FIELDCAT-SELTEXT_M = 'VENDOR CODE'.
APPEND WA_FIELDCAT TO I_FIELDCAT.
CLEAR WA_FIELDCAT.
ENDFORM. "BUILD_FIELDCATLOG
*& Form EVENT_CALL
we get all events - TOP OF PAGE or USER COMMAND in table v_events
FORM EVENT_CALL.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
I_LIST_TYPE = 0
IMPORTING
ET_EVENTS = V_EVENTS
EXCEPTIONS
LIST_TYPE_WRONG = 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. "EVENT_CALL
*& Form POPULATE_EVENT
Events populated for TOP OF PAGE & USER COMAND
FORM POPULATE_EVENT.
READ TABLE V_EVENTS INTO WA_EVENT WITH KEY NAME = 'TOP_OF_PAGE'.
IF SY-SUBRC EQ 0.
WA_EVENT-FORM = 'TOP_OF_PAGE'.
MODIFY V_EVENTS FROM WA_EVENT TRANSPORTING FORM WHERE NAME =
WA_EVENT-FORM.
ENDIF.
READ TABLE V_EVENTS INTO WA_EVENT WITH KEY NAME = 'USER_COMMAND'.
IF SY-SUBRC EQ 0.
WA_EVENT-FORM = 'USER_COMMAND'.
MODIFY V_EVENTS FROM WA_EVENT TRANSPORTING FORM WHERE NAME =
WA_EVENT-NAME.
ENDIF.
ENDFORM. "POPULATE_EVENT
*& Form data_retrieval
retreiving values from the database table ekko
FORM DATA_RETRIEVAL.
SELECT EBELN AEDAT BUKRS BSART LIFNR FROM EKKO INTO TABLE IT_EKKO.
ENDFORM. "data_retrieval
*& Form bUild_listheader
text
-->I_LISTHEADEtext
FORM BUILD_LISTHEADER USING I_LISTHEADER TYPE SLIS_T_LISTHEADER.
DATA HLINE TYPE SLIS_LISTHEADER.
HLINE-INFO = 'this is my first alv pgm'.
HLINE-TYP = 'H'.
ENDFORM. "build_listheader
*& Form display_alv_report
text
FORM DISPLAY_ALV_REPORT.
V_REPID = SY-REPID.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_CALLBACK_PROGRAM = V_REPID
I_CALLBACK_PF_STATUS_SET = ' '
I_CALLBACK_USER_COMMAND = 'USER_COMMAND'
I_CALLBACK_TOP_OF_PAGE = 'TOP_OF_PAGE'
I_GRID_TITLE = I_TITLE_EKKO
I_GRID_SETTINGS =
IS_LAYOUT = ALV_LAYOUT
IT_FIELDCAT = I_FIELDCAT[]
IT_EXCLUDING =
IT_SPECIAL_GROUPS =
IT_SORT =
IT_FILTER =
IS_SEL_HIDE =
i_default = 'ZLAY1'
I_SAVE = 'A'
is_variant = i_variant
IT_EVENTS = V_EVENTS
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 TOP_OF_PAGE
text
FORM TOP_OF_PAGE.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
IT_LIST_COMMENTARY = IT_LISTHEADER
i_logo =
I_END_OF_LIST_GRID =
ENDFORM. "TOP_OF_PAGE
*& Form USER_COMMAND
text
-->R_UCOMM text
-->, text
-->RS_SLEFIELDtext
FORM USER_COMMAND USING R_UCOMM LIKE SY-UCOMM
RS_SELFIELD TYPE SLIS_SELFIELD.
CASE R_UCOMM.
WHEN '&IC1'.
READ TABLE IT_EKKO INTO WA_EKKO INDEX RS_SELFIELD-TABINDEX.
PERFORM BUILD_FIELDCATLOG_EKPO.
PERFORM EVENT_CALL_EKPO.
PERFORM POPULATE_EVENT_EKPO.
PERFORM DATA_RETRIEVAL_EKPO.
PERFORM BUILD_LISTHEADER_EKPO USING IT_LISTHEADER.
PERFORM DISPLAY_ALV_EKPO.
ENDCASE.
ENDFORM. "user_command
*& Form BUILD_FIELDCATLOG_EKPO
text
FORM BUILD_FIELDCATLOG_EKPO.
WA_FIELDCAT-TABNAME = 'IT_EKPO'.
WA_FIELDCAT-FIELDNAME = 'EBELN'.
WA_FIELDCAT-SELTEXT_M = 'PO NO.'.
APPEND WA_FIELDCAT TO I_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-TABNAME = 'IT_EKPO'.
WA_FIELDCAT-FIELDNAME = 'EBELP'.
WA_FIELDCAT-SELTEXT_M = 'LINE NO'.
APPEND WA_FIELDCAT TO I_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-TABNAME = 'I_EKPO'.
WA_FIELDCAT-FIELDNAME = 'MATNR'.
WA_FIELDCAT-SELTEXT_M = 'MATERIAL NO.'.
APPEND WA_FIELDCAT TO I_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-TABNAME = 'I_EKPO'.
WA_FIELDCAT-FIELDNAME = 'MENGE'.
WA_FIELDCAT-SELTEXT_M = 'QUANTITY'.
APPEND WA_FIELDCAT TO I_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-TABNAME = 'I_EKPO'.
WA_FIELDCAT-FIELDNAME = 'MEINS'.
WA_FIELDCAT-SELTEXT_M = 'UOM'.
APPEND WA_FIELDCAT TO I_FIELDCAT.
CLEAR WA_FIELDCAT.
WA_FIELDCAT-TABNAME = 'I_EKPO'.
WA_FIELDCAT-FIELDNAME = 'NETPR'.
WA_FIELDCAT-SELTEXT_M = 'PRICE'.
APPEND WA_FIELDCAT TO I_FIELDCAT.
CLEAR WA_FIELDCAT.
ENDFORM. "BUILD_FIELDCATLOG_EKPO
*& Form event_call_ekpo
we get all events - TOP OF PAGE or USER COMMAND in table v_events
FORM EVENT_CALL_EKPO.
CALL FUNCTION 'REUSE_ALV_EVENTS_GET'
EXPORTING
I_LIST_TYPE = 0
IMPORTING
ET_EVENTS = V_EVENTS
EXCEPTIONS
LIST_TYPE_WRONG = 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. "event_call_ekpo
*& Form POPULATE_EVENT
Events populated for TOP OF PAGE & USER COMAND
FORM POPULATE_EVENT_EKPO.
READ TABLE V_EVENTS INTO WA_EVENT WITH KEY NAME = 'TOP_OF_PAGE'.
IF SY-SUBRC EQ 0.
WA_EVENT-FORM = 'TOP_OF_PAGE'.
MODIFY V_EVENTS FROM WA_EVENT TRANSPORTING FORM WHERE NAME =
WA_EVENT-FORM.
ENDIF.
ENDFORM. "POPULATE_EVENT
*& Form TOP_OF_PAGE
text
FORM F_TOP_OF_PAGE.
CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE'
EXPORTING
IT_LIST_COMMENTARY = IT_LISTHEADER
i_logo =
I_END_OF_LIST_GRID =
ENDFORM. "TOP_OF_PAGE
*& Form USER_COMMAND
text
-->R_UCOMM text
-->, text
-->RS_SLEFIELDtext
*retreiving values from the database table ekko
FORM DATA_RETRIEVAL_EKPO.
SELECT EBELN EBELP MATNR MENGE MEINS NETPR FROM EKPO INTO TABLE IT_EKPO.
ENDFORM.
FORM BUILD_LISTHEADER_EKPO USING I_LISTHEADER TYPE SLIS_T_LISTHEADER.
DATA: HLINE1 TYPE SLIS_LISTHEADER.
HLINE1-TYP = 'H'.
HLINE1-INFO = 'CHECKING PGM'.
ENDFORM.
FORM DISPLAY_ALV_EKPO.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
I_INTERFACE_CHECK = ' '
I_BYPASSING_BUFFER = ' '
I_BUFFER_ACTIVE = ' '
I_CALLBACK_PROGRAM = V_REPID
I_CALLBACK_PF_STATUS_SET = ' '
I_CALLBACK_USER_COMMAND = 'F_USER_COMMAND'
I_CALLBACK_TOP_OF_PAGE = 'TOP_OF_PAGE'
I_CALLBACK_HTML_TOP_OF_PAGE = ' '
I_CALLBACK_HTML_END_OF_LIST = ' '
I_STRUCTURE_NAME =
I_BACKGROUND_ID = ' '
I_GRID_TITLE = I_TITLE_EKPO
I_GRID_SETTINGS =
IS_LAYOUT =
IT_FIELDCAT = I_FIELDCAT[]
IT_EXCLUDING =
IT_SPECIAL_GROUPS =
IT_SORT =
IT_FILTER =
IS_SEL_HIDE =
I_DEFAULT =
I_SAVE = 'A'
IS_VARIANT =
IT_EVENTS = V_EVENTS
TABLES
T_OUTTAB = IT_EKPO
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.
Hope this resolves your query.
Reward all the helpful answers.
Regards

Similar Messages

  • Interactive report coding without using LVs

    hi...can i get coding for interactive report without using ALVs?

    Hi Rakkasi....
    here i am pastina a Two levels Code for NON ALV Interactive report....
    just copy and paste this code into your sample editor program and run it...
    and see the code ...its simple...
    <b>Reward points if helpful,</b>
    Here is the code....
    *& Report  ZTEJ_INTAB1                                                 *
    REPORT  ZTEJ_INTAB1 LINE-SIZE 103 LINE-COUNT 35(5) NO STANDARD PAGE
    HEADING.
    *TABLES DECLARATION
    TABLES : KNA1, VBAK, VBAP.
    *SELECT OPTIONS
    SELECT-OPTIONS: CUST_NO FOR KNA1-KUNNR.
    *INITIALIZATION
    INITIALIZATION.
        CUST_NO-LOW = '01'.
        CUST_NO-HIGH = '5000'.
        CUST_NO-SIGN = 'I'.
        CUST_NO-OPTION = 'BT'.
        APPEND CUST_NO.
    *SELECTION SCREEN VALIDATION
    AT SELECTION-SCREEN ON CUST_NO.
        LOOP AT SCREEN.
            IF CUST_NO-LOW < 1 OR CUST_NO-HIGH > 5000.
              MESSAGE E001(ZTJ1).
             ENDIF.
        ENDLOOP.
    *BASIC LIST SELECTION
    START-OF-SELECTION.
        SELECT KUNNR NAME1 ORT01 LAND1 INTO
               (KNA1-KUNNR, KNA1-NAME1,KNA1-ORT01,KNA1-LAND1)
               FROM KNA1
               WHERE KUNNR IN CUST_NO.
              WRITE:/1 SY-VLINE,
                    KNA1-KUNNR UNDER 'CUSTOMER NO.' HOTSPOT ON,
                    16 SY-VLINE,
                    KNA1-NAME1 UNDER 'NAME',
                    61 SY-VLINE,
                    KNA1-ORT01 UNDER 'CITY',
                    86 SY-VLINE,
                    KNA1-LAND1 UNDER 'COUNTRY',
                    103 SY-VLINE.
        HIDE: KNA1-KUNNR.
        ENDSELECT.
        ULINE.
    *SECONDARY LIST ACCESS
    AT LINE-SELECTION.
        IF SY-LSIND = 1.
            PERFORM SALES_ORD.
        ENDIF.
        IF SY-LSIND = 2.
            PERFORM ITEM_DET.
        ENDIF.
    *TOP OF PAGE
    TOP-OF-PAGE.
            FORMAT COLOR 1.
            WRITE : 'CUSTOMER DETAILS'.
            FORMAT COLOR 1 OFF.
            ULINE.
            FORMAT COLOR 3.
            WRITE : 1 SY-VLINE,
                    3 'CUSTOMER NO.',
                    16 SY-VLINE,
                    18 'NAME',
                    61 SY-VLINE,
                    63 'CITY',
                    86 SY-VLINE,
                    88 'COUNTRY',
                    103 SY-VLINE.
                    ULINE.
          FORMAT COLOR 3 OFF.
    *TOP OF PAGE FOR SECONDARY LISTS
    TOP-OF-PAGE DURING LINE-SELECTION.
    *TOP OF PAGE FOR 1ST SECONDARY LIST
        IF SY-LSIND = 1.
                     ULINE.
      FORMAT COLOR 1.
      WRITE : 'SALES ORDER DETAILS'.
                     ULINE.
      FORMAT COLOR 1 OFF.
      FORMAT COLOR 3.
            WRITE : 1 SY-VLINE,
                    3 'CUSTOMER NO.',
                    16 SY-VLINE,
                    18 'SALES ORDER NO.',
                    40 SY-VLINE,
                    42 'DATE',
                    60 SY-VLINE,
                    62 'CREATOR',
                    85 SY-VLINE,
                    87 'DOC DATE',
                    103 SY-VLINE.
                    ULINE.
          ENDIF.
          FORMAT COLOR 3 OFF.
    *TOP OF PAGE FOR 2ND SECONDARY LIST
    IF SY-LSIND = 2.
                     ULINE.
          FORMAT COLOR 1.
          WRITE : 'ITEM DETAILS'.
          ULINE.
          FORMAT COLOR 1 OFF.
    FORMAT COLOR 3.
            WRITE : 1 SY-VLINE,
                    3  'SALES ORDER NO.',
                    40 SY-VLINE,
                    42 'SALES ITEM NO.',
                    60 SY-VLINE,
                    62 'ORDER QUANTITY',
                    103 SY-VLINE.
                    ULINE.
        ENDIF.
    FORMAT COLOR 3 OFF.
    *END OF PAGE
    END-OF-PAGE.
         ULINE.
    WRITE :'USER :',SY-UNAME,/,'DATE :', SY-DATUM, 85 'END OF PAGE:',
    SY-PAGNO.
          SKIP.
    *&      Form  SALES_ORD
    *&      FIRST SECONDARY LIST FORM
    FORM SALES_ORD .
    SELECT KUNNR VBELN ERDAT ERNAM AUDAT INTO
           (VBAK-KUNNR, VBAK-VBELN, VBAK-ERDAT, VBAK-ERNAM, VBAK-AUDAT)
           FROM VBAK
           WHERE KUNNR = KNA1-KUNNR.
           WRITE:/1 SY-VLINE,
                   VBAK-KUNNR UNDER 'CUSTOMER NO.' HOTSPOT ON,
                   16 SY-VLINE,
                   VBAK-VBELN UNDER 'SALES ORDER NO.' HOTSPOT ON,
                   40 SY-VLINE,
                   VBAK-ERDAT UNDER 'DATE',
                   60 SY-VLINE,
                   VBAK-ERNAM UNDER 'CREATOR',
                   85 SY-VLINE,
                   VBAK-AUDAT UNDER 'DOC DATE',
                   103 SY-VLINE.
          HIDE : VBAK-VBELN.
    ENDSELECT.
    ULINE.
    ENDFORM.                    " SALES_ORD
    *&      Form  ITEM_DET
    *&      SECOND SECONDARY LIST FORM
    FORM ITEM_DET .
      SELECT VBELN POSNR KWMENG INTO
             (VBAP-VBELN, VBAP-POSNR, VBAP-KWMENG)
             FROM VBAP
             WHERE VBELN = VBAK-VBELN.
             WRITE : /1 SY-VLINE,
                       VBAP-VBELN UNDER 'SALES ORDER NO.',
                       40 SY-VLINE,
                       VBAP-POSNR UNDER 'SALES ITEM NO.',
                       60 SY-VLINE,
                       VBAP-KWMENG UNDER 'ORDER QUANTITY',
                       103 SY-VLINE.
            ENDSELECT.
            ULINE.
            ENDFORM.                    " ITEM_DET
    Regards,
    Tejas

  • Interactive reports coding

    How to create Reports with Radio Buttons, which gives sales information, Delivery information and Billing information. plz mention the detail coding
    Thanks,
    Priya Ranjan

    hi,,
    *& Report Z50813_SD_REPT_SALESDATA1
    REPORT Z50813_SD_REPT_SALESDATA1.
    *-----TABLES DECLARATION
    TABLES : KNA1, "Customer Master
    vbak, "Sales Document Header
    VBAP, "Sales Document Item
    SSCRFIELDS. "Screen Field Table
    & D A T A D E C L A R A T I O N &
    DATA : BEGIN OF IT_KNA1 OCCURS 0,
    KUNNR TYPE KNA1-KUNNR, "Customer Number
    LAND1 TYPE KNA1-LAND1, "Country Key
    NAME1 TYPE KNA1-NAME1, "Name
    ORT01 TYPE KNA1-ORT01, "City
    END OF IT_KNA1.
    DATA : BEGIN OF IT_KNA2 OCCURS 0,
    KUNNR TYPE KNA1-KUNNR, "Customer Number
    LAND1 TYPE KNA1-LAND1, "Country Key
    NAME1 TYPE KNA1-NAME1, "Name
    ORT01 TYPE KNA1-ORT01, "City
    END OF IT_KNA2.
    DATA: BEGIN OF IT_VBAK OCCURS 0,
    VBELN TYPE VBAK-VBELN, "Sales Document
    ERDAT TYPE VBAK-ERDAT, "Date
    ERNAM TYPE VBAK-ERNAM, "Name of Person
    AUART TYPE VBAK-AUART, "Sales Document Type
    END OF IT_VBAK.
    DATA: BEGIN OF IT_VBAP OCCURS 0,
    VBELN TYPE VBAP-VBELN, "Sales Document
    POSNR TYPE VBAP-POSNR, "Sales Document Item
    MATNR TYPE VBAP-MATNR, "Material Number
    MATKL TYPE VBAP-MATKL, "Material group
    END OF IT_VBAP.
    DATA: V_COUNT TYPE INT4, "Current Row Index
    V_LINE LIKE SY-LISEL, "Contents of selected line
    V_KUNNR LIKE KNA1-KUNNR.
    & S E L E C T I O N S C R E E N &
    SELECTION-SCREEN BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
    SELECTION-SCREEN BEGIN OF LINE.
    PARAMETERS : RB1 RADIOBUTTON GROUP G1 DEFAULT 'X'.
    SELECTION-SCREEN COMMENT 5(20) TEXT-002 FOR FIELD RB1.
    SELECTION-SCREEN END OF LINE.
    SELECT-OPTIONS : SO_KUNNR FOR KNA1-KUNNR OBLIGATORY.
    PARAMETERS : P_HITS(3) TYPE C.
    SELECTION-SCREEN BEGIN OF LINE.
    PARAMETERS : RB2 RADIOBUTTON GROUP G1.
    SELECTION-SCREEN COMMENT 5(20) TEXT-003 FOR FIELD RB2.
    SELECTION-SCREEN END OF LINE.
    PARAMETERS : P_FILE LIKE RLGRAP-FILENAME DEFAULT 'c:\test'.
    SELECTION-SCREEN PUSHBUTTON /33(10) CUSTL USER-COMMAND PUSH1.
    SELECTION-SCREEN PUSHBUTTON 58(10) CUSTD USER-COMMAND PUSH2.
    SELECTION-SCREEN END OF BLOCK B1.
    & I N I T I A L I Z A T I O N &
    INITIALIZATION.
    MOVE 'LOAD' TO CUSTL.
    MOVE 'DISP' TO CUSTD.
    & A T L I N E S E L E C T I O N &
    AT SELECTION-SCREEN.
    PERFORM VALIDATE_KUNNR.
    & A T S E L E C T I O N S C R E E N O N V A L U E-R E Q U E S T &
    AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_FILE.
    CALL FUNCTION 'F4_FILENAME'
    EXPORTING
    PROGRAM_NAME = SYST-CPROG
    DYNPRO_NUMBER = SYST-DYNNR
    FIELD_NAME = ' '
    IMPORTING
    FILE_NAME = P_FILE.
    & S T A R T O F S E L E C T I O N &
    START-OF-SELECTION.
    PERFORM CUST_DETAILS.
    & S T A R T O F S E L E C T I O N &
    TOP-OF-PAGE.
    FORMAT COLOR 3 INTENSIFIED OFF.
    WRITE :/02(25) SY-REPID.
    WRITE : 39(15) 'Page'(010), SY-PAGNO.
    FORMAT COLOR OFF.
    FORMAT COLOR 6 INTENSIFIED OFF.
    FORMAT COLOR COL_HEADING.
    ULINE AT :/1(60).
    WRITE: /1 SY-VLINE,
    2 'Cust Number'(000),
    14 SY-VLINE,
    16 'Country'(007),
    25 SY-VLINE,
    26 'City'(008),
    42 SY-VLINE,
    43 'Region'(009),
    60 SY-VLINE.
    ULINE AT :/1(60).
    FORMAT COLOR COL_HEADING OFF.
    & T O P O F P A G E D U R I N G L I N E S E L E C T I O N &
    TOP-OF-PAGE DURING LINE-SELECTION.
    IF SY-LSIND EQ 1 OR SY-UCOMM EQ 'VBAK'.
    FORMAT COLOR COL_HEADING.
    ULINE AT :/1(60).
    WRITE : /1 SY-VLINE,
    2 'Docu No.'(011),
    14 SY-VLINE,
    16 'Date'(012),
    26 SY-VLINE,
    27 'Name'(013),
    42 SY-VLINE,
    43 'DType'(014),
    60 SY-VLINE.
    ULINE AT :/1(60).
    ELSEIF SY-LSIND EQ 2 OR SY-UCOMM EQ 'VBAK'.
    SET PF-STATUS SPACE.
    ULINE AT :/1(60).
    WRITE : /1 SY-VLINE,
    2 'Docu No.'(015),
    14 SY-VLINE,
    16 'Sales Item'(016),
    25 SY-VLINE,
    26 'Mat No'(017),
    42 SY-VLINE,
    43 VBAP-MATKL,
    50 'Mat Grp'(018),
    60 SY-VLINE.
    ULINE AT :/1(60).
    ENDIF.
    & AT USER-COMMAND &
    AT USER-COMMAND.
    CASE SY-UCOMM.
    WHEN 'VBAK'.
    PERFORM SALES_ITEM.
    WHEN 'DELIVERY'.
    CLEAR IT_VBAK-VBELN.
    GET CURSOR VALUE IT_VBAK-VBELN.
    SET PARAMETER ID 'AUN' FIELD IT_VBAK-VBELN.
    CALL TRANSACTION 'VA03' AND SKIP FIRST SCREEN.
    WHEN 'DISP'.
    PERFORM DISPLAY_BASIC.
    ENDCASE.
    & AT LINE SELECTION &
    AT LINE-SELECTION.
    IF SY-LSIND = 1.
    SET PF-STATUS 'DDDD'.
    PERFORM SALES_HEADER.
    ELSEIF SY-LSIND = 2.
    CASE SY-UCOMM.
    WHEN 'PICK'.
    SET PF-STATUS SPACE.
    PERFORM SALES_ITEM.
    WHEN 'DELIVERY'.
    CLEAR IT_VBAK-VBELN.
    GET CURSOR VALUE IT_VBAK-VBELN.
    SET PARAMETER ID 'AUN' FIELD IT_VBAK-VBELN.
    CALL TRANSACTION 'VA03' AND SKIP FIRST SCREEN.
    WHEN 'DISP'.
    PERFORM DISPLAY_BASIC.
    ENDCASE.
    PERFORM sales_item.
    ENDIF.
    & AT USER-COMMAND &
    AT USER-COMMAND.
    CASE SY-UCOMM.
    WHEN 'VBAK'.
    PERFORM SALES_ITEM.
    WHEN 'DELIVERY'.
    CLEAR IT_VBAK-VBELN.
    GET CURSOR VALUE IT_VBAK-VBELN.
    SET PARAMETER ID 'AUN' FIELD IT_VBAK-VBELN.
    CALL TRANSACTION 'VA03' AND SKIP FIRST SCREEN.
    WHEN 'DISP'.
    PERFORM DISPLAY_BASIC.
    ENDCASE.
    & Form CUST_DETAILS &
    FORM CUST_DETAILS .
    SELECT KUNNR
    LAND1
    NAME1
    ORT01
    FROM KNA1
    INTO TABLE IT_KNA1
    WHERE KUNNR IN SO_KUNNR.
    IF SY-SUBRC 0.
    MESSAGE 'SELECT VALID CUST NO' TYPE 'I'.
    ELSE.
    LOOP AT IT_KNA1.
    v_count = v_count + 1.
    IF SY-TABIX < P_HITS.
    IF v_count <= p_hits.
    MOVE IT_KNA1 TO IT_KNA2.
    APPEND IT_KNA2.
    ELSE.
    EXIT.
    ENDIF.
    ENDLOOP.
    ENDIF.
    IF NOT IT_KNA2[] IS INITIAL.
    LOOP AT IT_KNA2.
    WRITE : /1 SY-VLINE,
    2 IT_KNA2-KUNNR,
    14 SY-VLINE,
    16 IT_KNA2-LAND1,
    25 SY-VLINE,
    26 IT_KNA2-NAME1,
    42 SY-VLINE,
    43 IT_KNA2-ORT01,
    60 SY-VLINE.
    ULINE AT :/1(60).
    ENDLOOP.
    ENDIF.
    ENDFORM. " CUST_DETAILS
    **& Form load_file
    *form load_file .
    *endform. " load_file
    **& Form disp_file
    *form disp_file .
    *endform. " disp_file
    *& Form VALIDATE_KUNNR
    FORM VALIDATE_KUNNR .
    SELECT SINGLE KUNNR
    FROM KNA1
    INTO KNA1
    WHERE KUNNR = SO_KUNNR.
    ENDFORM. " VALIDATE_KUNNR
    *& Form SALES_HEADER
    FORM SALES_HEADER .
    DATA : V_KNA1(13).
    V_KNA1 = 'IT_KNA2-KUNNR'.
    *get cursor line sy-lilli value v_line
    CLEAR V_KUNNR.
    GET CURSOR FIELD V_KNA1 VALUE V_KUNNR.
    v_kunnr = v_line+1(10).
    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
    EXPORTING
    INPUT = V_KUNNR
    IMPORTING
    OUTPUT = V_KUNNR.
    SELECT VBELN
    ERDAT
    ERNAM
    AUART
    FROM VBAK
    INTO TABLE IT_VBAK
    WHERE KUNNR = V_KUNNR.
    IF SY-SUBRC = 0.
    LOOP AT IT_VBAK.
    WRITE : /1 SY-VLINE,
    2 IT_VBAK-VBELN,
    14 SY-VLINE,
    16 IT_VBAK-ERDAT,
    26 SY-VLINE,
    27 IT_VBAK-ERNAM,
    42 SY-VLINE,
    43 IT_VBAK-AUART,
    60 SY-VLINE.
    ULINE AT :/1(60).
    ENDLOOP.
    ENDIF.
    ENDFORM. " SALES_HEADER
    *& Form SALES_ITEM
    FORM SALES_ITEM .
    DATA : V_VBELN(13).
    V_VBELN = 'IT_VBAK-VBELN'.
    CLEAR IT_VBAK-VBELN.
    GET CURSOR FIELD V_VBELN VALUE IT_VBAK-VBELN.
    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
    EXPORTING
    INPUT = IT_VBAK-VBELN
    IMPORTING
    OUTPUT = IT_VBAK-VBELN.
    SELECT VBELN
    POSNR
    MATNR
    MATKL
    FROM VBAP
    INTO TABLE IT_VBAP
    WHERE VBELN = IT_VBAK-VBELN.
    LOOP AT IT_VBAP .
    WRITE : /1 SY-VLINE,
    2 IT_VBAP-VBELN,
    14 SY-VLINE,
    16 IT_VBAP-POSNR,
    25 SY-VLINE,
    26 IT_VBAP-MATNR,
    42 SY-VLINE,
    43 IT_VBAP-MATKL,
    60 SY-VLINE.
    ULINE AT :/1(60).
    ENDLOOP.
    ENDFORM. " SALES_ITEM
    *& Form DISP_DOCU
    FORM DISPLAY_BASIC .
    LOOP AT IT_KNA1 INTO IT_KNA1.
    FORMAT HOTSPOT ON.
    WRITE : /03 IT_KNA1-KUNNR,
    24 IT_KNA1-NAME1.
    HIDE IT_KNA1-KUNNR.
    ENDLOOP.
    ENDFORM. " display_basic
    pls reward if useful
    regards,
    rekha

  • Interactive Report Performance With Conditional Link

    Apex 3.2
    I have a interactive report.
    The underlying sql would return 127000 rows
    The sql is
    select
      lde.ods_system,
      lde.ldekey,
      msg.sendersystem, 
      msg.messagetype,
      msg.messageversion,
      msg.msgseqnumber,
      msg.alternatekey,
      msg.crudmarker,
      msg.clrbookdate,
      msg.clrbookresult,
      lower('udf_'||msg.messagetype) button,
      lde.ldekey||'.'||msg.alternatekey||'.'||msg.msgseqnumber udm_key
    from
      clr_esbmessageheader msg,
      clr_adm_systemmessage adm,
      udm_lde lde
    where
      adm.ldeid = lde.ldeid and
      msg.sendersystem = adm.system and
      msg.messagetype = adm.messagetype and
      msg.messageversion = adm.messageversion and
      msg.receiversystem = 'SCIPS'
    order by msg.clrbookdate desc
    This report only takes 1 second to display.
    I need to add a conditional link to another page, so I used
    case
    when lower('udf_'||msg.messagetype) = 'udf_distreceipt' then
    '<a class="type" href="' || apex_util.prepare_url('f?p='||:APP_ID||':52:'||:APP_SESSION||'::'||:DEBUG||':RIR'||':IR_MSG_KEY,P52_PG:'|| lde.ldekey||'.'|| msg.alternatekey ||'.'|| msg.msgseqnumber ||','|| 50, null, 'SESSION') || '"title="Go to udf_distreceipt Report">udf_distreceipt</a>'
    else 'no link' end table_link
    The sql seems to be ok, because the report accepted it, but selecting the new column and saving the report takes forever (over 2 mins)
    Now the report takes over 2 minutes to run and I still need to add more conditions.
    Have I coded the link incorrectly ?
    Gus

    Hi Gus,
    Are you wanting to put the link in the query for a specific reason?
    I had to do a similar thing in the past and just completed the column link section for the column.
    Why not just have the following in the query:
    case
    when lower('udf_'||msg.messagetype) = 'udf_distreceipt' then
    udf_distreceipt
    else null END table_link
    Then do the linking using column link section:
    You would specify your link text as #TABLE_LINK# which should then be conditionally displayed due to the case statement, then add in all the page item and values to pass across using a normal link column.
    Thanks
    Paul

  • Dynamically Colour Cells in an Interactive Report

    My application requires an interactive report where cells are colour coded and the cell may, or may not have a value, but the value doesn't relate to the colour.
    The report is based on a view which returns a result set as follows:
    rn col1_value col1_colour col2_value col2_colour col3_value col3_colour col4_value col4_colour
    1        null        grey          3        null       null        null        null        red
    2        null        null          3        grey       null        null           4        red
    3        null        grey       null        null          3        null        null        redIn the results, each cell to be displayed has two columns per row, one with the colour and one with the value to display where null is the default colour (white)/no value.
    In Apex 4.1 I can set the colour based on the values using the dynamic actions on the report display, but I can't work out how to set the colour of col1_value based on the results of col1_colour. I am hoping there is a way to set the colour of the cell col1_value and hide col1_colour from the report.
    If you know of any posts providing an example of how this may work, or if you are able to explain it to me I would really appreciate your time.
    I appreciate it may not be simple to see what I am aiming for given the text restriction and no images/tables available on the forum, hopefully you get the idea, but if not, ask and I will try and explain further.
    I have seen Blog posts about 3-4 years old on how you do this in Apex 3.0 or older, but can't work out how to get this to work in Apex 4.0 or Apex 4.1.

    I have solved this using Javascript in a Dynamic Action, javascript something like:
    $("td[headers='COL1_COLOUR']").each(function(){
       switch($(this).text())
          case "grey":
               $(this).parent().children("td[headers='COL1_VALUE']").css({"background-color":"#999"});
               break;
          case "green":
               $(this).parent().children("td[headers='COL1_VALUE']").css({"background-color":"green"});
               break;
          case "blue":
               $(this).parent().children("td[headers='COL1_VALUE']").css({"background-color":"blue"});
               break;
          case "orange":
               $(this).parent().children("td[headers='COL1_VALUE']").css({"background-color":"orange"});
               break;
          case "yellow":
               $(this).parent().children("td[headers='COL1_VALUE']").css({"background-color":"yellow"});
               break;
          default:
               break;
        $(this).css({"visibility":"hidden"});
        $("th[id='COL1_COLOUR']").css({"visibility":"hidden"});
    });

  • Remove HTML from Interactive report download

    I have interactive reports where the column link on a specific column has to be dynamic, that means, it cannot be hard coded in the column link attributes. The following is an example of one such report query:
    case when d.object_type_description ='Business Service' then
    '< href="f?p='||:app_id||':183:'||:app_session||'::::P183_OBJECT_ID:'||d.id||'">'||d.object_name||'</>'
    when d.object_type_description = 'Real Time Event' then
    '< href="f?p='||:app_id||':162:'||:app_session||'::::P162_OBJECT_ID:'||d.id||'">'||d.object_name||'</>'
    else
       null
    end as "OBJECT NAME"As you see in the above example, the link on the "Object Name" column could either redirect to page 183 or to page 162 based on the "Object Type Description" column.
    The column attribute of the "Object Name" column has "Display Type" set to "Standard Report Column". That works perfectly fine in the UI of the report. However, if I download the IR data (in any format) from the Actions -> Download menu, the object name column values are downloaded with the HTML characters as:
    < href="f?p=15548:183:6072319179284::::P183_OBJECT_ID:255245470513999672860510787772603748464">JP010000</>where JP010000 is the object name.
    Is there a way I can strip the HTML from the column values in the downloaded files?
    I am using Apex 4.1.

    Rohit,
    You can define the link in the query, make it hidden, use the value as column link URL. So, your query will look like the following:
    d.object_name,
    case when d.object_type_description ='Business Service' then
        'f?p='||:app_id||':183:'||:app_session||'::::P183_OBJECT_ID:'||d.id
    when d.object_type_description = 'Real Time Event' then
        'f?p='||:app_id||':162:'||:app_session||'::::P162_OBJECT_ID:'||d.id
    else
       null
    end linkChange the display type of LINK column to Hidden. In column link, enter #OBJECT_NAME# as Link Text. Select URL as Target. Enter #LINK# as URL value. In APEX 4.2, you can do this in easier way by defining HTML Column Expression.
    Regards,
    Christina
    Edited by: cbcho on Sep 27, 2012 11:35 AM

  • VERY STRANGE Interactive Report Filter Error

    I have a very interesting problem happening with an interactive report in my APEX application. The report runs just fine and has been in use for about 6 months. Just recently, the users have begun to run into problems when using the filter capability within the report. There is a specific column heading (RH Analyst) that they typically click on and select a specific analyst name (the list contains 10 entries). Most selections from the filter list work fine. However, when one specific name is chosen, they get the dreaded ORA-06502: PL/SQL: numeric or value error: character string buffer too small+*  error. 
    I have been working to narrow the problem down and have found the following:
    1. The filter error is related to the content of one specific column (not the one I am filtering on)
    2. The column that is causing the error is a CLOB datatype
    3. The data in the CLOB column was inserted into the database from a form utilizing an "HTML Editor Standard" type of item
    4. The data in the CLOB column was copied and pasted from an email that was being viewed using Outlook 2007
    5. If I try to recreate the problem with exactly the same information, but copied and pasted from Outlook 2003, I don't experience the problem.
    6. The only people experiencing this problem are people who have upgraded their system from Microsoft Office 2003 to Microsoft Office 2007
    7. When I try to load the form with the data that was stored in the database, I get a 404 page not found error. This is the same error that I get if more than 32k of data was saved into the CLOB.
    The data pasted into the HTML editor from Outlook 2007 (_this is the data that causes problems_) and saved to the CLOB looks like this when I extract it in SQL Developer
    (CLOB) <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
    <meta content="Word.Document" name="ProgId" />
    <meta content="Microsoft Word 12" name="Generator" />
    <meta content="Microsoft Word 12" name="Originator" />
    <link href="file:///C:\DOCUME~1\euw6ay0\LOCALS~1\Temp\msohtmlclip1\01\clip_filelist.xml" rel="File-List" />
    <link href="file:///C:\DOCUME~1\euw6ay0\LOCALS~1\Temp\msohtmlclip1\01\clip_themedata.thmx" rel="themeData" />
    <link href="file:///C:\DOCUME~1\euw6ay0\LOCALS~1\Temp\msohtmlclip1\01\clip_colorschememapping.xml" rel="colorSchemeMapping" /><!--[if gte mso 9]><xml>
    <w:WordDocument>
    <w:View>Normal</w:View>
    <w:Zoom>0</w:Zoom>
    <w:TrackMoves />
    <w:TrackFormatting />
    <w:PunctuationKerning />
    <w:ValidateAgainstSchemas />
    <w:SaveIfXMLInvalid>false</w:SaveIfXMLInvalid>
    <w:IgnoreMixedContent>false</w:IgnoreMixedContent>
    <w:AlwaysShowPlaceholderText>false</w:AlwaysShowPlaceholderText>
    <w:DoNotPromoteQF />
    <w:LidThemeOther>EN-US</w:LidThemeOther>
    <w:LidThemeAsian>X-NONE</w:LidThemeAsian>
    <w:LidThemeComplexScript>X-NONE</w:LidThemeComplexScript>
    <w:Compatibility>
    <w:BreakWrappedTables />
    <w:SnapToGridInCell />
    <w:WrapTextWithPunct />
    <w:UseAsianBreakRules />
    <w:DontGrowAutofit />
    <w:SplitPgBreakAndParaMark />
    <w:DontVertAlignCellWithSp />
    <w:DontBreakConstrainedForcedTables />
    <w:DontVertAlignInTxbx />
    <w:Word11KerningPairs />
    <w:CachedColBalance />
    </w:Compatibility>
    <w:BrowserLevel>MicrosoftInternetExplorer4</w:BrowserLevel>
    <m:mathPr>
    <m:mathFont m:val="Cambria Math" />
    <m:brkBin m:val="before" />
    <m:brkBinSub m:val="&#45;-" />
    <m:smallFrac m:val="off" />
    <m:dispDef />
    <m:lMargin m:val="0" />
    <m:rMargin m:val="0" />
    <m:defJc m:val="centerGroup" />
    <m:wrapIndent m:val="1440" />
    <m:intLim m:val="subSup" />
    <m:naryLim m:val="undOvr" />
    </m:mathPr></w:WordDocument>
    </xml><![endif]--><!--[if gte mso 9]><xml>
    <w:LatentStyles DefLockedState="false" DefUnhideWhenUsed="true"
    DefSemiHidden="true" DefQFormat="false" DefPriority="99"
    LatentStyleCount="267">
    <w:LsdException Locked="false" Priority="0" SemiHidden="false"
    UnhideWhenUsed="false" QFormat="true" Name="Normal" />
    <w:LsdException Locked="false" Priority="9" SemiHidden="false"
    UnhideWhenUsed="false" QFormat="true" Name="heading 1" />
    <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 2" />
    <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 3" />
    <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 4" />
    <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 5" />
    <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 6" />
    <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 7" />
    <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 8" />
    <w:LsdException Locked="false" Priority="9" QFormat="true" Name="heading 9" />
    <w:LsdException Locked="false" Priority="39" Name="toc 1" />
    <w:LsdException Locked="false" Priority="39" Name="toc 2" />
    <w:LsdException Locked="false" Priority="39" Name="toc 3" />
    <w:LsdException Locked="false" Priority="39" Name="toc 4" />
    <w:LsdException Locked="false" Priority="39" Name="toc 5" />
    <w:LsdException Locked="false" Priority="39" Name="toc 6" />
    <w:LsdException Locked="false" Priority="39" Name="toc 7" />
    <w:LsdException Locked="false" Priority="39" Name="toc 8" />
    <w:LsdException Locked="false" Priority="39" Name="toc 9" />
    <w:LsdException Locked="false" Priority="35" QFormat="true" Name="caption" />
    <w:LsdException Locked="false" Priority="10" SemiHidden="false"
    UnhideWhenUsed="false" QFormat="true" Name="Title" />
    <w:LsdException Locked="false" Priority="1" Name="Default Paragraph Font" />
    <w:LsdException Locked="false" Priority="11" SemiHidden="false"
    UnhideWhenUsed="false" QFormat="true" Name="Subtitle" />
    <w:LsdException Locked="false" Priority="22" SemiHidden="false"
    UnhideWhenUsed="false" QFormat="true" Name="Stro..."The data pasted into the HTML editor from Outlook 2003 and saved to the CLOB looks like this when I extract it in SQL Developer
    (CLOB) <p style="margin-bottom: 6pt;" class="MsoNormal"><u><span style="font-size: 10pt; font-family: 'Arial','sans-serif';">&ldquo;Implementation and  Compliance Update #2&rdquo;</span></u><span style="font-size: 10pt; font-family: 'Arial','sans-serif';"> addresses a concern  that clearinghouses may be in some cases inappropriately charging providers for  the use of a standard transaction. </span><o:p></o:p></p>
    <ul type="disc">
        <li style="" class="MsoNormal"><span style="font-size: 7pt;"> </span><span style="font-size: 10pt; font-family: 'Arial','sans-serif';">In particular, we  cite MN Statutes 62J.536, Subd. 1f, which states that:  <em>Group purchasers may  not impose any fee on providers for the use of the transactions prescribed in  this subdivision.  </em>The update explains that &ldquo;payers (or their agents) may  not charge for receiving a standard transaction&rdquo; and provides additional  information. The update is accompanied by a joint cover memo from MDH, the  Minnesota Department of Commerce, and the Minnesota Department of Labor and  Industry.  Note:  The Minnesota Department of Health (MDH) is charged with  implementing and enforcing Minnesota Statutes, section 62J.536. In addition, the  Minnesota Department of Commerce and the Department of Labor and Industry  administer additional statutory requirements for electronic claims submission,  consistent with MS &sect; 62J.536.</span><span style="font-size: 9pt; font-family: 'Arial','sans-serif';">  <o:p></o:p></span></li>
    </ul>
    <p style="margin-bottom: 6pt;" class="MsoNormal"><u><span style="font-size: 10pt; font-family: 'Arial','sans-serif';">&ldquo;Implementation and  Compliance Update #3&rdquo;</span></u><span style="font-size: 10pt; font-family: 'Arial','sans-serif';"> provides a reminder  of the upcoming Dec. 15, 2009 effective date for rules for the standard,  electronic exchange of health care remittance advices. It also clarifies  that:</span> <o:p></o:p></p>
    <ul type="disc">
        <li style="" class="MsoNormal"><span style="font-size: 10pt; font-family: 'Arial','sans-serif';">Statutory  requirements for standard, electronic remittance advices do not include  requirements for electronic payment (electronic funds transfer &ndash;  EFT)</span><span style="font-size: 9pt; font-family: 'Arial','sans-serif';">  <o:p></o:p></span></li>
    </ul>
    <ul type="disc">
        <li style="" class="MsoNormal"><span style="font-size: 10pt; font-family: 'Arial','sans-serif';">Consistent with MDH&rsquo;s  enforcement policies and plans described in Update #1 (posted  6/5/09):</span><span style="font-size: 9pt; font-family: 'Arial','sans-serif';">  <o:p></o:p></span></li>
    </ul>
    <p style="margin-bottom: 6pt; margin-left: 1.1in; text-indent: -0.25in;" class="MsoNormal"><span style="font-size: 10pt; font-family: 'Courier New';">o</span><span style="font-size: 7pt;">        </span><span style="font-size: 10pt; font-family: 'Arial','sans-serif';">Starting Dec. 15,  2009, group purchasers (payers) must be able to transmit &ndash; and providers must be  able to accept - standard, electronic RAs via computer-computer electronic data  interchange (EDI). So long as payers and providers are able to exchange the  remittance advice standard transaction electronically, the Department does not  take issue with payers making available additional mechanisms for communicating  RAs to providers, such as access to portable document format (.pdf) files, or  provider electronic mailboxes.</span><span style="font-family: 'Arial','sans-serif';"> </span><o:p></o:p></p>
    <ul type="disc">
        <li style="" class="MsoNormal"><span style="font-size: 10pt; font-family: 'Arial','sans-serif';">The Department&rsquo;s  determinations of whether payers and providers are complying with the  regulations will take into account several factors. However, we have determined  that it is not realistic to require electronic remittance advices when claims  ar..."     I am using APEX version 3.2
    Any help would be greatly appreciated. For now, my short term solution for them is to copy the information from Outlook 2007, paste it into a Wordpad, then copy it from wordpad and paste it into the HTML editor control. That seems to work fine but it is not a very nice solution for the users!
    Thanks,
    Dale

    Roel,
    Hey there! Hope you enjoyed your time off ;) Thanks for having a look...
    Yes, of course I "could" update the functions, but this is NOT something I want to do. I'm one of those people that subscribes to Coding by Contract and the assertion routines at the beginning and end of my subprograms are an important part of that.
    This may be a lack of understanding on my part with regards to the order in which Oracle does it's thing - or a bug in Apex... I'm able to duplicate the problem on apex.oracle.com: dmcghan/test/test.
    Log into the demo app with admin/dmcghan. The home page has an interactive report, filter the name and you should get the error. When you look at the query you'll see a filter in the where clause that goes against the apex_collections table. This is populated from the post-authentication procedure. Let me know if you have questions.
    Regards,
    Dan
    http://danielmcghan.us
    http://sourceforge.net/projects/tapigen
    http://sourceforge.net/projects/plrecur

  • Using HTML,how to change the color of column data in an interactive report?

    Hi,
    I want to change the color of data of a column in an interactive report.
    I want to do it by HTML.
    I have tried the code
    <style type="text/css">
    #apexir_EMP_MANID{color:blue;}
    </style>
    But it changes the color of the heading of column only. Not the data.
    Plz can anyone suggest me something ?
    Thanks in advance

    Hi Vaibss!
    Is it that what you're looking for?
    Color Coding (Post number 5)
    regards

  • Concept of Interactive Report by click on filed displaying next screen

    Hi,
    I want to know the concept of Interactive report i have work on simple and ALV reports, as per my present requirement of vendor outstanding balance  i have made a report as per my requirement i have data in 3 final tables  itab1  itab2   itab3,
    itab1 have all the data related to vendor bills line item wise,    itab2  have the data only as per vendor  means for one vendor one entry adding all the line item amount in one  row,   itab3 have the data as per reconcile account    
    in my requirement  firsti want to display  itab3       and after this  if vendor click on any reconcile account itab2 to be display  only those record as per selected reconcile account further to this  on next screen  if user click on any vendor  system should disply the itab1  record as per selected vendor from second screen.
    regards,
      zafar

    Hi
    call function 'REUSE_ALV_GRID_DISPLAY'
        exporting
          i_callback_program       = sy-cprog
          i_callback_user_command  = 'USER_COMMAND' " This is also maintained below just check further down
          is_layout                = gs_layout
          i_callback_pf_status_set = 'SET_PF_STATUS' " This form is maintained below just check further down
          it_fieldcat              = gt_fieldcat[]
          i_save                   = gc_a
        tables
          t_outtab                 = ist_final[].
    form set_pf_status using rt_extab type slis_t_extab.        "#EC CALLED
      set pf-status 'ZPP_NCO_STATUS_PTEI' excluding rt_extab.
    endform.   
    form user_command using p_ucomm    type sy-ucomm            "#EC CALLED
                            wa_selfield type slis_selfield .    "#EC CALLED
      case p_ucomm.
    * When user clicks on the Download button
        when '&DOWNLOAD'. " after you double click check the sy-ucomm (it is ONLY to the best of my knowledge )
    " again  Use The ALV FM or continue with your coding here
    " wa_selfield  contains the Line along with the contents of values of First Tab you can check them in Debug.
    Similary continue with Third Internal Table
    endform.

  • Displaying different colors for cells/columns in Interactive Report

    Hi,
    I have a requirement to display just the 'cells' in the Interactive Report columns with different colors.
    There are 3 columns in the Interactive report.
    The color coding for all the 3 different columns should be such that:
    <40% - red color
    40-70-orange
    greater than 70%-green
    I tried the highlight option in the report and saved the report as default, but still the color condition ended up getting displayed to the end user. I dont want this.
    Can someone suggest a better way to handle this requirement?

    Perhaps explore similar solutions described here
    Background Colour of Report Cell Issues.
    Scott

  • Interactive Report Returns Misleading Data Because of ROWNUM Limit

    Hi, We have been relying on widespread use of Interactive Reports for internal Business Intelligence in our company, and they have been very popular. However, a user found a data discrepancy when sorting a report because the ROWNUM limit of :APXWS_MAX_ROW_CNT is applied before the user requested ORDER BY clause. We are running Apex version 3.2.0.00.27 on a 10.2.0.4 database.
    The IR query returns quotes from our custom quoting application, and the default number of rows is 100 (and is changeable by the user). The user wanted to see the most recent quotes, so he selected the "Creation Date" column header and simply applied a descending filter. The most recent quote returned was dated last week. However, if he applied an additional filter of "creation date in the last week", he did see today's date and mostly current quote rows.
    When I ran debug on his IR query, I can see that the ROWNUM limit is applied first, then the ORDER BY. This means that the database fetches the first x rows that match the supplied parameters, and then orders the result set. However, this is not what the user meant, he wanted the first rows of an ordered set.
    Here's the debug query output (with the middle removed because it's long):
    select
           "QUOTE_NUMBER",
           "CUSTOMER",
           "CUST_CONTACT",
           "QUOTE_STATUS",
           "TOTAL_PRICE",
           "TOTAL_WEIGHT",
           "WHSE",
           "SHIP_DATE",
           "PO_NUMBER",
           "ORACLE_REFERENCE",
           "INSIDE_SALESREP",
           "OUTSIDE_SALESREP",
           "CREATION_DATE",
           "ID",
           "ORA_CUST_ID",
           "CUST_CONTACT_ID",
           count(*) over () as apxws_row_cnt
    from (
    select  *  from (
    SELECT
      kh.id,
      kh.ora_cust_id,
      kh.quote_number quote_number ,
      kh.cust_contact_id,
      k2_customers_pkg.get_contact(cust_contact_id) cust_contact ,
      k2_customers_pkg.get_cust_name(kh.ora_cust_id)customer,
      k2_customers_pkg.get_cust_number(ora_cust_id)
    ( ......... more sql goes here )
    AND k2_customers_pkg.get_outside_salesrep_number(kh.ora_site_id)||'%' LIKE :P64_OUTSIDE_SALES||'%'
    AND kh.whse_code like :P64_WAREHOUSES||'%'
    AND ((1=
        CASE WHEN :P64_ITEM_ID IS NULL THEN
            1
        ELSE
            (SELECT 1
               FROM k2_quote_lines kl
               JOIN k2_ingredients ki
                 ON ki.quote_line_id=kl.id
              WHERE (1=1
                AND kh.id=kl.quote_id
                AND ki.ora_item_id=:P64_ITEM_ID AND ROWNUM=1))
        END)
        OR 1=(
            SELECT 1 FROM k2_quote_lines kl WHERE kl.quote_id=kh.id AND kl.part_id=:P64_ITEM_ID AND ROWNUM=1
    )  r
    ) r where rownum <= to_number(:APXWS_MAX_ROW_CNT)
    order by "CREATION_DATE" DESC,"QUOTE_NUMBER" DESCHowever, what the user wanted is to have the ORDER BY applied first, then the limit. I realize performance may suffer, but users are now alarmed that they cannot trust these reports. I'm tempted to log a SR with Oracle on this.
    Any thoughts on this? Is this fixed in 4.0?
    Thank you, Wolf Moritz

    Hi, thanks for the response. I did spend a bit of time on trying to trick the interactive report into reversing the rownum and order by clauses. But ultimately I didn't see how to do it. Whatever query I paste into the source of the report is then wrapped in a couple of containing select statements which first applies the rownum limit and then the order by clause (if the user selects any columns to sort by).
    So this query:
    select * from scott.empBecomes:
    select
           "EMPNO",
           "ENAME",
           "JOB",
           "MGR",
           "HIREDATE",
           "SAL",
           "COMM",
           "DEPTNO",
           count(*) over () as apxws_row_cnt
    from (
    select  *  from (
    select * from scott.emp
    )  r
    ) r where rownum <= to_number(:APXWS_MAX_ROW_CNT)
    pAnd a user applied sort becomes:
    select
           "EMPNO",
           "ENAME",
           "JOB",
           "MGR",
           "HIREDATE",
           "SAL",
           "COMM",
           "DEPTNO",
           count(*) over () as apxws_row_cnt
    from (
    select  *  from (
    select * from scott.emp
    )  r
    ) r where rownum <= to_number(:APXWS_MAX_ROW_CNT)
    order by "DEPTNO" DESCIf I could somehow bind to some item for the order by string I might then be able to trick the report into ordering the result set first (which I know can't really be done unless using dynamic sql). Forcing an initial hard coded order by isn't practical on this particular report, although I do see why that might work in some circumstances.
    Side note on the oddly placed case statement: This interactive report has some page level "meta" parameter items, and that case statement was meant as a way to avoid an exists statement on a particularly large table if no value was submitted for P64_ITEM_ID. It's been a long time since we deployed the report, so it's probably worth testing some explain/autotrace plans on this case statement vs an exists statement in the predicate. But for now it works!
    Thanks, Wolf

  • Interactive Report Filter Problem

    Hello,
    I ran into a problem with an interactive report today. When the report first loads, no issue. If a filter is added, an error is returned. The error is actually generated by an assertion routine that raises and exception if a NULL value was passed in. Here's a modified/simplified version of the query:
    SELECT id,
       name,
       dept,
       emp.year_of_emp(hire_date) AS years_of_employment
    FROM emp_table
    WHERE id IN (
       SELECT c001
       FROM apex_collections
       WHERE collection_name = 'EMPS_UNDER_MANAGER'
    );Again, when the report first loads, no problem. Then when the manager applies, say a filter on dept, an error is raised from the emp.year_of_emp function because a NULL value was passed in.
    I know that all emps with an emp id in the collection have a hire_date so I don't feel as though I should have to add another condition in the where clause to filter those out (although that is the work around at this point). Anyone have any ideas as to what could be causing this?
    Regards,
    Dan
    http://danielmcghan.us
    http://sourceforge.net/projects/tapigen
    http://sourceforge.net/projects/plrecur

    Roel,
    Hey there! Hope you enjoyed your time off ;) Thanks for having a look...
    Yes, of course I "could" update the functions, but this is NOT something I want to do. I'm one of those people that subscribes to Coding by Contract and the assertion routines at the beginning and end of my subprograms are an important part of that.
    This may be a lack of understanding on my part with regards to the order in which Oracle does it's thing - or a bug in Apex... I'm able to duplicate the problem on apex.oracle.com: dmcghan/test/test.
    Log into the demo app with admin/dmcghan. The home page has an interactive report, filter the name and you should get the error. When you look at the query you'll see a filter in the where clause that goes against the apex_collections table. This is populated from the post-authentication procedure. Let me know if you have questions.
    Regards,
    Dan
    http://danielmcghan.us
    http://sourceforge.net/projects/tapigen
    http://sourceforge.net/projects/plrecur

  • SQL statement with Function returns slow in Interactive Report

    I have an Interactive Report that returns well but when I add in a function call in the where clause that does nothing but return a hard coded string of primary keys and is compared to a table's primary key with a like operator the performance tanks. Here is the example:
    get_school2_section(Y.pk_id,M.pk_id,I.section,:P577_SECTION_SHUTTLE) LIKE '%:' || I.pk_id || ':%'
    I have the values hard coded in the return of the function. There are no cursors run in the function, there is no processing done in the function. It only declares a variable. Sets the variable, and returns that variable back to the SQL statement.
    I can hard code the where clause value to look like this:
    ':90D8D830A877CCFFE040010A347D1A50:8ED0BBFDEAACC629E040010A347D6471:9800B8FDBD22B761E040010A347D0D9A:' LIKE '%:' || I.pk_id || ':%'
    This returns fast. When I add in the function call which returns the same hard coded values, the page goes from returning in 1 to 2 seconds to 45 or more seconds.
    Why does adding a simple function call into the where clause cause such a deterioration in performance.
    Edited by: alamantia on Aug 17, 2011 7:39 AM
    Edited by: alamantia on Aug 17, 2011 7:40 AM

    So you are telling me that the where clause with a function call will NOT run the function on every row? Please explain that to me further?
    if you have code that is the following:
    select a,b,c from a_table where a > 2 and b < 3 and function_call(c) > 0You are telling me that Oracle will NOT call that function on EVERY row it tries to process in the select?
    Thank you,
    Tony Miller
    Webster, TX
    I cried because I did not have an office with a door until I met a man who had no cubicle.
    -Dilbert
    If this question is answered, please mark the thread as closed and assign points where earned..

  • Interactive report for Interactions

    Hi all,
    Creating a report for Interactions using Analytics_Pro business role. I'm using the Interactions report area and am creating a very basic call coding report.
    The AHT (handle time) is however represented in Minutes, which is not quite standard for call centers (we usually use seconds). Is there a config required or do I have to play with the cube and add an extra figure that would represent it in seconds, then expose it, then add it to my report area, then add it to my report? (or whatever other steps required)?
    I'm on CRM 7.0 EHP 2

    Hi Fabien
    Interactive Reporting "Cubes" are defined with the expected fields of usage. When building the Interactive Report if the field is not available as standard then some type of enhancement would be required.
    Regards
    Arden

  • Basic report, Interactive report

    Hi i am new in report . Anybody can help me regards this . I need material with examlpe (Proper coding also ).  Help me in interactive report also. send through my mail id [email protected]
    Edited by: supriya satapathy on Oct 14, 2008 7:29 AM

    Hi supriya,
    Goto tcode ABAPDOCU or http://help.sap.com.
    you'll find reports etc with examples wrt syntax, use .
    Regards,
    Amit

Maybe you are looking for