{"id":29229101,"url":"https://github.com/aritra-banerjee-code/sap-abap","last_synced_at":"2025-08-24T16:34:16.998Z","repository":{"id":302572474,"uuid":"1012895072","full_name":"Aritra-Banerjee-code/SAP-ABAP","owner":"Aritra-Banerjee-code","description":"SAP ABAP- HANA","archived":false,"fork":false,"pushed_at":"2025-07-03T04:26:20.000Z","size":20,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-07-03T05:26:38.117Z","etag":null,"topics":["abap","sap","sql"],"latest_commit_sha":null,"homepage":"","language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Aritra-Banerjee-code.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-07-03T03:58:41.000Z","updated_at":"2025-07-03T04:26:22.000Z","dependencies_parsed_at":"2025-07-03T17:15:22.785Z","dependency_job_id":null,"html_url":"https://github.com/Aritra-Banerjee-code/SAP-ABAP","commit_stats":null,"previous_names":["b-aritra/sap-abap"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Aritra-Banerjee-code/SAP-ABAP","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Aritra-Banerjee-code%2FSAP-ABAP","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Aritra-Banerjee-code%2FSAP-ABAP/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Aritra-Banerjee-code%2FSAP-ABAP/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Aritra-Banerjee-code%2FSAP-ABAP/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Aritra-Banerjee-code","download_url":"https://codeload.github.com/Aritra-Banerjee-code/SAP-ABAP/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Aritra-Banerjee-code%2FSAP-ABAP/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271902791,"owners_count":24841269,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-24T02:00:11.135Z","response_time":111,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["abap","sap","sql"],"created_at":"2025-07-03T12:00:54.274Z","updated_at":"2025-08-24T16:34:16.978Z","avatar_url":"https://github.com/Aritra-Banerjee-code.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# SAP-ABAP\nSUMMER INTERNSHIP\nSAP ABAP at Exide Industries LTD\n\nBy- Aritra Banerjee\t\t\t\nUnder the Supervision of-\nMr. Indrajit Saha\n\n1.\t Problem Statement\nThe objective is to develop a custom ABAP report in SAP named ZMM_PO_REPORT_TEST to provide a comprehensive overview of the Purchase Order (PO) lifecycle in the Materials Management (MM) module. The report must retrieve and display PO data along with corresponding Goods Receipt (GR) and Invoice Receipt (IR) information in a single, integrated ALV output.\nUsers from procurement and finance departments need a unified tool to monitor the progress and status of POs, which are currently tracked through multiple transactions like SE38, SE11, ME23N and MIGO. This fragmentation creates inefficiencies and limits visibility.\nThe report should support:\n●\tFiltering based on PO number, PO date, document type, and company code.\n\n●\tA date range restriction to ensure performance and focus, limited to a maximum of 30 days.\n\n●\tIntegration of data from SAP tables:\n\n○\tEKKO, EKPO – for PO details\n\n○\tMSEG – for GR details\n\n○\tRSEG – for IR details\n\n○\tLFA1 – for vendor information\n\n●\tAn interactive ALV display that allows:\n\n○\tSubtotals and totals for quantities and invoice values\n\n○\tHotspot functionality to click on a PO number and directly navigate to ME23N for detailed PO view\n\nThis report aims to streamline procurement operations by consolidating PO, GR, and IR data into a single view, enhancing both operational efficiency and data-driven decision-making.\nREPORT NAME :- ZMM_PO_REPORT_TEST\n\nObjective\nTo develop a custom ABAP ALV report ZMM_PO_REPORT_TEST that:\n1.\tRetrieves and displays PO header and item data.\n\n2.\tTracks and shows corresponding Goods Receipts (GR).\n\n3.\tIncludes Invoice Receipt (IR) details.\n\n4.\tAllows filtering by PO number, PO date, PO type, and company code.\n\n5.\tRestricts selection date range to 30 days.\n\n6.\tProvides an interactive ALV output with:\n\n○\tSummation of quantities and invoice amounts.\n\n○\tGrouping and subtotals by PO.\n\n○\tHyperlinks for direct PO navigation.\n\n7.\tEnables accounting and purchasing users to monitor the full procurement lifecycle in one screen.\n\n\n Table of TCodes\n\nTCode\tDescription\tUsage in Report\nME23N\tDisplay Purchase Order\tTriggered via ALV hotspot\nMIGO\tGoods Receipt for PO\tSource of GR data\nSE38\tExecute ABAP Report\tRun report with selection screen\nSE11\tABAP Dictionary\tUsed to view/edit table structures like EKKO, EKPO, and to understand field definitions.\n\n\n\n\n\n\n\n\n\n\n\nOUTPUTS - \n\n \nFIG 1 - Purchase Order Details \n\n \n\t\t\tFIG 2- Purchase Order with GR and IR \n\n \n\t\tFIG 3 - Hyperlink on PO to open the ME23N\n\n\n2. Problem Statement\nThe business requires a detailed and interactive SAP report to monitor Purchase Order (PO) item histories, including Goods Receipt (GR) and Invoice Receipt (IR) transactions for each PO item. Currently, analyzing PO histories involves manually checking multiple documents via various transactions (ME23N, MIGO, MIRO) and lacks a consolidated view at the PO item level.\nTo address this gap, the custom report ZMM_PO_ITEM_HISTORY is to be developed. It should:\n●\tDisplay basic PO header and item details.\n\n●\tOn user interaction (clicking the PO number), fetch and display associated GR and IR history for a specific PO item.\n\n●\tRetrieve history using BAPI_PO_GETDETAIL to ensure accuracy and SAP standard logic.\n\n●\tShow the historical data in a popup ALV layout dynamically.\n\n●\tValidate input criteria (PO number, date range, etc.) to prevent overload and irrelevant data.\n\n●\tEnable the user to view the full lifecycle of a PO item from creation to receipt and invoice in a single interactive report.\n\nREPORT NAME :- ZMM_PO_ITEM_HISTORY \n\n\n\n\n\n\n\nTransaction Codes (Tcodes) Used in the Report\n\nTCode\tDescription\tPurpose in the Report Context\nSE38\tABAP Editor – Execute ABAP Reports\tUsed to create, edit, and run the custom report ZMM_PO_ITEM_HISTORY.\nSE11\tABAP Dictionary\tUsed to view/edit table structures like EKKO, EKPO, and to understand field definitions.\nME21N\tCreate Purchase Order\tCreates PO master and item data that the report will later retrieve and display.\nMIGO\tGoods Movement (GR)\tPosts Goods Receipts for POs. GR data shown in the popup is based on MIGO transaction entries.\n\nFunction Modules Used\n 1. BAPI_PO_GETDETAIL\n●\tPurpose: Fetches complete details of a Purchase Order including item history.\n\n●\tUsed For:\n\n○\tRetrieving GR and IR history records via the PO_ITEM_HISTORY internal table.\n\n○\tEnsures data consistency as this BAPI uses SAP’s internal logic.\n○\t\n\n●\tParameters Used:\n\n○\tPURCHASEORDER = wa_final-ebeln\n\n○\tHISTORY = 'X'\n\n○\tReturns data in PO_ITEM_HISTORY structure (BAPIEKBE type)\n\n●\tAdvantage:\n SAP-standard BAPI which includes validated and up-to-date data. Avoids directly joining complex history tables (MKPF, MSEG, RBKP, RSEG).\n\n2. REUSE_ALV_GRID_DISPLAY\n●\tPurpose: Display the main PO report in an interactive ALV grid.\n\n●\tUsed For:\n\n○\tShowing the list of PO items.\n\n○\tSupporting sorting, totaling (EKPO_MENGE), and hotspot click on PO number.\n\n3. REUSE_ALV_POPUP_TO_SELECT\n●\tPurpose: Display the GR/IR item history for a PO item in a popup screen.\n\n●\tUsed For:\n\n○\tCompact display of BAPIEKBE history data (GR and IR) when user clicks on PO number.\n\n○\tSelection screen is non-editable (i_allow_no_selection = 'X')\nCore Functional Flow\n1.\tSelection Screen:\n\n○\tInput: PO number range, PO date, PO type, company code.\n\n○\tValidations: Date range ≤ 30 days, PO range ≤ 600 numbers.\n\n2.\tMain ALV Output:\n\n○\tDisplay PO header and item details from EKKO, EKPO.\n\n3.\tOn Hotspot Click (PO Number):\n\n○\tBAPI BAPI_PO_GETDETAIL is called with a history flag.\n\n○\tPO item-wise GR and IR history retrieved and filtered.\n\n○\tResult shown in a popup ALV via REUSE_ALV_POPUP_TO_SELECT.\n\n\n\nOUTPUTS : \n \nFIG 1- PO Item History\n \nFIG 2 -  Hyperlink on PO to show GR history \n\n\n \nFIG 3 - Hyperlink on PO to show IR history\n\n\n\n\n\n\n\n\n\n3.  Problem Statement\nIn many business scenarios, there is a need to upload bulk data from Excel files into SAP for validation, reporting, or further processing. Manual entry of such data can be time-consuming, error-prone, and inefficient.\nTo address this, the report ZMM_UPLOAD_REPORT is developed to provide a simple Excel file upload interface in SAP, allowing users to:\n●\tUpload an Excel file from the local system.\n\n●\tConvert its contents into an internal table using the standard SAP function module.\n\n●\tDisplay the uploaded data in a clean ALV Grid output for review or further processing.\n\nREPORT NAME - ZMM_UPLOAD_REPORT\n\n Features of the Report\n●\tFile selection popup (F4_FILENAME) to pick an Excel file from desktop.\n\n●\tUpload of .xls format Excel files (not .xlsx).\n\n●\tData conversion using SAP function module TEXT_CONVERT_XLS_TO_SAP.\n\n●\tALV output display of uploaded data in columns like:\n\n○\tMessage ID\n\n○\tName\n\n○\tMessage Type\n\n○\tMessage Number\n\n\n\nTransaction Codes (Tcodes) Used\nTCode\tDescription\tUsage in the Report\nSE38\tABAP Editor / Report Execution\tUsed to create, modify, and execute the report ZMM_UPLOAD_REPORT.\nSE11\tData Dictionary\tUsed to define and view structures, data types (like RLGRAP-FILENAME) used in the report.\n\n\n\nOUTPUT - \n\n \nFIG 1- Excel file upload\n \nFIG 2 - Execution of the Excel file\n\n\n\n\n4.  Problem Statement\n\nIn SAP MM, Purchase Orders (POs) are crucial for procurement, but creating them manually in ME21N is time-consuming, especially when dealing with bulk POs involving multiple line items and account assignments.\nThis program solves the problem by:\n●\tAllowing bulk creation of POs by uploading data from an Excel spreadsheet.\n\n●\tProcessing both header and item-level data, including account assignments.\n\n●\tUsing BAPI_PO_CREATE1 to create the POs programmatically.\n\n●\tLogging and displaying system return messages (success or failure) in the report output.\nREPORT NAME - ZMM_UPLOAD_REPORT_2\nTransaction Codes (Tcodes) Used\nTCode\tDescription\tPurpose in Context\nSE11\tData Dictionary\tTo inspect tables like EKKO, EKPO, EKNK, SANKR, etc.\nME21N\tCreate Purchase Order\tStandard SAP Tcode for manual PO creation (replaced here by automation).\nSE37\tFunction Module Editor\tTo view/test function modules like BAPI_PO_CREATE1, etc.\n\n Function Modules Used and Their Purpose\n\n\nFunction Module\tPurpose\nF4_FILENAME\tProvides file selection popup for choosing Excel file path\nTEXT_CONVERT_XLS_TO_SAP\tConverts Excel file data into internal table\nCONVERSION_EXIT_ALPHA_INPUT\tEnsures numeric values like vendor numbers, GL accounts have leading zeros\nBAPI_PO_CREATE1\tMain BAPI used to create Purchase Orders in SAP\nBAPI_TRANSACTION_COMMIT\tCommits the transaction after successful PO creation\n5 . Problem Statement \nIn SAP Materials Management (MM), once a Purchase Order (PO) is created and goods are physically received, a Goods Receipt (GR) must be posted to update stock and initiate payment processes. While GRs can be created using standard TCodes like MIGO, doing so manually for large numbers of PO items or via custom automation can be inefficient.\nTo simplify this, the report ZMM_GR_CREATION allows the user to:\n●\tEnter a PO number, item, and posting dates.\n\n●\tAutomatically fetch PO item details from SAP.\n\n●\tCall BAPI_GOODSMVT_CREATE to post a GR with movement type 101.\n\n●\tDisplay success or failure messages in an ALV report using the OO ALV (Object-Oriented ALV Grid).\n\nREPORT FILE - ZMM_GR_CREATION\nTransaction Codes (Tcodes) Used\nTCode\tDescription\tUsage in This Report\nSE38\tABAP Editor\tUsed to create, edit, and run the custom report ZMM_GR_CREATION.\nSE11\tData Dictionary\tUsed to explore the table structures like EKPO and data elements used in parameters.\nSE37\tFunction Builder\tTo view and test function modules like BAPI_GOODSMVT_CREATE and BAPI_TRANSACTION_COMMIT.\nMIGO\tGoods Movement\tStandard SAP TCode to post GR. This program replicates its core functionality programmatically.\nFunction Modules Used\nFunction Module\tPurpose in Code\nBAPI_GOODSMVT_CREATE\tPosts the Goods Receipt document based on PO item data.\nBAPI_TRANSACTION_COMMIT\tCommits the transaction to finalize the GR document in SAP.\nBAPI_TRANSACTION_\nROLLBACK\tRolls back the transaction in case of any error during GR creation.\n\n\n\n\n\n6.  Problem Statement\nThe goal is to design and implement a Module Pool SAP ABAP program (ZLIB_MP_2) for managing a Library System within an organization. The application should enable users to create, edit, and view records related to:\n1.\tLibrary Master Data\n\n2.\tBook Master Data\n\n3.\tBook Issue Transactions\n\nThe system must handle user interactions through custom SAP screens using dialog programming. It should support:\n●\tData validation and processing via user commands (sy-ucomm)\n\n●\tScreen navigation and status handling using CALL SCREEN\n\n●\tIntegration with custom transparent tables:\n\n○\tYLIBY_MASTER – for library details\n\n○\tYLIB_BOOK_MASTER – for book metadata\n\n○\tYSTD_MASTER – for book issue and return history\n\nThe system will be accessed using custom transaction codes and must be user-friendly, ensuring accurate data maintenance for the library and supporting all common operations such as insert, update, and display from the same program.\n\nStep-by-Step Implementation:\n🔹 Step 1: Create Custom Tables (Data Dictionary)\nUse T-Code: SE11\nCreate the following transparent tables:\n1.\tYLIBY_MASTER – Library master data\n\n○\tFields: LIBY_ID,  LIBY_NAME .\n\n2.\tYLIB_BOOK_MASTER – Book master data\n\n○\tFields: BOOK_ID , BOOK_NAME , BOOK_ATHR , BOOK_PBLSH. \n\n3.\tYSTD_MASTER – Student Details Master\n\n○\tFields: STD_ID ,STD_NAME , STD_DPRT, STD_SEM. \n\nSave and activate all tables.\nStep 2: Create the Module Pool Program\nUse T-Code: SE38\n Program Name: ZLIB_MP_2\n●\tSet program type as \"Executable Program\".\n\n●\tUse INCLUDE statements for screen logic:\n\n○\tZLIB_MP_2_STATUS_0100O01, ZLIB_MP_2_USER_COMMAND_0100I01 – for screen 100 logic\n\n○\tZLIB_MP_2_STATUS_0200O01, ZLIB_MP_2_USER_COMMAND_0200I01 – for screen 200 logic\n\n\n🔹 Step 3: Create Screens\n\n Create two screens:\n🔸 Screen 100 – Library \u0026 Book Master\n●\tElements: Input fields for YLIBY_MASTER\n\n●\tButtons: SAVE, DISPLAY, BACK\n\n●\tLogic handled via MODULE status_0100 OUTPUT and MODULE user_command_0100 INPUT\n\n🔸 Screen 200 – Book Issue Screen\n●\tElements: Input fields from YSTD_MASTER\n\n●\tButtons: ISSUE BOOK, BACK\n\n●\tLogic handled via MODULE status_0200 OUTPUT and MODULE user_command_0200 INPUT\n\n🔹 Step 4: Define Transaction Codes\n Create the following custom TCodes:\nTCode\tFunction\tScreen\nYLIB_1\tInsert Library/Book\t100\nYLIB_2\tEdit/Update Library/Book\t100\nYLIB_3\tDisplay Library/Book\t100\n🔹 Step 5: PF-Status and Titlebar\n●\tCreate status PF-STATUS_100 and PF-STATUS_200\n\n○\tButtons: SAVE, BACK, DISPLAY, EXIT, etc.\n\n\n🔹 Step 6: Write Logic in Includes\nInside includes like ZLIB_MP_2_USER_COMMAND_0100I01, implement:\n●\tData validation\n\n●\tInsert/update logic using INSERT, MODIFY, or SELECT\n\n●\tNavigation handling with CALL SCREEN or LEAVE PROGRAM\n\n🔹 Step 7: Testing\nUse your defined TCodes (YLIB_1, YLIB_2, YLIB_3) to:\n●\tInsert library \u0026 book details\n\n●\tIssue a book to a student\n\n●\tDisplay entries for verification\n\n\n\n\n\nT-Codes Used and Their Purposes\nTCode\tUsed For\tDescription\nSE11\tData Dictionary\tCreate and activate transparent tables: YLIBY_MASTER and YLIB_BOOK_MASTER.\nSE38\tABAP Editor\tCreate the module pool program ZLIB_MP_2 and include screens and logic.\nYLIB_1\tInsert Mode (Screen 100)\tAllows users to input and save new library and book records.\nYLIB_2\tEdit Mode (Screen 100)\tAllows users to fetch and update existing records based on primary keys.\nYLIB_3\tDisplay Mode (Screen 100)\tShows all details of the records in read-only mode for review purposes.\nOUTPUTS : \n \nFIG 1- YLIB_1 - Library Data insert\n\n \nFIG 2 - YLIBY_MASTER data entries\n(Library data insert successful)\n\n \nFIG 3- YLIB_2 - Library Data updated\n\n\n \nFIG 4 - YLIBY_MASTER data entries\n(Library data update successful)\n\n\n\n\n \nFIG 3- YLIB_3 - Library Data display\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faritra-banerjee-code%2Fsap-abap","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faritra-banerjee-code%2Fsap-abap","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faritra-banerjee-code%2Fsap-abap/lists"}