BSP Application to Retrive Material Information

Embed Size (px)

Citation preview

  • 8/3/2019 BSP Application to Retrive Material Information

    1/11

    Creating a BSP application to retrieve Material information

    For more tips, tutorials, Interview questions, certification questions, please visitSAPTechnical.com

    Business Server Pages (BSP)

    Creating a BSP application to retrieve Material information

  • 8/3/2019 BSP Application to Retrive Material Information

    2/11

    Creating a BSP application to retrieve Material information

    For more tips, tutorials, Interview questions, certification questions, please visitSAPTechnical.com

    Go to transaction SE80. Select BSP application and input the name of the BSP application thatyou want to create.

    Save and activate the application.

    Right click on the application name and click createpage.

    The resultant window appears as follows.

    Enter the name of the page that you want to create. In this case it is the default.htm that I amcreating.

    Enter the description of the page and click on continue.

  • 8/3/2019 BSP Application to Retrive Material Information

    3/11

    Creating a BSP application to retrieve Material information

    For more tips, tutorials, Interview questions, certification questions, please visitSAPTechnical.com

    Click save.

    You can observe the pages with flow logic and under that you can f ind default.htm page in theBSP application tree.

  • 8/3/2019 BSP Application to Retrive Material Information

    4/11

    Creating a BSP application to retrieve Material information

    For more tips, tutorials, Interview questions, certification questions, please visitSAPTechnical.com

    Change the code in the layout as shown in the image below or copy and paste the code givenbelow in the layout window.

    MATERIAL DETAILS

    Material Number

    MATNR

    ERSDA

    LAEDA

    VPSTA

  • 8/3/2019 BSP Application to Retrive Material Information

    5/11

    Creating a BSP application to retrieve Material information

    For more tips, tutorials, Interview questions, certification questions, please visitSAPTechnical.com

    MATNR

    ERSDA

    LAEDA

    Create the page attributes as shown below.

    Save, Check and activate the BSP application and execute. Enter the login name and password

    in the pop-up that appears.

  • 8/3/2019 BSP Application to Retrive Material Information

    6/11

    Creating a BSP application to retrieve Material information

    For more tips, tutorials, Interview questions, certification questions, please visitSAPTechnical.com

    The BSP page looks as shown below.

    In the Event Handler tab, under OnInputProcessing tab, write the code as shown below or copyand paste the code that is given below.

  • 8/3/2019 BSP Application to Retrive Material Information

    7/11

    Creating a BSP application to retrieve Material information

    For more tips, tutorials, Interview questions, certification questions, please visitSAPTechnical.com

    Code under OnInputProcessing.

    CASE EVENT_ID.

    WHEN 'select'.

    NAVIGATION->SET_PARAMETER( 'matnr' ).

    SELECT * FROM MARA INTO TABLE I_MARA WHERE MATNR BETWEEN MATNR AND

    MATNR2.

    WHEN 'materials'.

    SELECT * FROM MARA INTO TABLE I_MARA.

    WHEN OTHERS.

    ENDCASE.

    Click on the BSP application name and input as shown below.

  • 8/3/2019 BSP Application to Retrive Material Information

    8/11

    Creating a BSP application to retrieve Material information

    For more tips, tutorials, Interview questions, certification questions, please visitSAPTechnical.com

    Save, check and activate the BSP application and then execute the application. The page wouldbe displayed as shown below.

  • 8/3/2019 BSP Application to Retrive Material Information

    9/11

    Creating a BSP application to retrieve Material information

    For more tips, tutorials, Interview questions, certification questions, please visitSAPTechnical.com

    Enter the material numbers in the textboxes and then click on Get details.

    The output would be as follows.

    The output is a result of the select query that we fired selecting the specified set of fields.

  • 8/3/2019 BSP Application to Retrive Material Information

    10/11

    Creating a BSP application to retrieve Material information

    For more tips, tutorials, Interview questions, certification questions, please visitSAPTechnical.com

    Click on the Get all button to get the output as follows.

    Remember, we have fired a select query selecting all the records from the database table MARAand are displaying it.

  • 8/3/2019 BSP Application to Retrive Material Information

    11/11

    Creating a BSP application to retrieve Material information

    For more tips, tutorials, Interview questions, certification questions, please visitSAPTechnical.com

    For Tutorials on various Technical Topics, please visit

    All product names are trademarks of their respective companies. SAPTechnical.COM, Inc. is in no way affiliated with SAP AG.SAP, SAP R/3, R/3 software, mySAP, ABAP, BAPI, xApps, SAP NetWeaver, and and any other SAP trademarks are registered

    trademarks of SAP AG in Germany and in several other countries. Every effort is made to ensure content integrity. Use information on this site at your own risk.