Custom Purchasing Report

Hey guys,
I am new to SAP, so bear with me...
There is a Purchasing Report on our system as follows:
BEGIN
declare @FrmWhs varchar(8),
        @ToWhs varchar(8),
        @WhsLst varchar(254),
        @GroupCode int,
        @FrmItm varchar(20),
        @ToItm varchar(20),
        @MthAgo int,
        @GroupName varchar(20),
        @HistStart varchar(6),
        @HistEnd varchar(6),
        @ShowInactive varchar(1)
SELECT @FrmWhs = T0.U_FrmWhs,
       @ToWhs = T0.U_ToWhs,
       @WhsLst = T0.U_WhsLst,
       @GroupCode = T1.ItmsGrpCod,
       @FrmItm = T0.U_FrmItm,
       @ToItm = T0.U_ToItm,
       @MthAgo = T0.U_MthAgo,
       @HistStart = T0.U_Hist1,
       @HistEnd = T0.U_Hist2,
       @ShowInactive = T0.U_Inact
  FROM [dbo].[@XXPURCH] T0, [dbo].[OITB] T1
WHERE T0.U_FrmWhs = '[%0]'
   AND T0.U_ToWhs = '[%1]'
   AND T0.U_WhsLst = '[%2]'
   AND T1.ItmsGrpNam = '[%3]'
   AND T1.Locked = 'X'
   AND T0.U_FrmItm = '[%4]'
   AND T0.U_ToItm = '[%5]'
   AND T0.U_MthAgo = [%6]
   AND T0.U_Hist1 = '[%7]'
   AND T0.U_Hist2 = '[%8]'
   AND T0.U_Inact = '[%9]'
SET @GroupName = '[%3]'
IF @GroupName = ''
   SET @GroupCode = 0
ELSE
SELECT @GroupCode = T2.ItmsGrpCod
    FROM dbo.OITB T2
  WHERE T2.ItmsGrpNam = @GroupName
SET @FrmWhs = '[%0]'
SET @ToWhs = '[%1]'
SET @WhsLst = '[%2]'
SET @FrmItm = '[%4]'
SET @ToItm = '[%5]'
SET @MthAgo = [%6]
SET @HistStart = '[%7]'
SET @HistEnd = '[%8]'
SET @ShowInactive = '[%9]'
exec dbo.xxPurchReport @FrmWhs,@ToWhs,@WhsLst,@GroupCode,@FrmItm,@ToItm,@MthAgo,@HistStart,@HistEnd,@ShowInactive
END -- for browse
My first questions is:
How do I locate and view at the "dbo.xxPurchReport" being executed? (called in the 4th line from the bottom.
Thanks alot to you all.

I thought this section of the SQL query was most pertinent, let me know if posting the entire stored procedure would be more beneficial.
Thanks again everyone.
Select ItmGrp.ItmsGrpNam,lines.ItemCode,lines.WhsCode,
           items.CardCode as DefaultVendor,items.ItemName,
           whs.OnHand,items.SalUnitMsr as SaleUnit,items.BuyUnitMsr as PurchUnit,whs.IsCommited,
           (whs.OnHand - whs.IsCommited) as Available,whs.OnOrder,items.PurFactor2,
           isnull(purprc.Price,0) as PurchasePrice,
           isnull(purprc.Currency,'USD') as PurchCurrency,
           cast(whs.OnHand / (CASE WHEN items.PurFactor2 = 0 THEN 1 ELSE items.PurFactor2 END) as decimal(16,2)) as CS,
           whs.AvgPrice,prc.Price,isnull(prc.Currency,'USD') as Currency,isnull(whs.StockValue,0) as StockValue,
           cast(sum(case lines.usebaseun
               when 'Y' then   Lines.OpenCreQty
               else ( Lines.OpenCreQty  * Items.NumInSale) end) as integer) as MtdSales,
           isnull(hst.AvgQty,0) as AvgSales,items.SalFactor2
      into #temprpt
      From OINV Main,
           INV1 Lines,
           OITM Items,
           OITB ItmGrp,
           OITW whs
                left outer join #tmpavg hst
                     on hst.ItemCode = whs.ItemCode and hst.WhsCode = whs.WhsCode,
           ITM1 prc,
           ITM1 purprc
     Where Main.DocDate between @StartDate and @EndDate
       And Main.Instance = 0
       And Main.Canceled = 'N'
       and Main.DocEntry = Lines.DocEntry and lines.LineTotal <> 0
       and lines.ItemCode between @FromItem and @ToItem
       and lines.whscode collate database_default in (select WhsCode from #tempwhs)
       and Items.ItemCode = Lines.ItemCode
       and items.PrchseItem = 'Y'
       and (@ShowInactive = 'Y' or Items.frozenfor = 'N')
       and ItmGrp.ItmsGrpCod = Items.ItmsGrpCod
       and ItmGrp.ItmsGrpCod = isnull(@GroupCode,ItmGrp.ItmsGrpCod)
       and whs.ItemCode = lines.ItemCode and whs.WhsCode = lines.WhsCode
       and prc.ItemCode = items.Itemcode
       and prc.PriceList = (CASE WHEN whs.whscode = '02' THEN 6 else 2 END)
       and purprc.ItemCode = items.Itemcode
       and purprc.PriceList = (CASE WHEN whs.whscode = '02' THEN 10 else 1 END)
     Group BY
        ItmGrp.ItmsGrpNam,lines.ItemCode,lines.WhsCode,
        items.CardCode,items.ItemName,
        whs.OnHand,items.SalUnitMsr,items.BuyUnitMsr,whs.IsCommited,whs.OnOrder,items.PurFactor2,purprc.Price,isnull(purprc.Currency,'USD'),
        cast(whs.OnHand / (CASE WHEN items.PurFactor2 = 0 THEN 1 ELSE items.PurFactor2 END) as decimal(16,2)),
        whs.AvgPrice,prc.Price,prc.Currency,isnull(whs.StockValue,0),hst.AvgQty,items.SalFactor2
    union
    select grp.ItmsGrpNam,itm.ItemCode,whs.WhsCode,itm.CardCode as DefaultVendor,
           itm.ItemName,whs.OnHand,itm.SalUnitMsr as SaleUnit,itm.BuyUnitMsr as PurchUnit,
           whs.IsCommited,
           (whs.OnHand - whs.IsCommited) as Available,whs.OnOrder,itm.PurFactor2,purprc.Price,
           isnull(purprc.Currency,'USD') as PurchCurrency,
           cast(whs.OnHand / (CASE WHEN itm.PurFactor2 = 0 THEN 1 ELSE itm.PurFactor2 END) as decimal(16,2)) as CS,
           whs.AvgPrice,prc.Price,isnull(prc.Currency,'USD') as Currency,isnull(whs.StockValue,0) as StockValue,0,
           isnull(hst.AvgQty,0) as AvgSales,itm.SalFactor2
    from OITM itm,
         OITB grp,
         OITW whs
              left join(INV1 lines inner join OINV main
                on lines.DocEntry = main.DocEntry and lines.LineTotal <> 0
                   and main.Canceled = 'N' and main.instance = 0
                   and Main.DocDate Between @StartDate and @EndDate)
                on whs.ItemCode = lines.ItemCode and whs.WhsCode = lines.WhsCode
              left outer join #tmpavg hst on hst.ItemCode = whs.ItemCode and hst.WhsCode = whs.WhsCode,
         ITM1 prc,
         ITM1 purprc
        where itm.ItemCode between @FromItem and @ToItem
          and itm.PrchseItem = 'Y'
          and (@ShowInactive = 'Y' or itm.frozenfor = 'N')
          and grp.ItmsGrpCod = itm.ItmsGrpCod
          and grp.ItmsGrpCod = isnull(@GroupCode,grp.ItmsGrpCod)
          and whs.ItemCode = itm.ItemCode
          and whs.WhsCode collate database_default in (select WhsCode from #tempwhs)
          and main.DocEntry is null
          and prc.ItemCode = itm.Itemcode
          and prc.PriceList = (CASE WHEN whs.whscode = '02' THEN 6 else 2 END)
          and purprc.ItemCode = itm.Itemcode
          and purprc.PriceList = (CASE WHEN whs.whscode = '02' THEN 10 else 1 END)
    group by grp.ItmsGrpNam,itm.ItemCode,whs.WhsCode,itm.CardCode,
       itm.ItemName,whs.OnHand,itm.SalUnitMsr,itm.BuyUnitMsr,whs.IsCommited,whs.OnOrder,itm.PurFactor2,itm.LastPurPrc,purprc.Price,purprc.Currency,
       cast(whs.OnHand / (CASE WHEN itm.PurFactor2 = 0 THEN 1 ELSE itm.PurFactor2 END) as decimal(16,2)),
       whs.AvgPrice,prc.Price,prc.Currency,isnull(whs.StockValue,0),hst.AvgQty,itm.SalFactor2

Similar Messages

  • Custom Purchase Oder Report Printing

    Hi All,
    We have custom purchase order report XML with Default Output Type as PDF, the report as such has no issues with it. We would like to capture the print count on the po_headers_all each time the custom report is printed by the user.
    I would be glad if any one could throw light as what will be the initiator for the print action so we could update the print count.
    Thanks in Advance.
    Regards

    Hi Guys,
    Anyone please throw anylight on the above issue of PO printing.
    Regards

  • How to Send Custom Purchase Order Report in PDF format to Supplier through email

    Hi,
    Currently whenever a PO is approved in PO form if Email Option is enabled it is sending the standard report output to the supplier, we need to replace the custom designed report instead of the standard report. How to achieve this, is there any need to modify the stuff in Workflow, if so what activity need to modify.
    Thanks in Advance.

    Attach your custom PDF report XML template related to the POXPOPDF program.

  • Reg:Vendor Sales & purchase report

    Dear All,
    We need one customzied report which is having the details about Vendor Sales & purchase transactions , if we are giving the input vendor or customer , fiscal year, comapany code, & fiscal period as the input means we need the details about the vendor sales and purchase report.
    Thanks,
    Sanakar M

    You can purchase the custom report from vendors called consultants or employees with developer keys.
    If you input the type as ABAPER, then you have the options and (hopefully) a good quality report.
    I am sure this will work....
    Cheers,
    Julius

  • Open PO not showing up on purchasing reports

    We have a customer whos PO's are not showing up on our purchasing reports. I am thinking it has something to do with needing to run some type of process to maybe sync up addresses or something. Anyone have an idea!
    Thanks in advance.

    Hi,
    There are various reports in Purchasing, can you please let us know the name of the report which you are trying to run?
    Thanks,
    Raghav

  • Customer Purchase order number

    Dear Experts
    If I execute FBL5N I will get the customer po details in the referance field for 1 company.
    If I execute same report for other company I will get the delivery document.
    How to set to get the customer purchase order details in referance field.

    Hi,
    here company code wise data fetching logic diffrent, please discuss with APAPer, he will tell you the logic behaviour.
    >>> Hi Mr. Ajay FYI Short Key updates Line Item wise Assignment Field not Referance Field.
    Regards
    Viswa

  • Printing Procurement Terms and Conditions in custom BIP report

    We are developing a custom BIP report for printing Purchase Agreements. We created new Data model and a new report template that matches the customer's requirements. However, we are not able to print the Terms and conditions in this custom report.
    The custom report is placed in the Shared Folders/Custom/Procurement/Purchasing folder and we included the following code at the beginning of the custom report template -
    <?import: xdoxsl:///Procurement/Purchasing/prc_po_terms_and_conditions_sub.xsb?loc=${_XDOLOCALE}?>
    And at the end, where we want to print the Terms and Conditions, the following code -
    <xsl:apply-templates select=".//TermsAndConditions"/>
    But the Terms and conditions are not printed. Can someone please help out and point to me where the mistake is?
    Thanks
    Lakshmi

    I am not an expert on BIP and will ask a colleague to comment. Took a look at the documentation and noticed some small differences, not sure if these have any impact, but you could try them while waiting to triage the issue:
    The documentation does not have space in the import statement i.e. "import:xdoxsl" while your example has a space "import: xdoxsl"
    To render the content the documentation states to use "<?call-template:template_name?>"
    Jani Rautiainen
    Fusion Applications Developer Relations
    https://blogs.oracle.com/fadevrel/

  • How do i get purchase Report.

    Hello All
    u201CHow do I get a purchase report from u2013 to date.  The report should be display each individual row itemu2019s  quantity, unit price, Assessable value, Base amount, tax amount .  i.e BED amount, Cess , HSCess, VAT, CST etc.u201D
    Regards
    Santhosh.K

    Try this
    Select T0.docnum,
    (select seriesname from nnm1 where series=T0.series) as InvSeries,
    T0.DocDate,T0.CardName,T0.NumatCard as 'Customer Reference',
    (select T8.TaxId11 from pch12 T8 where T8.docentry=T1.docentry) as 'TIN No.',
    T1.ItemCode,T1.Dscription,T1.AssblValue,
    CAST(T1.Quantity as Decimal(10,3)) as Quantity,T1.unitMsr as UOM,
    T1.currency,
    T1.PriceBefDi as 'Unit Price',T1.DiscPrcnt as 'Row Discount',
    CAST(T1.Price as Decimal(10,2)) as Price,
    CAST(T1.LineTotal as Decimal(14,2)) as Basic,
    T0.DiscPrcnt as 'Doc Discount',
    isnull((select sum(O1.Transvalue) from OINM O1,PDN1 N1,OPDN N0
    where
    N0.Docentry=N1.docentry and O1.Itemcode=N1.Itemcode and N1.TrgetEntry=T0.Docentry
    and O1.Warehouse=N1.WhsCode
    and O1.BASE_REF=N0.Docnum
      and O1.TransType = 20 and
    N1.Targettype=18),0) as 'GRPO Price',
    isnull((select sum(O1.Transvalue) from OINM O1
    where
    O1.Itemcode=T1.Itemcode
    and O1.Warehouse=T1.WhsCode
    and O1.BASE_REF=T0.Docnum
      and O1.TransType = 18),0) as 'Price Difference ',
    isnull((select sum(O1.Transvalue) from OINM O1,OIPF L0 inner join
    IPF1 L1 on L0.Docentry=L1.Docentry,PDN1 N1
    where
    O1.Itemcode=T1.Itemcode
    and O1.Warehouse=T1.WhsCode
    and O1.BASE_REF= L0.DocNum and
    L1.BaseEntry = N1.Docentry and
    N1.TrgetEntry=T0.Docentry
    and O1.TransType = 69),0) as 'Lande Cost',
    (SELECT T6.[BaseDocNum]
    FROM OPDN T5  INNER JOIN PDN1 T6 ON T5.DocEntry = T6 .DocEntry
    Where(T5.[DocType]='I') and (T5.[DocNum]=T1.[BaseDocNum]) and (T6.[DocEntry] = T1.[BaseEntry])
    and (T6.[LineNum]=T1.[BaseLine]) and (T6.[BaseType]='22')
    ) as PONumber,
    (SELECT T7.[DocDate] FROM OPOR T7 WHERE T7.[DocEntry]=(SELECT T6.[BaseEntry]
    FROM OPDN T5  INNER JOIN PDN1 T6 ON T5.DocEntry = T6 .DocEntry
    Where(T5.[DocType]='I') and (T5.[DocNum]=T1.[BaseDocNum]) and (T6.[DocEntry] = T1.[BaseEntry])
    and (T6.[LineNum]=T1.[BaseLine]) and (T6.[BaseType]='22')
    ) ) as PODate,
    isnull((select sum(taxsum) from pch4 where pch4.docentry=T0.docentry and pch4.LineNum=T1.Linenum and
                        pch4.statype=-90 ),0) as BasicExcise,
    isnull((select sum(taxsum) from pch4 where pch4.docentry=T0.docentry and pch4.LineNum=T1.Linenum and
                        pch4.statype=-60 ),0) as ExciseCess,
    isnull((select sum(taxsum) from pch4 where pch4.docentry=T0.docentry and pch4.LineNum=T1.Linenum and
                        pch4.statype=7 ),0) as Excisecess_he,
    isnull((select Min(BaseSum) from pch4 where pch4.docentry=T0.docentry and pch4.LineNum=T1.Linenum
                   and pch4.statype not in (-90,-60,7)),0) as TaxableTurnover,
    isnull((select sum(taxsum) from pch4 where pch4.docentry=T0.docentry and pch4.LineNum=T1.Linenum and
                        pch4.statype=4 and taxrate=10),0) as cst10,
    isnull((select sum(taxsum) from pch4 where pch4.docentry=T0.docentry and pch4.LineNum=T1.Linenum and
                        pch4.statype=4 and taxrate=12.5),0) as cst12,
    isnull((select sum(taxsum) from pch4 where pch4.docentry=T0.docentry and pch4.LineNum=T1.Linenum and
                        pch4.statype=4 and taxrate=3),0) as cst3,
    isnull((select sum(taxsum) from pch4 where pch4.docentry=T0.docentry and pch4.LineNum=T1.Linenum and
                        pch4.statype=4 and taxrate=2),0) as cst2,
    isnull((select sum(taxsum) from pch4 where pch4.docentry=T0.docentry and pch4.LineNum=T1.Linenum and
                        pch4.statype=4 and taxrate not in (10,12.5,3,2)),0) as cst_others,
    isnull((select sum(taxsum) from pch4 where pch4.docentry=T0.docentry and pch4.LineNum=T1.Linenum and
                        pch4.statype=1 and taxrate=4),0) as VAT4,
    isnull((select sum(taxsum) from pch4 where pch4.docentry=T0.docentry and pch4.LineNum=T1.Linenum and
                        pch4.statype=1 and taxrate=12.5),0) as VAT12,
    isnull((select sum(taxsum) from pch4 where pch4.docentry=T0.docentry and pch4.LineNum=T1.Linenum and
                        pch4.statype=1 and taxrate=0),0) as VAT0,
    isnull((select sum(taxsum) from pch4 where pch4.docentry=T0.docentry and pch4.LineNum=T1.Linenum and
                        pch4.statype=1 and taxrate not in (4,12.5,0)),0) as VAT_others,
    isnull((select sum(taxsum) from pch4 where pch4.docentry=T0.docentry and pch4.LineNum=T1.Linenum and
                        pch4.statype=9),0) as tcs,
    isnull((select sum(linetotal) from pch3 where pch3.docentry=T0.docentry and
    T1.linenum=(Select Max(Linenum) from PCH1 T3 where T3.DocEntry=T0.DocEntry)),0 ) as Other_expenses,
    T1.Gtotal as Itemwise_grossTotal,
    isnull(( select Rounddif from OPCH  T4 where T4.docentry=T0.Docentry and
            T1.linenum=(Select Max(Linenum) from PCH1 T3 where T3.DocEntry=T0.DocEntry)),0) as Inv_RoundDiff,
    isnull(( select DocTotal from OPCH  T5 where T5.docentry=T0.Docentry and
            T1.linenum=(Select Max(Linenum) from PCH1 T3 where T3.DocEntry=T0.DocEntry)),0)  as Inv_grosstotal
    from Opch T0, pch1 T1,OITM M1 INNER JOIN OITB B1 ON M1.ItmsGrpCod=B1.ItmsGrpCod
    where (T0.DocType='I') and T0.docentry=T1.docentry and (T0.DocDate between '[%0]' and '[%1]')
    Union All
    Select
    T0.docnum,
    (select seriesname from nnm1 where series=T0.series) as InvSeries,
    T0.DocDate,T0.CardName,T0.NumatCard as 'Customer Reference',
    (select T8.TaxId11 from RPC12 T8 where T8.docentry=T1.docentry) as 'TIN No.',
    T1.ItemCode,T1.Dscription,T1.AssblValue,
    CAST(T1.Quantity as Decimal(10,3)) as Quantity,T1.unitMsr as UOM,T1.currency,
    T1.PriceBefDi as 'Unit Price',T1.DiscPrcnt as 'Row Discount',
    -1*CAST(T1.Price as Decimal(10,2)) as Price,
    -1*CAST(T1.LineTotal as Decimal(14,2)) as Basic,
    T0.DiscPrcnt as 'Doc Discount',
    0 as 'GRPO Price',
    -1*isnull((select sum(O1.Transvalue) from OINM O1
    where
    O1.Itemcode=T1.Itemcode
    and O1.Warehouse=T1.WhsCode
    and O1.BASE_REF=T0.Docnum
      and O1.TransType = 19),0) as 'Price Difference ',
    0 as 'Landed Cost',
    (SELECT T6.[BaseDocNum]
    FROM OPDN T5  INNER JOIN PDN1 T6 ON T5.DocEntry = T6 .DocEntry
    Where(T5.[DocType]='I') and (T5.[DocNum]=T1.[BaseDocNum]) and (T6.[DocEntry] = T1.[BaseEntry])
    and (T6.[LineNum]=T1.[BaseLine]) and (T6.[BaseType]='22')
    ) as PONumber,
    (SELECT T7.[DocDate] FROM OPOR T7 WHERE T7.[DocEntry]=(SELECT T6.[BaseEntry]
    FROM OPDN T5  INNER JOIN PDN1 T6 ON T5.DocEntry = T6 .DocEntry
    Where(T5.[DocType]='I') and (T5.[DocNum]=T1.[BaseDocNum]) and (T6.[DocEntry] = T1.[BaseEntry])
    and (T6.[LineNum]=T1.[BaseLine]) and (T6.[BaseType]='22')
    ) ) as PODate,
    -1*isnull((select sum(taxsum) from RPC4 where RPC4.docentry=T0.docentry and RPC4.LineNum=T1.Linenum and
                        RPC4.statype=-90 ),0) as BasicExcise,
    -1*isnull((select sum(taxsum) from RPC4 where RPC4.docentry=T0.docentry and RPC4.LineNum=T1.Linenum and
                        RPC4.statype=-60 ),0) as ExciseCess,
    -1*isnull((select sum(taxsum) from RPC4 where RPC4.docentry=T0.docentry and RPC4.LineNum=T1.Linenum and
                        RPC4.statype=7 ),0) as Excisecess_he,
    -1*isnull((select Min(BaseSum) from RPC4 where RPC4.docentry=T0.docentry and RPC4.LineNum=T1.Linenum
                   and RPC4.statype not in (-90,-60,7)),0) as TaxableTurnover,
    -1*isnull((select sum(taxsum) from RPC4 where RPC4.docentry=T0.docentry and RPC4.LineNum=T1.Linenum and
                        RPC4.statype=4 and taxrate=10),0) as cst10,
    -1*isnull((select sum(taxsum) from RPC4 where RPC4.docentry=T0.docentry and RPC4.LineNum=T1.Linenum and
                        RPC4.statype=4 and taxrate=12.5),0) as cst12,
    -1*isnull((select sum(taxsum) from RPC4 where RPC4.docentry=T0.docentry and RPC4.LineNum=T1.Linenum and
                        RPC4.statype=4 and taxrate=3),0) as cst3,
    -1*isnull((select sum(taxsum) from RPC4 where RPC4.docentry=T0.docentry and RPC4.LineNum=T1.Linenum and
                        RPC4.statype=4 and taxrate=2),0) as cst2,
    -1*isnull((select sum(taxsum) from RPC4 where RPC4.docentry=T0.docentry and RPC4.LineNum=T1.Linenum and
                        RPC4.statype=4 and taxrate not in (10,12.5,3,2)),0) as cst_others,
    -1*isnull((select sum(taxsum) from RPC4 where RPC4.docentry=T0.docentry and RPC4.LineNum=T1.Linenum and
                        RPC4.statype=1 and taxrate=4),0) as VAT4,
    -1*isnull((select sum(taxsum) from RPC4 where RPC4.docentry=T0.docentry and RPC4.LineNum=T1.Linenum and
                        RPC4.statype=1 and taxrate=12.5),0) as VAT12,
    -1*isnull((select sum(taxsum) from RPC4 where RPC4.docentry=T0.docentry and RPC4.LineNum=T1.Linenum and
                        RPC4.statype=1 and taxrate=0),0) as VAT0,
    -1*isnull((select sum(taxsum) from RPC4 where RPC4.docentry=T0.docentry and RPC4.LineNum=T1.Linenum and
                        RPC4.statype=1 and taxrate not in (4,12.5,0)),0) as VAT_others,
    -1*isnull((select sum(taxsum) from RPC4 where RPC4.docentry=T0.docentry and RPC4.LineNum=T1.Linenum and
                        RPC4.statype=9),0) as tcs,
    -1*isnull((select sum(linetotal) from RPC3 where RPC3.docentry=T0.docentry and
    T1.linenum=(Select Max(Linenum) from RPC1 T3 where T3.DocEntry=T0.DocEntry)),0 ) as Other_expenses,
    -1*T1.Gtotal as Itemwise_grossTotal,
    -1*isnull(( select Rounddif from ORPC  T4 where T4.docentry=T0.Docentry and
            T1.linenum=(Select Max(Linenum) from RPC1 T3 where T3.DocEntry=T0.DocEntry)),0) as Inv_RoundDiff,
    -1*isnull(( select DocTotal from ORPC  T5 where T5.docentry=T0.Docentry and
            T1.linenum=(Select Max(Linenum) from RPC1 T3 where T3.DocEntry=T0.DocEntry)),0)  as Inv_grosstotal
    from ORPC T0, RPC1 T1,OITM M1 INNER JOIN OITB B1 ON M1.ItmsGrpCod=B1.ItmsGrpCod
    where (T0.DocType='I') and T0.docentry=T1.docentry and (T0.DocDate between '[%0]' and '[%1]')

  • Get billing list by customer purchase order

    Hi Experts:
                     Is there any standard T-code which can get billing list by customer purchase order ?
                    Billing contains delivery-related and order-related,
                    one po can has several sales order,and one sales order has several DN or Billing.
                   Pls give me some advice.
                                                                                    Thank you very much.

    Dear Friend,
    There is no standard Tcode for your requirement.There is two way to get so,
    1. Either go for Abap Developed report.
    2. Or try to get the some through Table.
    Regards
    AJIT K SINGH

  • Error  while running custom BI report in R12.1.1

    Hi All,
    We are encountering below error while running custom BI report in R12.1.1...
    Forcing NLS_NUMERIC_CHARACTERS to: '.,' for XDO processing
    APPLLCSP Environment Variable set to :
    Current NLS_LANG and NLS_NUMERIC_CHARACTERS Environment Variables are :
    American_America.UTF8
    Enter Password:
    MSG-00001: started report
    REP-1401: '': Fatal PL/SQL error occurred.
    REP-0069: Internal error
    REP-57054: In-process job terminated:Terminated with error:
    REP-1401: '': Fatal PL/SQL error occurred.
    Report Builder: Release 10.1.2.3.0 - Production on Fri Jun 24 16:47:30 2011
    Please let us know how to fix this error.
    Thanks
    Praveen

    Hi Praveen,
    Seems the issue is with the rdf. Check whether all the parameters are passed correctly.
    REP-1401: '': Fatal PL/SQL error occurred.

  • Customer payment report

    I have an requirement, user ask me to generate a customer report to them on monthly basis, i would like to know which table can be use? The report need to shown the customer payment date( i think use entry date would be better), and for which invoice and sales order item... thank you very much.
    Moderator Message: First work on it yourself and get back if you have any specific queries.
    Edited by: kishan P on Nov 30, 2010 10:01 AM

    Hi
    i think we can get report from ABAP Query.  we have to write Query using tables and select fields, then we can get customer payment report.

  • CR2008 Purchasing Report needed

    Hi
    Has anyone created a Purchasing report in Crystal Reports 2008 based on AP Invoices and AP Credit Notes. I have created a WPA (Weekly Purchase Analysis) report but based off AP Invoice table (OPCH & PCH1), now the company is wanting to have Credit Notes added to this report.
    I have created a UDF called WPA on the OPCH form which is a Mandatory field so when running the WPA Report you can run it by WPA # and Project to get your results (Parameter), now how will I acheive this by adding the AP Credit Note fields ORPC & RPC1 to the report so if I create x2 Invoice's (different suppliers) for say WPA # 1010 and I Credit one, on the WPA Report I will want to see Invoice 1 (NumCard = 1) = R100, Invoice 2 (NumCard = 2) = 100, Credit Note 1 (NumCard = 2) = -100, Total = 100.
    Any suggestions or ideas will be most helpful.
    Regards
    Kurt Walters

    Hi Kurt,
    That is possible using "Shared Variable".
    Check this link: [Sub-report data in report|Sub-report data in report].
    1.Initialize a shared variable in Report.
    2.Pass the Credit memo value to the 'Shared variable' in Sub-report
    3.Now create a formula in Report like
          Sub-total = {Invoice total} - {SharedVariable}
    In order to know more about shared variable, post a separate question in [SAP Crystal Reports Design - Forum|SAP Crystal Reports;.
    Hope this helps.
    Regards,
    Bala

  • Problem in making logic for customer balance report

    Hi,
    I am working on a customer balance report in which i am picking the data from BSAD and BSID tables. I am facing a problem that i am able to calculate the opening balance in it but not able to calculate  closing balance. I am comparing the data with tcode FBL5N for opening and closing  balances for a given date range.  Kindly help me out where i am getting wrong:-
    Here the link to the code :-
    http://docs.google.com/View?id=dfxswwff_11fdktr7ct
    Edited by: nav009 on Feb 6, 2010 9:30 AM

    Hi Nikhil,
    Thanks for you response but i had developed the report and  i am able to pick the correct data but i am facing the problem in displaying the NETAMT which is displaying the data using this formula :-
    1.) NETAMT = NETAMT +  W_TAB1-DR + W_TAB1-CR.
    so that the last value matches with the closing balance.
    When i am using this formula i am not able to display the correct data of deducting or addition of the opening balance in it but the value matches with closing balance .
    2.) NETAMT = NETAMT + W_OPBAL-OPBAL +  W_TAB1-DR + W_TAB1-CR.
    When i am using this formula it is showing the first value correctly but not the last one which will be displayed in the closing balance.
    I want to have desired output to display the first value to be displayed as it is showing in the (2) and last value to be displayed as  it is showing in (1) last value.
    How can i achieve this  functionality? i really want to know...
    Edited by: nav009 on Feb 10, 2010 6:29 AM

  • Upgrade from 11i to R12 - Custom Forms,Reports and Workflows

    Dear Community Friends,
    We are planning for upgrade from oracle apps 11.5.10.2 to R12.
    We have custom Forms,Form Libraries,Reports and Workflows.
    Kindly provide me for approach on how to migrate Custom form libraries,reports and Workflows.
    I beleive, this thread will exists as one shot point for custom forms,reports,workflow upgradation from 11i to r12 with detailed steps.
    I know that many links exists here in the forum for all the above objects mentioned,but still from all those i am able to get a clear picture for oracle forms but not for custom form libraries ,reports and workflows.
    Also,this post will provide a low level,practical picture of the steps for those who are in line with this.
    Links i have read for all these in our forum are:
    For Custom Forms,
    Re: Planning to upgrade from 11i to R12
    Re: Custom forms: After upgrading 11i to R12
    ofcourse,'n' number of links exists providing metalink notes also.
    Hussain,Helios and some others also has given many updates regd this.
    For custom workflow upgradation,
    Upgrade Workflow 11i to R12
    Workflow Upgrade
    Workflow Upgrade
    For reports,links mentioned the below metalink notes:
    Do Not Compile EBS R12 Reports Using rwconverter.sh or Reports Builder from IDS 10gR2 [ID 786794.1]
    Using the OracleAS 10.1.2 Forms and Reports Builders with Oracle Applications Release 12 [ID 444248.1]
    Per my understanding, after searching in many threads,i am here by summarising the practical low level steps for custom forms migration
    Please correct me,if i am wrong.
    1) Download the Forms(.fmb's) and all PLL's(all the PLL from resource folder in AU_TOP) into a Local Machine Folder
    2) Open the forms using Forms Developer 10G and connect to DB
    3) Compile by clicking compilein Forms Developer and then save it.
    4) Upload the Saved Forms(.fmb's) into the new R12 server(system) in the respective custom paths(paths similar to 11i Server)
    5) Compile all the forms using the command like below(example command is shown below or f60 gen commands or frmcmp.sh utility) in the respective custom form paths,
    this will generate the .fmx's.
    frmcmp_batch module=FORMNAME.fmb userid=apps/apps output_file=FORMNAME.fmx compile_all=yes
    Link for compiling forms: https://support.oracle.com/epmos/faces/ui/km/SearchDocDisplay.jspx?_afrLoop=359210362972527&type=DOCUMENT&id=1085928.1&displayIndex=3&_afrWindowMode=0&_adf.ctrl-state=c348xvwbg_98
    6) Open the form and check in R12 instance
    As per my understanding for custom form libraries,we can just copy paste the PLL's from 11i server to R12 server (Please correct me,if i am wrong)
    Can anyone please help me out in custom reports and custom workflows.Sorry that,i could not get a practical and clear picture for reports and also for workflow even after referring many threads and metalink notes mentioned.
    As for reports,some says that Developer Suite 10g can be used and .rdf can be used in R12.
    Some says that reports should be converted to XML published as reports does not exists in R12.
    So,i am not clear on this.
    Thanks,
    Ganesh
    [email protected]

    Per my understanding, after searching in many threads,i am here by summarising the practical low level steps for custom forms migration
    Please correct me,if i am wrong.
    1) Download the Forms(.fmb's) and all PLL's(all the PLL from resource folder in AU_TOP) into a Local Machine Folder
    2) Open the forms using Forms Developer 10G and connect to DB
    3) Compile by clicking compilein Forms Developer and then save it.
    4) Upload the Saved Forms(.fmb's) into the new R12 server(system) in the respective custom paths(paths similar to 11i Server)
    5) Compile all the forms using the command like below(example command is shown below or f60 gen commands or frmcmp.sh utility) in the respective custom form paths,
    this will generate the .fmx's.
    frmcmp_batch module=FORMNAME.fmb userid=apps/apps output_file=FORMNAME.fmx compile_all=yes
    Link for compiling forms: https://support.oracle.com/epmos/faces/ui/km/SearchDocDisplay.jspx?_afrLoop=359210362972527&type=DOCUMENT&id=1085928.1&displayIndex=3&_afrWindowMode=0&_adf.ctrl-state=c348xvwbg_98
    6) Open the form and check in R12 instance
    As per my understanding for custom form libraries,we can just copy paste the PLL's from 11i server to R12 server (Please correct me,if i am wrong)You are right, and the steps mentioned above should be sufficient.
    Can anyone please help me out in custom reports and custom workflows.Sorry that,i could not get a practical and clear picture for reports and also for workflow even after referring many threads and metalink notes mentioned.
    As for reports,some says that Developer Suite 10g can be used and .rdf can be used in R12.
    Some says that reports should be converted to XML published as reports does not exists in R12.
    So,i am not clear on this.You can still use RDF files in R12, and just follow the approach you mentioned above, and you do not have to migrate them to XML publisher (though it is recommended, but this can be done after the upgrade as an enhancement task).
    For custom workflow, you need also to do the same thing, open them using workflow builder and make sure they work in R12 (correct the code if required and save them again in R12 once they work properly).
    Thanks,
    Hussein

  • How to create new Custom XML Report without using Form Builder

    Hi,
    What are the steps to create new Custom XML Report without using Report Builder ?
    Thanks and Regards,
    Abhi

    Hi,
    Steps we now follow
    1)Create Data Model in Reports Builder
    2)Create xml
    3)Insert xml in Publisher to build Fomat
    4)FTp rdf
    5)Create Data Definition and Template
    6)Create executable and Concurrent Program
    Is there any way we can build reports without use of Report Builder ? By writing PL SQL Package for Before Report and After Report etc ...
    Thanks and Regards,
    Abhijit Rode

Maybe you are looking for

  • How can i create a new instance on unix

    Hi, How can i create a new instance(instance only) on UNIX and how can i mount my database with this new instance.

  • FR: Full Screen Preview of Multi-Camera Angles

    The Program monitor can be viewed in Full Screen mode, as we all know, but when the Program monitor is displaying Multi-camera angles, it can only viewed in windowed mode.  Full Screen mode no longer works in this situation.  This is inconsistent, il

  • IDOC-- JDBC server with synchronous communication.

    Hi  SAP PI Experts, we have requirement as per the below. could you suggest the best possible way to execute this below. we need to send the outbound IDOC to JDBC and reponse file from JDBC should be posted to ECC in IDOC format. as per my knowledge

  • Difference in core application of "SPARC 32-bit" vs "generic" WebLogic10.3?

    Hi guys, I really need your urgent advice on the topic above. My question is that is there a difference in the WEBLOGIC 10.3 CORE itself between these two version mentioned? My opinion think the only determining factor is the VM used that would deter

  • Live stream won't play on Windows

    We're using QTSS and QTBroadcaster to stream a live event. Everything works fine on Mac clients, but Windows clients simply can't get the stream unless it's opened directly in QuickTime Player. We have a website with an embedded link for the stream,