Not able to do page down in table control of screen

Hello,
I have created a table control on a screen of my report. This screen gets called from my selection screen. When I do page down or click on down arrow key to view other table entries nothing is happening. The scroll bar is not moving vertically.
Someone told me that no coding is required to make the table scrollable vertically.
Can someone please tell me if there is any attribute that needs to be set for this?
Best Regards,
Priyanka Gupta.

Hi,
Please go through this code.
dataL line_count type i.         " Global declaration
In the PAI of the table control screen.
CASE OK_CODE.
     when 'P--'.
      clear ok_code.
      perform paging using 'P--'.
     when 'P-'.
      clear ok_code.
      perform paging using 'P-'.
     when 'P+'.
      clear ok_code.
      perform paging using 'P+'.
     when 'P++'.
      clear ok_code.
      perform paging using 'P++'.
form paging using code.  "   NOTE  :  here "TABCTL" is your table control name
  data: i type i,
        j type i.
  case code.
    when 'P--'.
      tabctl-top_line = 1.
    when 'P-'.
      tabctl-top_line = tabctl-top_line - line_count.
      if tabctl-top_line le 0.
         tabctl-top_line = 1.
     endif.
    when 'P+'.
      i = tabctl-top_line + line_count.
      j = tabctl-lines - line_count + 1.
      if j le 0.
         j = 1.
      endif.
      if i le j.
        tabctl-top_line = i.
      else.
        tabctl-top_line = j.
      endif.
    when 'P++'.
      tabctl-top_line = tabctl-lines - line_count + 1.
      if tabctl-top_line le 0.
         tabctl-top_line = 1.
      endif.
  endcase.
endform.                   
Hope this will help you.
Regards,
Smart Varghese

Similar Messages

  • Disable Vertical scroll but enable Page down in Table control for BDC

    Hello All
    In my 4.6C sysem , i had enabled Scroll bar in table control by  populating TABC-lines = <No of records>...Then when i try to capture the BDC recording of this , then the scrolling event is not captured in BDC , as we all know.....
    So i put few buttons on the application bar as NEXT PAGE, NEXT LINE , PREV PAGE n PREV LINE...and i did the scrolling by writing the code manually in PAI...and that is getting captured in BDC so my problem is partially solved...
    Now as u see..i have default working Scroll bar on my T.C..also i have my buttons on the application bar....i want to get rid of the vertical scrolling....so now i am NOT populating the TABC-lines field...But as soon as i do this , my  buttons stopped also working...Any idea how to get rid of this ?
    In short when i don't write : TABC-lines = no_of_records .....to remove vertical scroling.......my manual scrolling mechanism also getting disabled..
    Is it possible to remove only vertical scrolling ?
    Thanks in advance .
    Nilesh

    No reply from any one ???

  • Issue finding current line when page down occurs - table control

    HI experts,
    How to find the current line index of the table control? The "Current line" property of table control gives the index of the current line when the cursor is in the first page. If it exceeds the first page, then it is not returning the correct value..
    For example, first page has 10 lines and the cursor is in the 5th line of the 2nd page, then the index must be returned as 15.. But current line returns the value as 5..
    Pls tell me how to find this.

    Hi,
    try this Way...
    IN PBO At MODULE STATUS_<Screen-Number>.
    13 is the number of cells in the Tables control
    TBC_200 is the Table control Name....
      if sy-ucomm = 'PGUP'.
         if TBC_200-current_line GE 14.
            TBC_200-top_line = TBC_200-top_line - 13.
         endif.
      ENDIF.
      if sy-ucomm = 'PGDN'.
         if TBC_200-current_line lE TBC_200-lines.
            TBC_200-top_line = TBC_200-top_line + 13.
         endif.
      ENDIF.
    Regards,
    Prabhudas

  • How Make Table Control full screen   ?

    Hi all, how can I make table control full screen?

    Hello,
    In the menu painter for the screen containing the table control....drag the boundaries of the table to fit the visible boundary marked..if we are calling table control using a sub screen area ..then the subscreen area in the main screen needs to be enlarged as per requirements...
    Pls check and revert
    Regards
    Byju

  • I AM NOT ABLE TO BROWSE PAGES USING PG UP/DOWN OR BY USING ARROW KEYS EVEN BY USING THE F7 KEY..WHAT TO DO

    I HAVE USE "ABOUT:CONFIG" AND TURNED "accessibility.warn_on_caretbrowsing" as "true" and "accessibility.browsewithcaret" as "false"...

    If you have overlaid keys on keyboards make sure NumLock light is off; hopefully, OEM did not reverse that -- light should mean NumLock is on and you want if off.
    Do you have two sets of vertical scrollbars on the webpage. If you are inside a textbox, the keyboard controls would apply to the textbox and the textbox scrollbar would move.
    Test with this page, it has no text boxes and no frames:
    :http://dmcritchie.mvps.org/firefox/firefox-problems.htm#fx4
    If you find the page up and page down is changing to back/forward button within the tab history (particularly on some laptops), see
    *Bug 640587 – Page up/down behavior changes to "page back/forward"
    *:https://bugzilla.mozilla.org/show_bug.cgi?id=640587
    Sounds like you have the following under control and correct:
    :Are those settings still in effect when you have the problem. F7 will toggle the accessibility.browsewith caret on(true)/off(false).
    The settings in about:config still allow you to change them with F7, by including the following in user.js they will be reset each time you restart Firefox.
    // Get SpaceBar, PageUp, PageDown to work properly if F7 hit accidentally
    :// see http://dmcritchie.mvps.org/firefox/firefox.htm#caret(problems)
    : user_pref("accessibility.browsewithcaret", false);
    : user_pref("accessibility.warn_on_browsewithcaret", true);
    Press F7 if you get the warning message you were okay but will have to press "No", if you don't get the message then you. Do not put a check in the dialog box -- if you you will not get the warning again until you restart.
    summary:
    :http://kb.mozillazine.org/Scrolling_with_arrow_keys_no_longer_works

  • Not able to scroll up/down on pages with touchpad in Firefox 8.0.1

    Use a laptop with Win XP pro and not able to use scrollfunction in Firefox 8.0.1.
    On another laptop with Win XP pro and Firefox 3.6.xxx ,scrollfunction works ok.

    I did more research and Command "C" does not function ONLY WHEN TRYING TO USE IT IN HOTMAIL. I have other sites open in Firefox and I am able to Command "C" and Command "V" from them just fine.
    Problem is not in Firefox it is in Hotmail, specifically the latest update which allows you to "flag" emails to keep them at the top of your inbox. Sorry for all the fuss.

  • Not able to see data in Pivot table

    Hi,
    I have a issue with pivot table i have a column which displays values 0 and 1 and another column called month when i am placing this month column as a section and values column as a measure i am not seeing any values means i can see the month as header but instead showing 0 or 1 its showing blank columns. previously i created similar kind of table it worked but at that time values column data type is number this time its char. can anybody help me out how i can see the data in the pivot table. i already tried converting this column to number but still i am not able to see data in that values column.
    Thanks

    Hi copter,
    Place the month column in rows and value column in measure section and check if results are coming.If still it doesnt come i suppose you dint apply aggregation rules to value column.In pivot view click values column and aggregate by /select min or max or either server complex and check your results.
    (I suppose your aggregation rules is default)....Correct this one and you can place it in sections as per your requirement.
    Cheers,
    KK

  • Not able to open page in R12

    Hi all,
    I have developed a page in 9i jdevoloper, I registerd page in oracle applications.
    It is working fine in 11i instance. But I am not able to run the page from R12 instance.
    It is showing the below error when i open page in oracle applications.
    oracle.apps.fnd.framework.OAException: Could not load application module 'wnsgs.oracle.apps.sysadmin.employeeadvancerequest.server.EmployeeAdvanceRequestAM'.
         at oracle.apps.fnd.framework.webui.OAJSPApplicationRegistry.registerApplicationModule(OAJSPApplicationRegistry.java:279)
         at oracle.apps.fnd.framework.webui.OAJSPApplicationRegistry.registerApplicationModule(OAJSPApplicationRegistry.java:78)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:1300)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:543)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:431)
         at OA.jspService(_OA.java:212)
         at com.orionserver.http.OrionHttpJspPage.service(OrionHttpJspPage.java:59)
         at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:379)
         at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:594)
         at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:518)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
         at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:713)
         at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:370)
         at com.evermind.server.http.ServletRequestDispatcher.unprivileged_forward(ServletRequestDispatcher.java:259)
         at com.evermind.server.http.ServletRequestDispatcher.access$100(ServletRequestDispatcher.java:51)
         at com.evermind.server.http.ServletRequestDispatcher$2.oc4jRun(ServletRequestDispatcher.java:193)
         at oracle.oc4j.security.OC4JSecurity.doPrivileged(OC4JSecurity.java:284)
         at com.evermind.server.http.ServletRequestDispatcher.forward(ServletRequestDispatcher.java:198)
         at com.evermind.server.http.EvermindPageContext.forward(EvermindPageContext.java:395)
         at RF.jspService(_RF.java:225)
         at com.orionserver.http.OrionHttpJspPage.service(OrionHttpJspPage.java:59)
         at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:379)
         at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:594)
         at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:518)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
         at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:64)
         at oracle.apps.jtf.base.session.ReleaseResFilter.doFilter(ReleaseResFilter.java:26)
         at com.evermind.server.http.EvermindFilterChain.doFilter(EvermindFilterChain.java:15)
         at oracle.apps.fnd.security.AppsServletFilter.doFilter(AppsServletFilter.java:318)
         at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:621)
         at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:370)
         at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:871)
         at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:453)
         at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:313)
         at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:199)
         at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
         at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
         at java.lang.Thread.run(Thread.java:619)
    ## Detail 0 ##
    JBO-30003: The application pool (wimuat1.wind.wnsgroup.netTESTFIN1529wnsgs.oracle.apps.sysadmin.employeeadvancerequest.server.EmployeeAdvanceRequestAM) failed to checkout an application module due to the following exception:
    oracle.jbo.JboException: JBO-29000: Unexpected exception caught: oracle.jbo.JboException, msg=JBO-29000: Unexpected exception caught: oracle.jbo.NoDefException, msg=JBO-25002: Definition wnsgs.oracle.apps.sysadmin.employeeadvancerequest.server.EmployeeAdvanceRequestAM of type ApplicationModule not found
         at oracle.jbo.common.ampool.ApplicationPoolImpl.doCheckout(ApplicationPoolImpl.java:2002)
         at oracle.jbo.common.ampool.ApplicationPoolImpl.useApplicationModule(ApplicationPoolImpl.java:2793)
         at oracle.jbo.common.ampool.SessionCookieImpl.useApplicationModule(SessionCookieImpl.java:453)
         at oracle.jbo.http.HttpSessionCookieImpl.useApplicationModule(HttpSessionCookieImpl.java:233)
         at oracle.apps.fnd.framework.webui.OAHttpSessionCookieImpl.useApplicationModule(OAHttpSessionCookieImpl.java:511)
         at oracle.jbo.common.ampool.SessionCookieImpl.useApplicationModule(SessionCookieImpl.java:424)
         at oracle.apps.fnd.framework.webui.OAJSPApplicationRegistry.registerApplicationModule(OAJSPApplicationRegistry.java:208)
         at oracle.apps.fnd.framework.webui.OAJSPApplicationRegistry.registerApplicationModule(OAJSPApplicationRegistry.java:78)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:1300)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:543)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:431)
         at OA.jspService(_OA.java:212)
         at com.orionserver.http.OrionHttpJspPage.service(OrionHttpJspPage.java:59)
         at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:379)
         at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:594)
         at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:518)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
         at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:713)
         at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:370)
         at com.evermind.server.http.ServletRequestDispatcher.unprivileged_forward(ServletRequestDispatcher.java:259)
         at com.evermind.server.http.ServletRequestDispatcher.access$100(ServletRequestDispatcher.java:51)
         at com.evermind.server.http.ServletRequestDispatcher$2.oc4jRun(ServletRequestDispatcher.java:193)
         at oracle.oc4j.security.OC4JSecurity.doPrivileged(OC4JSecurity.java:284)
         at com.evermind.server.http.ServletRequestDispatcher.forward(ServletRequestDispatcher.java:198)
         at com.evermind.server.http.EvermindPageContext.forward(EvermindPageContext.java:395)
         at RF.jspService(_RF.java:225)
         at com.orionserver.http.OrionHttpJspPage.service(OrionHttpJspPage.java:59)
         at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:379)
         at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:594)
         at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:518)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
         at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:64)
         at oracle.apps.jtf.base.session.ReleaseResFilter.doFilter(ReleaseResFilter.java:26)
         at com.evermind.server.http.EvermindFilterChain.doFilter(EvermindFilterChain.java:15)
         at oracle.apps.fnd.security.AppsServletFilter.doFilter(AppsServletFilter.java:318)
         at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:621)
         at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:370)
         at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:871)
         at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:453)
         at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:313)
         at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:199)
         at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
         at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
         at java.lang.Thread.run(Thread.java:619)
    Can anyone help me on this issue..It's urgent
    Thanks
    Naresh
    Edited by: naresh on May 8, 2012 2:17 PM

    Hi Naresh,
    This is because of the files which you moved will not have read write permissions.. make sure that
    you need to change the mode of the class files to 777.
    Login to Telnet and change the mode through CHMOD 777 command
    OR
    Navigate to winscp3 right click on the files then give read write access
    Regards
    krish

  • Not able to find the mapping for table W_CUSTOMER_STATUS_HIST_F_TMP

    Hi All,
    I have implemented the Out of Box solution of Order Management Analytics module with 11.5.10 version of Oracle EBS and respective adopters. Under the same I am not able to notice any mapping to load the data into W_CUSTOMER_STATUS_HIST_F_TMP table and due to which it causing few reports under order management.
    Could you please tell me the mappings name for this Target Table so that I can verify from my side if it has been missed or so?
    I am finding this W_CUSTOMER_STATUS_HIST_F_TMP table is getting used as Source Table under the folder of PLP for the mapping as,
    PLP_CustomerStatusHistoryFact_Extract
    PLP_CustomerStatusHistoryFact_Old_Customers_Load
    and PLP_CustomerStatusHistoryFact_Extract
    Thanks,
    -Vinay

    Not sure this would help but As per data lineage guide, it says PLP_CustomerStatusHistoryFact_Extract mapping populates this table from series of different tables. Later, From temp table it goes to W_CUSTOMER_STATUS_HIST_F table via mapping PLP_CustomerStatusHistoryFact_New_Customers_Load
    ~r

  • Not able to see all the SAP tables from CR 2008

    Hi All,
    1)I am not able to see all the SAP database tables(DEV server) from Database expert menu in CR 2008. Only tables those start with alphabet letters upto A & B are visible. I checked the database connection>right click>options> found no filters as well.
    We are using the CR 2008 trial version with SAP ECC.
    2) When i am trying with Production Server of SAP ECC, I am not able to logon to the SAP from CR 2008. It is giving error message
    as : LOGON FAILED : User USER1 has no RFC AUTHORIZATION for function group SYST
    Please help me to resolve these. Thanks in advance.

    Thank you very much ingo.
    You helped me a lot.
    One more question, when I am trying for SAP database connections say for ex: 10.57.410.70, again and again some times the connection is getting saved in my connections with as new versions/variants like
    10.57.410.70_1 or so. How to overcome this.
    Thanks in advance ingo
    Badari

  • Not able to select MS SQL Server tables in sqldeveloper using dblink

    Hi All,
    I able tp select MS SQL table columns in sqlplus prompt but i am not able to select same thing in sql developer using dblink.
    If i use convert(<mycol>,'WE8ISO8859P1','utf8') in sqldeveloper its working, how to select MS SQL columns without convert function.
    Thanks,
    -Mani

    Mani,
    This is a problem with SQL*Developer and converting nvarchar characters.
    The workround is to install the Oracle client software and use the option in SQL*Developer -
    - Tools
    - Preferences
    - Database
    - Advanced
    - and click the 'Use OCI/Thick driver' option.
    I made these steps -
    - download the 11.1 client software from eDelivery -
    http://edelivery.oracle.com/
    - go through the administration screens (name, etc)
    - on the next screen ' Media Pack Search' screen choose -
    - Select a Product Pack - Oracle database
    - Platform - Microsoft Windows (32-bit)
    - Oracle® Database 11g Release 1 (11.1.0.6.0) Media Pack for Microsoft Windows (32-bit)
    - then download -
    Oracle® Database 11g Release 1 Client (11.1.0.6.0) for Microsoft Windows (32-bit) CD
    - Install the Instant Client and also apply the 11.10.7 patchset to the ORACLE_HOME where you install the client. (if you are using 11.1.0.7 RDBMS)
    - for Windows change the PATH system variable to make sure the 11.1 RDBMS and Client ORACLE_HOME directories are listed before any other Oracle directories
    - started SQL*Developer and clicked the 'Use OCI/Thick driver' option
    - could then run the select -
    select "col2" from test_nvarchar@dg4msql ;
    without any problems.
    If this is still a problem for you then let us know the description of the columns in the SQL*Server table that give the problem and the exact errors you receive.
    Regards,
    Mike

  • I am not able to fill up my output table

    I'm fresher to ABAP.
    I am  not able to fill up my output internal table. please help in correcting my select statements.
    Please help me.
    I am pasting my code here.
    DATA: BEGIN OF marc_tab OCCURS 0,
           matnr LIKE marc-matnr,    " Material Number
           eislo LIKE marc-eislo,    " Minimum Safety Stock
           mabst LIKE marc-mabst,    " Maximum stock level
           eisbe LIKE marc-eisbe,    " Safety stock
           werks LIKE marc-werks,    " Plant
           ekgrp LIKE marc-ekgrp,    " Purchasing group
           dispo LIKE marc-dispo,    " MRP controller
    END OF marc_tab.
    DATA: BEGIN OF mard_tab OCCURS 0,
           lgort LIKE mard-lgort,     " Storage Location
           speme LIKE mard-speme,    " Blocked stock
           umlme LIKE mard-umlme,    " Stock in transfer
           insme LIKE mard-insme,    " Stock in quality inspection
           retme LIKE mard-retme,    " Blocked Stock Returns
           labst LIKE mard-labst,    " Valuated stock with unrestricted use
          END OF mard_tab.
    DATA: mard_tab1 LIKE STANDARD TABLE OF mard_tab WITH HEADER
    LINE.
    Material and description
    DATA: BEGIN OF mara_makt_tab OCCURS 0,
          matnr LIKE mara-matnr,   "Material number
          maktx LIKE makt-maktx,   "Material description
          END OF mara_makt_tab.
    DATA: BEGIN OF eord_lfa1_tab OCCURS 0,
          matnr LIKE eord-matnr,  "Material number
          ebeln LIKE eord-ebeln,  "Scheduling Agreement
          lifnr LIKE eord-lifnr,  "Vendor's account number
          name1 LIKE lfa1-name1,                                "Name 1
          END OF eord_lfa1_tab.
    DATA: BEGIN OF mseg_mkpf_tab OCCURS 0,
          budat LIKE mkpf-budat,    "Posting date in the document
          mblnr LIKE mkpf-mblnr,    "Number of material document
          werks LIKE mseg-werks,
          mjahr LIKE mseg-mjahr,     "Material doc. year
          menge LIKE mseg-menge,     "Quantity
          lgort LIKE mseg-lgort,     "Storage location
          bwart1 LIKE mseg-bwart,     " Movement type (inventory management)
          bwart2 LIKE mseg-bwart,    
          lifnr LIKE mseg-lifnr,
          END OF mseg_mkpf_tab.
    DATA: mseg_mkpf_tab1 LIKE STANDARD TABLE OF mseg_mkpf_tab WITH HEADER
    LINE.
    DATA: BEGIN OF mkol_tab OCCURS 0,
          seinm LIKE mkol-seinm,      " Restricted-use consignment stock
          slabs LIKE mkol-slabs,     " Unrestricted-use consignment stock
          sobkz  LIKE mkol-sobkz,     " Special stock indicator         
          END OF mkol_tab.
    DATA: BEGIN OF t_werks OCCURS 0,
          werks LIKE t001w-werks,    " plant
          END OF  t_werks.
    **DATA: BEGIN OF mkpf_tab OCCURS 0,
         budat LIKE mkpf-budat,    "Posting date in the document
         mblnr LIKE mkpf-mblnr,    "Number of material document
         END OF  mkpf_tab.
    DATA: BEGIN OF zresult_tab OCCURS 0,
           matnr LIKE marc-matnr,    " Material Number
           maktx LIKE makt-maktx,   "Material description
           rev_lvl TYPE c,           " Revision level
           ebeln LIKE eord-ebeln,  "Scheduling Agreement
           ekgrp LIKE marc-ekgrp,    " Purchasing group
           dispo LIKE marc-dispo,    " MRP controller
           lifnr LIKE eord-lifnr,  "Vendor's account number
           name1 LIKE lfa1-name1,                               "Name 1
           eislo LIKE marc-eislo,    " Minimum Safety Stock
           mabst LIKE marc-mabst,    " Maximum stock level
           eisbe LIKE marc-eisbe,    " Safety stock
           werks LIKE marc-werks,    " Plant
           bwart LIKE mseg-bwart,     " Movement type (inventory management)
           slabs LIKE mkol-slabs,    " Unrestricted-use consignment stock
           labst LIKE mard-labst,    " Valuated stock with unrestricted use
           speme LIKE mard-speme,    " Blocked stock
           umlme LIKE mard-umlme,    " Stock in transfer
           insme LIKE mard-insme,    " Stock in quality inspection
          retme LIKE mard-retme,    " Blocked Stock Returns /added
         seinm LIKE mkol-seinm,    " Restricted-use consignment stock
         sobkz LIKE mkol-sobkz,   " Special stock indicator         
         lgort LIKE mseg-lgort,     "Storage location
           END OF zresult_tab.
    *DATA: zresult_tab1 LIKE STANDARD TABLE OF zresult_tab WITH HEADER LINE.
    DATA: BEGIN OF zresult_tab1 OCCURS 0,
           matnr LIKE marc-matnr,    " Material Number
           maktx LIKE makt-maktx,   "Material description
           ebeln LIKE eord-ebeln,  "Scheduling Agreement
           ekgrp LIKE marc-ekgrp,    " Purchasing group
           dispo LIKE marc-dispo,    " MRP controller
           lifnr LIKE eord-lifnr,  "Vendor's account number
           name1 LIKE lfa1-name1,                               "Name 1
           eislo LIKE marc-eislo,    " Minimum Safety Stock
           mabst LIKE marc-mabst,    " Maximum stock level
           eisbe LIKE marc-eisbe,    " Safety stock
           werks LIKE marc-werks,    " Plant
           bwart LIKE mseg-bwart,     " Movement type (inventory management)
           menge LIKE mseg-menge,   
           slabs LIKE mkol-slabs,    " Unrestricted-use consignment stock
           labst LIKE mard-labst,    " Valuated stock with unrestricted use
           speme LIKE mard-speme,    " Blocked stock
           umlme LIKE mard-umlme,    " Stock in transfer
           insme LIKE mard-insme,    " Stock in quality inspection
           lgort LIKE mard-lgort,    
          retme LIKE mard-retme,    " Blocked Stock Returns
           END OF zresult_tab1.
    *DATA : begin of zresult_tab1 occurs 0,
    *include zresult_tab LIKE zresult_tab.
    *end of itab.
    and the select statements are like this:
      SELECT matnr
                FROM mara
                    INTO  TABLE zresult_tab
                    WHERE matnr IN s_matnr.
                   and werks in s_werks.
      SELECT mkpfbudat mkpfmblnr
             msegmblnr msegmjahr mseg~menge
             mseglgort msegbwart
            FROM mseg INNER JOIN mkpf
              ON  mkpfmblnr = msegmblnr
                AND  mkpfmjahr = msegmjahr
               INTO CORRESPONDING FIELDS OF
                TABLE mseg_mkpf_tab
                WHERE
                mseg~werks IN s_werks
                AND lgort IN s_lgort1
                AND lgort IN s_lgort2
                AND bwart IN s_bwart1
                AND bwart IN s_bwart2.
              AND budat IN s_usgpid.
      IF sy-subrc EQ 0.
    special stocks from vendor/Vendor consignment stock
        SELECT seinm slabs sobkz
                FROM  mkol
                  INTO CORRESPONDING FIELDS OF
                  TABLE mkol_tab
                  FOR ALL ENTRIES IN mseg_mkpf_tab
                 WHERE matnr IN s_matnr
                AND werks = mseg_mkpf_tab-werks
              AND lifnr in s_lifnr
                AND sobkz  = 'K'.
      ENDIF.
      SELECT lgort speme umlme insme retme labst
       FROM mard INTO TABLE mard_tab
       WHERE matnr = zresult_tab-matnr
                AND werks IN s_werks
                AND lgort IN s_lgort1
                AND lgort IN s_lgort2.
      IF sy-subrc NE 0.
        MESSAGE i000 WITH 'no data populated!!!'.
      ENDIF.
    SELECT matnr ebeln lifnr
                        FROM eord
                            INTO CORRESPONDING FIELDS OF
                            TABLE eord_lfa1_tab
                            WHERE matnr IN s_matnr
                           AND werks IN s_werks.
      IF sy-subrc NE 0.
        MESSAGE i000 WITH 'fgdf'.  ENDIF
      SELECT matnr ebeln lifnr
                    FROM eord
                        INTO CORRESPONDING FIELDS OF
                        TABLE eord_lfa1_tab
                        WHERE lifnr IN  s_lifnr
                        AND werks IN s_werks
      IF sy-subrc NE 0.
        MESSAGE i000 WITH 'No  matching material found'.
      ENDIF.
      IF NOT p_endstk  IS INITIAL.
        CLEAR zresult_tab1.
        LOOP AT mard_tab.
          READ TABLE zresult_tab1 WITH KEY lgort = s_lgort1.
          IF sy-subrc EQ 0.
            COLLECT mard_tab INTO mard_tab1.
          ENDIF.
          MOVE mard_tab1-speme TO zresult_tab-speme.
          MOVE mard_tab1-umlme TO zresult_tab-umlme.
          MOVE mard_tab1-insme TO zresult_tab-insme.
          MOVE mard_tab1-retme TO zresult_tab-retme.
          MOVE mard_tab1-labst TO zresult_tab-labst.
          APPEND zresult_tab.
        ENDLOOP.
      ENDIF.
      IF NOT p_otrstk  IS INITIAL.
        CLEAR zresult_tab1.
        LOOP AT mard_tab.
         READ TABLE zresult_tab1 WITH KEY lgort = s_lgort1 lgort = s_lgort2
          IF sy-subrc EQ 0.
            COLLECT mard_tab INTO mard_tab1.
          ENDIF.
          MOVE mard_tab1-speme TO zresult_tab-speme.
          MOVE mard_tab1-umlme TO zresult_tab-umlme.
          MOVE mard_tab1-insme TO zresult_tab-insme.
          MOVE mard_tab1-retme TO zresult_tab-retme.
        move mard_tab1-labst to zresult_tab-labst.
          APPEND zresult_tab.
        ENDLOOP.
      ENDIF.
      IF NOT p_chk IS INITIAL.
        CLEAR :mseg_mkpf_tab,mseg_mkpf_tab1.
        LOOP AT zresult_tab1.
          READ TABLE mseg_mkpf_tab WITH KEY bwart1 = s_bwart1
          lifnr =  s_lifnr budat = s_usgpid.
          IF sy-subrc EQ 0.
            COLLECT mseg_mkpf_tab INTO mseg_mkpf_tab1.
          ENDIF.
          MOVE mseg_mkpf_tab1-menge TO zresult_tab1-menge.
          APPEND zresult_tab1.
        ENDLOOP.
      ENDIF.
    and filling the zresult _tab like this:
      LOOP AT zresult_tab1.
        READ TABLE mseg_mkpf_tab.
        IF sy-subrc EQ 0.
          zresult_tab1-bwart = mseg_mkpf_tab-bwart1.
          MODIFY  zresult_tab1.
        ENDIF.
      ENDLOOP.
      LOOP AT zresult_tab1.
        READ TABLE mkol_tab.
        IF sy-subrc EQ 0.
          zresult_tab1-slabs = mkol_tab-slabs.
        ENDIF.
        MODIFY zresult_tab1.
      ENDLOOP.
      LOOP AT zresult_tab1.
        READ TABLE marc_tab.
        IF sy-subrc EQ 0.
          zresult_tab1-eislo = marc_tab-eislo.
          zresult_tab1-mabst = marc_tab-mabst.
          zresult_tab1-eisbe = marc_tab-eisbe.
          zresult_tab1-werks = marc_tab-werks.
          zresult_tab1-ekgrp = marc_tab-ekgrp.
          zresult_tab1-dispo = marc_tab-dispo.
        ENDIF.
        MODIFY zresult_tab1.
      ENDLOOP.
      LOOP AT zresult_tab1.
        READ TABLE mard_tab.
        IF sy-subrc EQ 0.
          zresult_tab1-labst = mard_tab-labst.
          zresult_tab1-lgort = mard_tab-lgort.
          zresult_tab1-speme = mard_tab-speme.
          zresult_tab1-umlme = mard_tab-umlme.
          zresult_tab1-insme = mard_tab-insme.
        ENDIF.
        MODIFY zresult_tab1.
      ENDLOOP.
    Thanks
    Alekhya

    Some comments on your code ---
    SELECT lgort speme umlme insme retme labst
    FROM mard INTO TABLE mard_tab
    WHERE matnr = zresult_tab-matnr
    AND werks IN s_werks
    AND lgort IN s_lgort1
    AND lgort IN s_lgort2.
    ---> instead of using zresult_tab-matnr u should be using s_matnr...to populate the mard_tab internal table with the records for all material otherwise it would just do it for the last record of zresult_tab-matnr.
    IF NOT p_endstk IS INITIAL.
    CLEAR zresult_tab1.
    LOOP AT mard_tab.
    READ TABLE zresult_tab1 WITH KEY lgort = s_lgort1.
    IF sy-subrc EQ 0.
    COLLECT mard_tab INTO mard_tab1.
    ENDIF.
    MOVE mard_tab1-speme TO zresult_tab-speme.
    MOVE mard_tab1-umlme TO zresult_tab-umlme.
    MOVE mard_tab1-insme TO zresult_tab-insme.
    MOVE mard_tab1-retme TO zresult_tab-retme.
    MOVE mard_tab1-labst TO zresult_tab-labst.
    APPEND zresult_tab.
    ENDLOOP.
    ENDIF.
    --> I am quiet puzzled with the above code you are trying to read zresult_tab1 and appending data into zresult_tab. Also, for the read to be successful you should try and fill more key columns otherwise it would just fetch the first record.
    --> Also in the final bit of code you are appending and modifying zresult_tab1 table and expecting result in zresult_tab table ?? Can you please check on the code with that respect.
    Regards
    Anurag

  • Not able to find the Queries in Table

    Hi Experts,
    Am searching for all the queries whcih we have developed in table RSRREPDIR - which is Directory of all reports (Query GENUNIID). But am not able to find out some queries in this table also..
    Can anyone please let me know the table where i can find all the queries...
    Regards,
    Gattu...

    Oliver,
    Thanks a lot for your quick reply... But am not able to find few queries in that table.. Can you please let me know hat might be the reason and how to trigger this..
    Regards,
    Gattu

  • Not able to load page with contents to be shown on selecting first option

    I have one.jsp which has a select box whose values are got from the database..on change of option, the two.jsp is excuted (which includes one.jsp using one.jsp) and the corresponding results are shown...
    As of now i am using the select box with the first option as "select the option"..
    Now in the select box, i dont want the use
    [<option>--Select the option--</option>/code]
    ...i want to load the select box with the database values in one.jsp and load the corresponding contents to be shown for the  first option value automatically using two.jsp by default...
    can anyone help me out in this....Urgently needed                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

    Let me try to explain this with example:
    Say The select box contain these values: Fruits and Vegetable which say are retrieved from the database.
    the onchange function retrieves the following if Fruits are selected:
    Examples of fruits: mango,apple
    Similarly if Vegetables are selected, the followin is displayed:
    Example of Vegetable: Raddish, Carrot.
    Since i was using the "Select a option" as the first option, when i clicked on fruits the examples of fruits are displayed and if i select vegetable the example of vegetables are displayed.
    Now i dont want to use the "Select a option". I just want to show the option values as fruits and vegetables and by default the examples of fruits should be displayed. If i select vegetables the examples of vegetables should be selected.
    Currently what is happening is that i am not able to show the examples of fruits by default. Secondly, I am able to show the examples of vegetables on selecting the Vegetables from the select box but if i select the Fruits again, the examples of fruits are not been displayed.
    Hope you get this better now...Any solutions...

  • Unable to scroll down in table control screen .

    Hi techies ,
    am attaching the table control screen .
    am not able to scroll down in that .
    and also may i know the reason why am not able to tick the checkbox ?
    it seems in disable mode .

    Hi Ajay,
    It was the only reason, ever i have faced...
    And other possibility is regarding tbc-lines, but i saw that you were doing this using describe table.
    Sometimes the table control will not show all the records in internal table(case while changing number of records in internal table each time )..
    At this case you have to set the lines in TBC.. using
    describe table itab lines tbc-lines.
    tbc-lines is very useful, if you want to enable a new blank line in table control, just do this
    tbc-lines = tbc-lines + 1.
    Explore all properties of table control it is very useful.
    I think, i could solved your issue.. thanks for your appreciation.
    Regards
    Sreekanth

Maybe you are looking for