Item wise total quantity prob

hi experts,
i made an alv,which shows o/p like this:
truckno(likp-traid)| dono(likpvbeln)|party nm(kna1-name1)|skucode(lips-arktx)| qty(lips-lfimg)
wb03-7809         |  80000345       | msaha                      |  frooti_pet            |   40,000  cs
wb03-7809         |  80000346      | msaha                      |  frooti_ tetra          |   20,000  cs
wb03-7809         |  80000345       | msaha                      |  appy1 ltr             |   60,000  cs,
but client requirement is that,
they need item wise total ie say, frooti_pet       is assigned against dono(80000345), bt this item can also be assigned against another do say(80000389) with sum qty in it.
they want total sum of a particular skucode(item) means  frooti_pet(item wise)  , that may be assigned in diff dono  , but duff dono may be assigned in same truck
o/p will show,
like
truck no| skucode| total(partycular item wise).
how to do it?
thnx in advance.

Declare the fields in the internal table in the below order.
dono(likpvbeln)|
skucode(lips-arktx)|
truckno(likp-traid)|
party nm(kna1-name1)|
qty(lips-lfimg)
Above the loop sort the internal table as follows.
Sort itab by dono skucode.
Loop at itab.
at end of skucode.
sum.
here move the Quantity  to another variable.
endat.
endloop.
Edited by: Poorna Chandrasekhar on Jan 23, 2009 12:07 PM

Similar Messages

  • How to find item wise totals and header wise total using hierarchical ALV

    Hi Friends,
    I came across an issue of finding  item wise total using hierarchical ALV. I am getting header wise total by setting the field catalog. May you help me in finding  Item wise total.
    Regards
    Nikhil.

    hi,
    you must use "w_fieldcat-do_sum = 'X'" and change your layout like :
    w_sort-fieldname = 'FIELD'.
      w_sort-tabname   = 'TABNEME'.
      w_sort-up        = 'X'.
      w_sort-subtot    = 'X'.
      APPEND w_sort TO i_sort.
      CLEAR w_sort.
    you can use detailed code from http://wiki.sdn.sap.com/wiki/display/Snippets/Subtotalsinhirarchial+report.
    regards,
    orhan
    Edited by: goktasor on Jun 1, 2010 11:03 AM (need points : ) )

  • Line item wise billing

    Hi All,
    Can we do sale order related billing for individual line item wise and quantity wise?
    If this is for delivery related billing then the setting will be in item category, billing relevance as K. But what will be the settings for order related billing?
    Kumar

    Hi,
    In two ways you can achieve your requirement.
    1.Goto the T.Code VF01
    Enter your sales order number.Donot press Enter.
    Click on "Selection list".
    Select your items.Click on Copy.
    Save the invoice.In "VOV7" T.Code maintain the billing relevance as "C".
    2.Goto the T.Code "VA02".
    Double click on the item.Goto Billing document tab.
    Maintain the billing block under "Billing" tab.
    Save.
    Goto the T.Code "VF01".Enter your order number.
    Create the billing document.
    Next Goto VA02 and remove the another block.
    Create the invoice.
    Regards,
    Krishna.

  • How to get Item-Code wise stock quantity and value for a previous date

    Dear Sir,
    As per the government legal requirement , we are required to furnish a list for items having stock as on a date ( date is not the current date but it is some past date)  and  in the list we need to provide material wise stock quantity and value .
    We can generate a list  for the current date , but do not know how to get it for a previous date .
    We request you to kindly guide us about such a list .
    With Thanks and Regards
    Sonia Agarwal

    hi,
    might be this reports will be help full for your requirement.
    MMBE
    MB53
    MB52
    MB5M
    MB5B
    MB5T
    MBLB
    MBBS
    MB54
    ME56
    Thanking you

  • I want to check/see the total quantity of items from fixed asset module

    Dear All,
    When I create purchase requisitions or purchase order, at the time of selection of items (Printer etc)…
    I want to check/see the total quantity of items from fixed asset module.
    Please guide, me how can I see the total items are available in fixed assets, on purchase order
    Product Detail
    Database Server
    RDBMS : 10.2.0.5.0
    Oracle Applications : 11.5.10.2
    Machine : ofadb.thecityschool.edu.pk
    User : APPS
    Oracle SID : PROD
    System Date : 16-APR-2012 13:27:37
    Database Server PID : 13485
    Session SID : 1437
    SERIAL# : 12175
    AUDSID : 32767692
    Database CPU Usage (in secs) : 0.69
    Regards

    Oracle does not offer this functionality.
    You will have to write a personalization that will query FA based on the item and display the message to the user.
    To invoke this personalization, the user may have to go to tools > show FA. This Show FA is a new option you create by personalization.
    Sandeep Gandhi

  • Create item delivery with zero or total quantity (even if available stock)

    Hello!!
    My requirement is create a item delivery with zero or total quantity, but not only the stock available at this moment. The item only will have 2 possibilities: 0 quantity or total quantity of the sales order.
    Example of the current process:
    Material M-10: Stock available: 2
    M-10: Item in sales order: 6
    M-10: Item in delivery: 2  --> should be 0!!!
    Material M-20: Stock available: 10
    M-20: Item in sales order: 5
    M-20: Item in delivery: 5
    In M-10, quantity in item delivery should be 0. (my category item delivery allows quantity 0).
    Do you know if there is some customizing for this requirement? All quantity from sales order or 0 in delivery item.
    Thanks in advance,
    Jen

    Hi,
    for complete delivery:
    Entering the Indicator
    There are two places where you can enter this indicator:
    Customer master record
    This indicator belongs to the shipping data for a customer within a sales area. You enter an X in the Complete Delivery field on the shipping screen of the customer master record. The indicator is copied into the order header.
    Order header
    You can also enter the indicator X in the Delivery field on the business data screen of the order header.
    If you try to partially deliver an order to which you have assigned a complete delivery indicator, the system will inform you that the customer requires complete delivery of the order. All items must be delivered at the same time. The items cannot have different delivery deadlines.
    If the system cannot include all the items with the total order quantity in the delivery, you receive a message that the customer requires full delivery.
    If you enter the complete delivery indicator X, you must set the partial delivery indicator to C (no partial deliveries allowed).

  • Calculate price on the basis of total quantity of line items.

    Hi,
    I have a scenario.
    One product is selling at premium price to the standard product.When customer buy both premium product and standard product the price break up should be on the total quantity of the both products.
    How to achieve it in SAP sales order?
    debajyoti

    Please have a look at standard 'group condition' functionality, it might solve your problem:
    http://help.sap.com/erp2005_ehp_05/helpdata/EN/1c/8c8b518d8c11d199a30000e8a5bd28/frameset.htm
    You have to carry out some settings for the condition type you want to use:
    SPRO > Sales and Distribution > Basic Functions > Pricing > Pricing Control > Define Condition Types - here choose 'Maintain Condition Types'
    - V_T685A-GRMEN
    - V_T685A-KGRPE
    - V_T685A-GRLNR

  • Line item wise Qty in Handling Unit Management

    Dear All,
    I am working and testing Handling Unit Management. As per the client requirement, he wants Multilevel Packaging (Manually) for materials as-
    E.g. 100 Pieces will be packed in 1 Small Carton.
           100 Small Cartons will be packed in 1 Big Carton.
           10 Big Cartons will be packed in 1 Pallet.
    Now while creating delivery I packed 2 materials separately. And in the item level it is showing as a whole, means total 1100 PC packed in 11 Small carton, 11 Small cartons packed in 5 Big cartons and 5 Big cartons packed in 2 Pallets. Please find the below screen shot.
    Now when I check this delivery number in tables LIPS-VBELN, it is showing the entire qty of Small carton, Big carton and Pallets as 11, 5, 2 respectively. But actually it has show each material or line item wise No. of Small carton, Big carton and pallet used.
    E.g. For 1st material Small Boxes = 5
                                   Big Carton = 2
                                   Pallet = 1
          For 2nd material Small Boxes = 6
                                   Big Carton = 3
                                   Pallet = 1
    My question is, is there any table or logic where I can fetch all these details for all material that how many packaging material and qty has been used. Because in packing list the same needs to get printed each line item wise. I checked in VEPO and VEKP table as well but not getting any input.
    Kindly help.
    Regards:
    Abhishek

    First of all, why you don't have any quantities assigned against Small cartons, big cartons and pallets?
    Well, for your requirement. As functional consultant, you should be smart enough to interpret & analysis the data when you have tables and data in hand. Anyways, in your case,
    As Pallet is the highest level pack material.
    Pass HU no of pallet in VEKP- EXIDV, in your case for one of the pallet, it is 1000013558.
    For that you will get, Internal HU no. VEKP-VENUM, say, 86.
    Pass VEKP-VENUM = VEPO-VENUM.
    With that you will get Lower-level HU, VEPO-UNVEL, that will be internal HU No for Big Cartons & VEPO-VEANZ for packing material quantity.
    Then pass VEPO-UNVEL = VEPO-VENUM, by this you will get internal HU No for Small Cartons in VEPO-UNVEL & VEPO-VEANZ for packing material quantity.
    Again, pass VEPO-UNVEL = VEPO-VENUM, by this you will get following info:
    Table - Fields
    Field Desc
    VEPO-VEPOS
    HU item
    VEPO-VBELN
    Delivery
    VEPO-POSNR
    Delivery Item
    VEPO-VEMNG
    Packed quantities
    Try and share your feedback.
    Thanks, JP

  • Query for Item wise sales report

    Hi Guys,
    Below is the query i have used to run Sales Register.
    But we need Item wise sales register  and those Excise Duty calculations are needed for item wise instead of total document wise. Pls update the query ...
    SELECT M.DocNum AS 'Inv.No ', M.DocDate as 'Date', M.CardName as 'Customer Name',L.Dscription,L.Quantity,L.Price,
    (Select Sum(LineTotal) FROM INV1 L Where L.DocEntry=M.DocEntry) as 'Base Amt.(Rs.)',
    (SELECT Avg(TaxRate) FROM INV4 where statype=1 and DocEntry=M.DocEntry) as ' VAT % ',
    (SELECT Sum(TaxSum) FROM INV4 where statype=1 and DocEntry=M.DocEntry) as ' VAT (Rs.) ',
    (SELECT Avg(TaxRate) FROM INV4 where statype=4 and DocEntry=M.DocEntry) as ' CST % ',
    (SELECT Sum(TaxSum) FROM INV4 where statype=4 and DocEntry=M.DocEntry) as ' CST (Rs.) ',
    (SELECT Avg(TaxRate) FROM INV4 where statype=7 and DocEntry=M.DocEntry) as ' TAXEXEMPT % ',
    (SELECT Sum(TaxSum) FROM INV4 where statype=7 and DocEntry=M.DocEntry) as ' TAXEXEMPT ',
    (SELECT Avg(TaxRate) FROM INV4 where statype=8 and DocEntry=M.DocEntry) as ' VAT% ',
    (SELECT Sum(TaxSum) FROM INV4 where statype=8 and DocEntry=M.DocEntry) as 'VAT12.5 ',
    (SELECT Avg(TaxRate) FROM INV4 where statype=9 and DocEntry=M.DocEntry) as ' CST 2% ',
    (SELECT Sum(TaxSum) FROM INV4 where statype=9 and DocEntry=M.DocEntry) as ' CST @2 ',
    (SELECT Avg(TaxRate) FROM INV4 where statype=11 and DocEntry=M.DocEntry) as ' CENVCST % ',
    (SELECT Sum(TaxSum) FROM INV4 where statype=11 and DocEntry=M.DocEntry) as ' CENVCST ',
    (SELECT Avg(TaxRate) FROM INV4 where statype=-90 and DocEntry=M.DocEntry) as ' BED % ',
    (SELECT Sum(TaxSum) FROM INV4 where statype=-90 and DocEntry=M.DocEntry) as ' BED ',
    (SELECT Avg(TaxRate) FROM INV4 where statype=-60 and DocEntry=M.DocEntry) as ' Cess% ',
    (SELECT Sum(TaxSum) FROM INV4 where statype=-60 and DocEntry=M.DocEntry) as ' Cess ',
    (SELECT Avg(TaxRate) FROM INV4 where statype=-55 and DocEntry=M.DocEntry) as ' HCess % ',
    (SELECT Sum(TaxSum) FROM INV4 where statype=-55 and DocEntry=M.DocEntry) as ' Hcess ', L.LineTotal as 'Row Total (Rs.)',M.DocTotal as 'Doc Total'
    FROM OINV M LEFT OUTER JOIN INV1 L on L.DocEntry=M.DocEntry LEFT OUTER JOIN INV4 T on T.DocEntry=L.DocEntry and L.LineNum=T.LineNum LEFT OUTER JOIN INV5 J ON M.DocEntry = J.AbsEntry LEFT OUTER JOIN INV3 Q ON M.DocEntry = Q.DocEntry
    WHERE (M.DocDate >= '[%0]' AND M.DocDate <= '[%1]') AND TargetType ! = 14
    GROUP BY M.DocNum,M.DocDate,M.CardName,M.NumAtCard,M.DocEntry,M.DiscSum,M.WTSum,L.Dscription,L.Quantity,L.Price,L.LineTotal,M.DocTotal
    ORDER BY M.DocNum,M.DocDate,M.CardName,M.NumAtCard,M.DocEntry,M.DiscSum,M.WTSum,L.Dscription,L.Quantity,L.Price,L.LineTotal,M.DocTotal

    Hi experts..
    Pls   Update the Query

  • Item wise consumption

    Hi Gurus,
    My client has R.M. Consumption A/c, R.M. stock Gain & Loss A/c, PRD Loss & Gain A/C, Revaluation Gain & Loss A/C & Legacy R.M. A/C.. In these accounts quantity & Value are mismatching & debit & credit balance are not equal. So please suggest me how can i maintain all of above accounts balance equal & quantity equal. please advise me. my client wants item wise consumption.
    Regards,
    Manas

    Hi,
    KOB1 shows only postings on internal orders, while FS10N shows total postings on G/L account. That is if you have postings on this account for other CO obejcts (cost centre, WBS, etc.), then you'll obviously have difference.
    Regards,
    Eli

  • Query for Item wise Sales.......

    *Hi Guys, Below is the query i have used to run Sales Register. But we need Item wise sales register and those Excise Duty calculations are needed for item wise instead of total document wise.
    Pls update the query ...*
    SELECT M.DocNum AS 'Inv.No ', M.DocDate as 'Date', M.CardName as 'Customer Name',L.Dscription,L.Quantity,L.Price, (Select Sum(LineTotal) FROM INV1 L Where L.DocEntry=M.DocEntry) as 'Base Amt.(Rs.)', (SELECT Avg(TaxRate) FROM INV4 where statype=1 and DocEntry=M.DocEntry) as ' VAT % ', (SELECT Sum(TaxSum) FROM INV4 where statype=1 and DocEntry=M.DocEntry) as ' VAT (Rs.) ', (SELECT Avg(TaxRate) FROM INV4 where statype=4 and DocEntry=M.DocEntry) as ' CST % ', (SELECT Sum(TaxSum) FROM INV4 where statype=4 and DocEntry=M.DocEntry) as ' CST (Rs.) ', (SELECT Avg(TaxRate) FROM INV4 where statype=7 and DocEntry=M.DocEntry) as ' TAXEXEMPT % ', (SELECT Sum(TaxSum) FROM INV4 where statype=7 and DocEntry=M.DocEntry) as ' TAXEXEMPT ', (SELECT Avg(TaxRate) FROM INV4 where statype=8 and DocEntry=M.DocEntry) as ' VAT% ', (SELECT Sum(TaxSum) FROM INV4 where statype=8 and DocEntry=M.DocEntry) as 'VAT12.5 ', (SELECT Avg(TaxRate) FROM INV4 where statype=9 and DocEntry=M.DocEntry) as ' CST 2% ', (SELECT Sum(TaxSum) FROM INV4 where statype=9 and DocEntry=M.DocEntry) as ' CST @2 ', (SELECT Avg(TaxRate) FROM INV4 where statype=11 and DocEntry=M.DocEntry) as ' CENVCST % ', (SELECT Sum(TaxSum) FROM INV4 where statype=11 and DocEntry=M.DocEntry) as ' CENVCST ', (SELECT Avg(TaxRate) FROM INV4 where statype=-90 and DocEntry=M.DocEntry) as ' BED % ', (SELECT Sum(TaxSum) FROM INV4 where statype=-90 and DocEntry=M.DocEntry) as ' BED ', (SELECT Avg(TaxRate) FROM INV4 where statype=-60 and DocEntry=M.DocEntry) as ' Cess% ', (SELECT Sum(TaxSum) FROM INV4 where statype=-60 and DocEntry=M.DocEntry) as ' Cess ', (SELECT Avg(TaxRate) FROM INV4 where statype=-55 and DocEntry=M.DocEntry) as ' HCess % ', (SELECT Sum(TaxSum) FROM INV4 where statype=-55 and DocEntry=M.DocEntry) as ' Hcess ', L.LineTotal as 'Row Total (Rs.)',M.DocTotal as 'Doc Total' FROM OINV M LEFT OUTER JOIN INV1 L on L.DocEntry=M.DocEntry LEFT OUTER JOIN INV4 T on T.DocEntry=L.DocEntry and L.LineNum=T.LineNum LEFT OUTER JOIN INV5 J ON M.DocEntry = J.AbsEntry LEFT OUTER JOIN INV3 Q ON M.DocEntry = Q.DocEntry WHERE (M.DocDate >= '[%0]' AND M.DocDate <= '[%1]') AND TargetType ! = 14 GROUP BY M.DocNum,M.DocDate,M.CardName,M.NumAtCard,M.DocEntry,M.DiscSum,M.WTSum,L.Dscription,L.Quantity,L.Price,L.LineTotal,M.DocTotal ORDER BY M.DocNum,M.DocDate,M.CardName,M.NumAtCard,M.DocEntry,M.DiscSum,M.WTSum,L.Dscription,L.Quantity,L.Price,L.LineTotal,M.DocTotal

    Closing this ...
    Edited by: Parimis on Jun 25, 2010 5:44 PM

  • How to add Total Quantity in Inbound and Outbound Delivery screen

    Hi,
    I want to add Total quantity field in Inbound and Outbound Delivery screens.
    In document flow i can see the line item quantities in ALV Format, but if i select Display the totals above the entry check box
    in Change Layout--> Display, i didn't see any totals displayed.
    Please help me on this?
    Regards
    Bhuvana

    Hi
    If the field is a customer field, see BADI 'LE_SHP_TAB_CUST_HEAD'
    Regards
    Eduardo

  • XML Publisher - Page Wise Total

    We are facing problem in incorporating ‘Page Wise Total’ in Invoice Report - Invoices print at format CAP_ETA for Germany. It an XML Report and its output appear in PDF format. As per the new requirement sent by L1 team, we are required to make changes in RTF, to show ‘Page Wise Total’.
    We have worked on this enhancement but unable to display ‘Page Wise Total’. We are able to display Sum Total of all the records appeared in three different blocks of records for that particular page at the end of the footer of Page, but not yet able to SUM UP total of these three Sum Total of three different blocks on that particular page.
    For e.g. First page of my XML Report display three different Block of data as shown below with Subtotal of 38,600.00, 4,453.47 for 1st and 2nd Block respectively, but 3rd block records appeared partially on the first page and remaining appeared on the next page. So My Report should display ‘Page Wise Total’ or ‘Amount Forward’ as 52853.47, which sholud be carried forward to next page as ‘Amount Forward’ - 52853.47. The next page/second page will dispaly the remaing line records of the 3rd block and Subtotal( Please see attachment New_Layout_Invoice_TUM_English.doc)
    Name Description Unit Quantity Price Amount in Euro
    Rösner Fees Day 17.00 1,400.00 23,800.00
    Schreiber, Clemens Fees Day 2.00 1,400.00 2,800.00
    Slegers, Arnd Fees Day 4.00 1,400.00 5,500.00
    Weiler, Andreas Fees Day 4.00 1,400.00 6,400.00
    Subtotal: 27.00 38,600.00
    Römer, Michael Expenses 2,253.79
    Schreiber, Clemens Expenses 157.69
    Slegers, Arnd Expenses 519.78
    Weiler, Andreas Expenses 1,522.21
    Subtotal: 4,453.47
    Rösner, Michael Travel expenses 2,400.00
    Schreiber, Clemens Travel expenses 2,000.00
    Siegers, Arndt Travel expenses 1,800.00
    Weiler, Andreas Travel expenses 2,000.00
    Marek, Gruchala Travel expenses 1,600.00
    Amount forward 52853.47
    As mentioned above we are able to show independently three different Page Wise Total of each of these blocks by using syntax:
    <?add-page-total:block1amount;’L_AMOUNT’?>, this syntax is used to sum up all the line records appeared in a block for a particular page and
    <?show-page-total: block1amount;’#####.##0,000’;’ ###.##0,000)’?> is used to display the Sum Total calculated by above syntax.
    But we are not able to further sum up all these Page Wise Total of different blocks.
    Please find attached copy of RTF file from Production (V18_CAR253E1), copy of RTF (V18_CAR253E1_TEST Where we are testing these new changes) and .out XML output file.
    I need help on this issue
    Thanks & Regards,
    Praveen S Negi
    [email protected]
    91-09930799325

    Hi Praveen,
    You got the solution for page total in Invoice Report in XML publisher report.
    Can you pls help regarding the same, i want to display total amount in the invoice report.
    Thanks in advance,
    Sunny

  • 'Maintain serial numbers for total quantity error in bapi_goodsmvt_create

    HI Experts,
    I am doing a goods movement programatically by using BAPI_GOODSMVT_CREATE.
    Though I am passing the serial no. for the document item still I am getting an error: 'Maintain serial numbers for total quantity'.
    My code goes like this:
    *-- Read all the items for the item category belonging to the plant
         loop at lt_lips into lw_lips where pstyv is not initial.
    *-- Process the goods movement -  Fill the data
              lw_gmvt-material = lw_lips-matnr.
              lw_gmvt-plant = lw_cat-werks.
              lw_gmvt-stge_loc = lw_cat-lgort.
              lw_gmvt-batch = lw_lips-charg.
              lw_gmvt-move_type = lw_cat-bwlvs.
              lw_gmvt-customer = <st_xvbpa>-kunnr.
              lw_gmvt-s_ord_item = lw_lips-posnr.
              lw_gmvt-entry_qnt = lw_lips-lfimg.
              lw_gmvt-entry_uom = lw_lips-meins.
              lw_gmvt-entry_uom_iso = lw_lips-meins.
             lw_gmvt-ref_doc = xlikp-vbeln.
              lw_gmvt-quantity = lw_lips-lfimg.
              lw_gmvt-base_uom = lw_lips-meins.
              append lw_gmvt to lt_gmvt.
              clear: lw_gmvt.
    BOC for serial numbers
              if lt_ser02 is not initial and lt_objk is not initial.
                clear: lw_ser02,
                       lw_objk.
                read table lt_ser02 into lw_ser02 with key sdaufnr = cvbak-vbeln
                                                           posnr = lw_lips-posnr
                                                           sd_postyp = lw_lips-pstyv binary search.
                if sy-subrc = 0.
                  read table lt_objk into lw_objk with key obknr = lw_ser02-obknr binary search.
                  if sy-subrc = 0.
    *-- Check if serial number is populated
                  if lw_objk-sernr is not initial.
    *-- Fill the serial number table for BAPI movement
                      clear: lw_sno.
                      lw_sno-matdoc_itm = lw_lips-posnr.
                      lw_sno-serialno = lw_objk-sernr.
                      append lw_sno to lt_sno.
                  endif. "Serial number not initial
                  endif. "OBJK read
                endif. "SER02 read
              endif. "SER02 and OBJK is not initial
    EOC for serial numbers
            endif. "Category table read
            clear: lw_cat, lw_lips.
         endloop.
    *-- Execute the BAPI only if item table is filled on the above condition
         if lt_gmvt is not initial.
    *-- Fill the header details
            lw_header-pstng_date = xlikp-erdat.
            lw_code-gm_code = lc_03.
    CALL FUNCTION 'BAPI_GOODSMVT_CREATE'
              EXPORTING
                GOODSMVT_HEADER               = lw_header
                GOODSMVT_CODE                 = lw_code
               IMPORTING
                MATERIALDOCUMENT              = lv_mblnr
                MATDOCUMENTYEAR               = lv_mjahr
              TABLES
                GOODSMVT_ITEM                 = lt_gmvt
                GOODSMVT_SERIALNUMBER         = lt_sno
                RETURN                        = lt_return.
    Please suggest.
    Regards,
    Sangeeta.

    Hi Banerjee,
    Actually we are trying to use the same bapi from se37, we are passing all the details which is required to process the bapi_goodmvt_create. But still the bapi returning the same error what sangeeta got in the above. Can you please guide me how to achieve this.
    how the values has to pass to the Serial Number?
    What exactly meant by Counter Values ?
    Regards,
    Siva

  • Project code based  Sales Order and Purchase Order - Item wise Report

    Dear all,
    Scenario:
    We are doing business based on Projects.  So, for every Sales , Project code is created and Sales order is booked with Project code and subsequently Purchase Order is booked with Project code. (Note:Some cases, few items might not be purchased since stock is available.)
    We want report like
    SO Project code
    SO Posting date
    SO Sales Employee
    SO Customer Name
    SO Item code
    SO Quantity
    SO Unit price
    SO Row Total
    PO Project code
    PO Posting date
    PO Sales Employee
    PO Customer Name
    PO Item code
    PO Quantity
    PO Unit price
    PO Row Total
    *SO line item and PO line item for same project should be parallel , that is important and challenge (certain cases, item in SO might not be in PO, for such cases Blank field should appear for PO Item code.)
    Thanks in advance,
    Regards,
    Dwarak.

    Hi Dwarak.......
    Your Report is right but a small change you have to make Left join RDR1 with POR1........
    Try this.......
    SELECT T0.PrjCode, T1.Project, T0.PrjName, T1.DocNum, T1.DocDate, T1.CardName, T2.ItemCode, T2.Dscription, T2.Quantity, T2.Price, T2.LineTotal, T3.Project, T4.ItemCode, T4.Dscription, T4.Quantity, T4.Price, T4.LineTotal FROM OPRJ T0 INNER JOIN ORDR T1 ON T0.PrjCode = T1.Project INNER JOIN RDR1 T2 ON T1.DocEntry = T2.DocEntry LEFT JOIN OPOR T3 ON T0.PrjCode = T3.Project LEFT OUTER JOIN POR1 T4 ON T3.DocEntry = T4.DocEntry AND T2.ITEMCODE = T4.ITEMCODE INNER JOIN OITM T5 ON T2.ItemCode = T5.ItemCode WHERE T0.PrjCode ='[%0]' AND
    T5.ItmsGrpCod in ('108', '110') GROUP BY T0.PrjCode, T1.Project, T0.PrjName, T1.DocNum, T1.DocDate, T1.CardName, T2.ItemCode, T2.Dscription, T2.Quantity, T2.Price, T2.LineTotal, T3.Project, T4.ItemCode, T4.Dscription, T4.Quantity, T4.Price, T4.LineTotal
    Regards,
    Rahul

Maybe you are looking for

  • Unable to create function based spatial index

    Maybe someone can help me. I can't seem to find the answer for what I'm doing here. I'm trying to create a function based spatial index - so that I can utilize coordinates in tables when I have no SDO_GEOMETRY column. Is there a fundamental problem w

  • Layout Printing

    Hello Everyone! I'm having problems printing layouts in SAP BO 2007A PL35, when I print one copy of the layout it comes fine, but when I print more than one copy the last copy is printed with box lines around the fields. Does anyone knows what should

  • Problem submitting book to Apple

    We have a book ready for submission in itunes producer and managed to upload the publication and go through all the other nitty-gritty writing and pricing for the publication. Now when we click the "deliver" button to Apple, we get the following erro

  • HT201307 My iPad Mini has stopped working with my router.  I honestly don't remember how I got  it working when I bought it, but I can't seem to fix it!!!!

    I need help from a person...  I bought this for educational reasons, it became handy when following the weather and such at home...  It disconnected from my home router, and I need help to reconnect it!  I don't remember how I did it, and I have no i

  • MacBook Pro Early 2011 support Handoff

    How come that my MacBook Pro Early 2011 supports the Handoff if it has Bluetooth 2.1? I receive all the SMS properly, Continuity works well and I also receive the calls. The only problem is that, during the calls, I hear a lot of rumor that comes fro