How to find invoice
Hi,
I want to find an invoice using DI-Api.
I use getbykey(invoicenumber) but there is no invoice found, but the invoice exists in SBO.
Does anyone have a working example?
Hi,
Yes, example (in VB.NET):
Dim rs As SAPbobsCOM.Recordset
Dim query As String
Dim docnum As Integer
Try
query = "SELECT DocEntry FROM OINV WHERE DocNum = 20050001"
rs = oCmp.GetBusinessObject(SAPbobsCOM.BoObjectTypes.BoRecordset)
rs.DoQuery(query)
Console.WriteLine("aantal regels ", rs.RecordCount)
If rs.RecordCount > 0 Then
Console.WriteLine("DocEntry: ", rs.Fields.Item(0).Value)
End If
Catch e As Exception
Dim message As String = _
e.[GetType].ToString + ":" + vbCrLf + _
e.Message + vbCrLf + _
e.StackTrace
Console.Error.WriteLine(message)
MsgBox(message, MsgBoxStyle.Critical)
End Try
Regards,
Jacco
Message was edited by: J. Moolenaar
Similar Messages
-
how to find invoice open item.
Hi,
You can get the open items from BSIS.
To get the details of open items you need to do as below :
1. Get all the document numbers from BSIS table based on year(GJAHR) and period (MONAT).
2. Once you get all the open items from BSIS, go to BSAS with the document number retreived from BSIS.
Now you will have two internal tables, one with open items and one with closed items. Now you need to segregate the open items and closed items from BSIS.
loop at it_bsis.
read table it_bsas with key bukrs = it_bsis-bukrs
hkont = it_bsis-hkont
gjhar = it_bsis-gjahr
monat = it_bsis-monat.
if sy-subrc eq 0.
delete it_bsis.
clear it_bsis.
endif.
endloop.
Now you are left with only open item only.
Thanks,
Sriram Ponna. -
How to find Invoices approved by me and sort them after supplier?
Hi,
Please help ?
How to find the invoices which I have approved in SAP ?
how to find the invoices which I have approved in SAP and sort after supplier ?
Can these searches be combined ?
I appreciate your immediate reply
Regards,
Sairam.What do you mean by approving invoice?
-
How to find Invoice number linked to FI accounting document number ??
Hello All,
I have been looking around for all possible combinations to find the link between FI accounting document number (BSEG-BELNR) and Intercompany Invoice number (for which billing corr. to STOs' or POs' is done).
The requirement is that during ERS posting, we have accounting document numbers (BSEG-BELNR) and associated STOs' for this (BSEG-EBELN), but we are unable to map the Intercompany Billing Invoice number(s) (where the billing corr. to STOs' obtained from BSEG-EBELN) to this accounting document number (BSEG-BELNR).
Any pointers or detailed view solution would be of great help.
Thanks,
AnshHello DPM,
Thank you for the descriptive help. But my requirement is to look for Intercomapny Billing number (VBRK-VBELN) linked to an accounting document number (BSEG-BELNR) and not Invoice Receipt Number.
The steps that I am following are:
From BSEG, found EBELN (Stock Transfer Order) and XREF3 (Reference Key, combination of fiscal yr., some ref. number, maybe GR no. and ref item no.), based on BELNR (Accounting document number).
From EKBE, found XBLNR (Reference Delivery Number or Direct Intercompany Billing Number on which GR is done) based on
EKBE - EBELN = BSEG - EBELN
EKBE - BELNR = BSEG - XREF3 (only ref and item no., considering it to be a GR no.)
EKBE - VGABE = '1' and EKBE - BEWTP = 'E'.
From VBRP, found VBELN (Intercompany Billing No., which is a desired number) based on
VBRP - AUBEL = EKBE -EBELN (Stock Transfer Order)
VBRP - VGBEL = EKBE - XBLNR (Delivery number)
Here, I am not sure about 2 things:
Whether the reference no in BSEG-XREF3 will always be Goods Receipt number for Stock Transfer Order or not. If not, then what it can be and how I will have to proceed further then.
Secondly, If in case for an accounting document number, I have 2 Stock Transfer orders (BSEG - EBELN) and same reference number (BSEG-XREF3), then from History table (EKBE) I get only single delivery based on which GR was doen for both STOs', then I shall be getting single Intercompany Billing Invoice from VBRP or different ?
Kindly provide your inputs.
Thanks,
Ansh -
Hi experts,
I have limited knowledge in FI model.
I want to find the AP/AR posted invoice according to the Company code and posting date.
How should I use the referred table BSEG BKPF and VBRK ?
Is this data just coming from table BESG and BKPF, and no relationship with VBRK?
and AP from BSEG, AR from BKPF?
Thanks a lot.
Sincerely Julie
Edited by: julie 2192 on Apr 2, 2010 9:55 PM>
Vinod Kumar wrote:
> Hi julie,
>
> BKPF-BLART = 'RV' means account receivable (Customer Invoice), if you are updating reference number in BKPF, then you will find the entry in VBRK,VBRP
>
> BKPF-BLART = 'KR' mean account payable invoice (Vendor Invoice), if you are updating reference number in BKPF, then you will find the entry in RBKP & RSEG.
>
> Regards
> Vinod
Hi Vinod,
As you mentioned upside,
BKPF-BLART = 'RV' means account receivable (Customer Invoice), if you are updating reference number in BKPF, then you will find the entry in VBRK,VBRP.
But there is still a field value BKPF-BLART = 'DR'. (Customer Invoice) I want to know, is this kind of document type belongs to AP Invoice?
Thanks a lot.
Sincerely Julie -
How to find invoices having a particular string in item description
SELECT T0.[DocDate], T0.DocNum,T0.[CardCode], T0.[CardName], T7.[descript] [Territory],
T5.[SlpName], T1.[ItemCode],
T1.[Dscription], T1.[Quantity], T1.[LineTotal], T1.[TotalFrgn],
T1.[Rate],T2.[U_SheetTab], T2.[U_SubCategory], T2.U_SPCatgry, T6.U_CatName, T3.[QryGroup22] Exports
FROM OINV T0
RIGHT JOIN INV1 T1 ON T0.DocEntry = T1.DocEntry
INNER JOIN OITM T2 ON T1.ItemCode = T2.ItemCode
INNER JOIN OCRD T3 ON T0.CardCode = T3.CardCode
INNER JOIN CRD1 T4 ON T3.CardCode = T4.CardCode
INNER JOIN OSLP T5 ON T0.SlpCode = T5.SlpCode
INNER JOIN [@NCM_PRODCATGRY] T6 ON T2.U_SPCatgry = T6.U_CatCode
INNER JOIN [OTER] T7 ON T3.Territory = T7.territryID
WHERE T0.DocType ='I'
and T1.[ItemCode] = T2.[ItemCode]
AND T4.ADRESTYPE='S'
and (T2.U_SPCatgry = '079' or T2.U_SPCatgry = '168' or T2.U_SPCatgry = '169')
--and T3.[QryGroup22]= 'Y'
and T0.[DocDate] between '[%0]' and '[%1]'
Union All
SELECT T0.[DocDate], T0.DocNum, T0.[CardCode], T0.[CardName],T7.[descript] [Territory],
T5.[SlpName], T1.[ItemCode], T1.[Dscription],
(T1.[Quantity] * -1 )Quantity, (T1.[LineTotal] * -1 )LineTotal, (T1.[TotalFrgn] * -1) TotalFrgn,
T1.[Rate],T2.[U_SheetTab], T2.[U_SubCategory], T2.U_SPCatgry, T6.U_CatName , T3.[QryGroup22] Exports
FROM ORIN T0
RIGHT JOIN RIN1 T1 ON T0.DocEntry = T1.DocEntry
INNER JOIN OITM T2 ON T1.ItemCode = T2.ItemCode
INNER JOIN OCRD T3 ON T0.CardCode = T3.CardCode
INNER JOIN CRD1 T4 ON T3.CardCode = T4.CardCode
INNER JOIN OSLP T5 ON T0.SlpCode = T5.SlpCode
INNER JOIN [@NCM_PRODCATGRY] T6 ON T2.U_SPCatgry = T6.U_CatCode
INNER JOIN [OTER] T7 ON T3.Territory = T7.territryID
WHERE T1.[ItemCode] = T2.[ItemCode]
and T0.DocType ='I'
AND T4.ADRESTYPE='S'
and (T2.U_SPCatgry = '079' or T2.U_SPCatgry = '168' or T2.U_SPCatgry = '169')
--and T3.[QryGroup22]= 'Y'
and T0.[DocDate] between '[%0]' and '[%1]'
--However in this query even if the invoice has many items, only items belonging to U_SPCatgry 079 or 168 or 169 are displayed. This can be a problem since the commission payable has to be calculated on all the other items that may also belong to some other U_SPCatgryHi,
Try this:
SELECT T0.[DocDate], T0.DocNum,T0.[CardCode], T0.[CardName], T7.[descript] [Territory],
T5.[SlpName], T1.[ItemCode],
T1.[Dscription], T1.[Quantity], T1.[LineTotal], T1.[TotalFrgn],
T1.[Rate],T2.[U_SheetTab], T2.[U_SubCategory], T2.U_SPCatgry, T6.U_CatName, T3.[QryGroup22] Exports
FROM OINV T0
RIGHT JOIN INV1 T1 ON T0.DocEntry = T1.DocEntry
INNER JOIN OITM T2 ON T1.ItemCode = T2.ItemCode
INNER JOIN OCRD T3 ON T0.CardCode = T3.CardCode
INNER JOIN CRD1 T4 ON T3.CardCode = T4.CardCode
INNER JOIN OSLP T5 ON T0.SlpCode = T5.SlpCode
INNER JOIN [@NCM_PRODCATGRY] T6 ON T2.U_SPCatgry = T6.U_CatCode
INNER JOIN [OTER] T7 ON T3.Territory = T7.territryID
WHERE T0.DocType ='I'
and T1.[ItemCode] = T2.[ItemCode]
AND T4.ADRESTYPE='S'
and T2.U_SPCatgry IN ('079','168','169','XXX','YYYY')
--and T3.[QryGroup22]= 'Y'
and T0.[DocDate] between '[%0]' and '[%1]'
Union All
SELECT T0.[DocDate], T0.DocNum, T0.[CardCode], T0.[CardName],T7.[descript] [Territory],
T5.[SlpName], T1.[ItemCode], T1.[Dscription],
(T1.[Quantity] * -1 )Quantity, (T1.[LineTotal] * -1 )LineTotal, (T1.[TotalFrgn] * -1) TotalFrgn,
T1.[Rate],T2.[U_SheetTab], T2.[U_SubCategory], T2.U_SPCatgry, T6.U_CatName , T3.[QryGroup22] Exports
FROM ORIN T0
RIGHT JOIN RIN1 T1 ON T0.DocEntry = T1.DocEntry
INNER JOIN OITM T2 ON T1.ItemCode = T2.ItemCode
INNER JOIN OCRD T3 ON T0.CardCode = T3.CardCode
INNER JOIN CRD1 T4 ON T3.CardCode = T4.CardCode
INNER JOIN OSLP T5 ON T0.SlpCode = T5.SlpCode
INNER JOIN [@NCM_PRODCATGRY] T6 ON T2.U_SPCatgry = T6.U_CatCode
INNER JOIN [OTER] T7 ON T3.Territory = T7.territryID
WHERE T1.[ItemCode] = T2.[ItemCode]
and T0.DocType ='I'
AND T4.ADRESTYPE='S'
and T2.U_SPCatgry IN ('079','168','169','XXX','YYYY')
--and T3.[QryGroup22]= 'Y'
and T0.[DocDate] between '[%0]' and '[%1]'
Replace XXX and YYYY with your category value to all other category value.
Thanks & Regards,
Nagarajan -
How to find whether an Invoice is been posted for a particular PO
Hi,
How to find whether an Invoice is been posted for a particular PO.
I have a scenario where I fetch data into an internal table T_CDHDR(It has PO and other details). For each and every entry(PO) in that internal table I have to see whether an Invoice is been posted or not. They told to use <b>EKBE(Purchasing document history)</b> table. But, I don't know which field to check for and based on what conditions.
Can someone help me with sample code or some valuable inputs.
Thanks in advance.
Regards,
Paddu.HI,
TABLE IS RIGHT.
IN THAT TABLE FOR THE FIELD BEWTP CHECK WHETHER ENTRY IS "Q".
Q STANDS FOR IR-L THAT MEANS INVOICE IS DONE.
ON THE SELECTION SCREEN OF EKBE TABLE ENTER THE PO NUMBER.
THEN CHECK WHETHER IT HAS ENTRY FOR BEWTP 'Q'.
YOU CAN CROSS-CHECK THIS DATA FROM TABLE WITH THAT IN ACTUAL PO IN T.CODE - ME23N.
ENTER PO NUMBER ,THEN IN ITEM DETAILS , IN HISTORY TAB SEE FOR THAT INVOICE NO. -
How to find out, that sales invoice is paid
Hi,
does anybody some hint, how to easy find out, that sales invoice is paid already (2007). I need to do this check for list of invoices (thousands) - so Im looking for some query.
I know, how to find it through oinvoice object, from bank payment, internal reconciliation, ..., but I think that there must be some internal view or SP which is in use for SAP for receiving this information (calculating variables). I dont need informations about payment dates, Im looking just for info, that invocie is paid already. Maybe some record in JE linked to invoice?
thanksWe need to get the Invoice Paid Amount. Our customer use Bill of exchange frequently , so we are looking into OBOE for payment info, because Invoice Paid Amount (OINV.PaidToDate) does not reflect current payment info when there are Bill of Exchanges.
Are we wrong?
Does anybody know an easy way gather this information?
For more detailed info about the way we are doing this see Field BoeType - OBOE -
How to find Material Document respect to incoming excise invoices?
When stock is transfered from one plant to another,
in sending plant, material document is created, with respect to this material document out bound delivery is created further out bound excise invoices.
In receiving plant when the incoming stock reached the plant with incoming excise
invoice, material document is created .
how to find the this receiving plant material document with respect to incoming excise invoice.?
how to get the receiving plant material documents with respect to sending plant material documents?when the material is transferred from the one plant to another.
before going to transfer the material.
one material document is created
with respect to multiple item of material document delivery documents created.
for every delivery one invoice is generated.
when the stock is reached to plant with invoice
with respect to this invoice one material document is created for quality check.
I this case we may have multiple invoices may have the multiple material documents in receiving plant .
how to find for which excise invoice it is creating material document in receiving plant? -
How to find out, whether any invoice is having header text or not.
HI all,
How to find out, whether any invoice is having header text or not. wheich table we have to refer.
Thanks
mahaboobHi,
You need to use FM READ_TEXT.
First you have to determine what text Object/ID/Language you want to read (you can have N text objects for an invoice header).
The easiest way to do this is to have an example document with the text you want to read.
For example in VF03.
1-Goto->Header->Header Texts.
2-Click on the text you want to read
3-Double click on the text (Right side box) This will take you
4-Goto->Header
This will give you the data you need to use in the READ_TEXT F.M. -
How to find the status of an invoice in ECC ?
Hi,
Could anyone please tell me how to find the status of an invoice in ECC system (Parked, posted or saved as completed)
Regards
Prashant ChauhanHI
MIR6
Regards
Kailas Ugale -
FI - How to find KOSTL for Single FI Documents / Invoices
Hi experts,
can someone explain me how to find the reight KOSTL for every Single Document/Invoice. Because the Filed within BSEG does not always contain
the information (=empty). e.g for Documents in BSEG with KOART = 'A' or 'S' etc...
Many Thanks in advance.
AliHi Eric,
this is exactly the point. I am trying to Extract towards BW with the
0FI_GL_4 Datasource all Items for Debits / Kredits whisch are mostly coming from the (BSID/BSAD) / (BSIK/BSAK) but for the most records i do not have a Costcenter. But what i know is that for example Items with the KOART 'A' Assets have a costcenter assigned somwehere in the table ANLZ. What i am looking for are the rules with which i can get
the KOSTL the diffrent KOART's in the BSEG.
Which tables and conditions do provide the KOSTL for
KOART EQ 'A' / 'S' / 'M' / 'D' or 'K'. I am new to FI and do not exactly
now the relations / tables.
With that information i will enhance my Extract to that selection logic and i will be fine
hopefully
many thank in advance to all who can help out with any kind of information to that topic.
Regards,
Ali -
How to find the invoice status
how to find the invoice status in ap
Hi,
Please elaborate your question, what Invoice are your referring? AR, AP...
Invoice status can be found from both Front end application or from the backend using SQL query. Also provide your enviornment details to better assist you.
Thanks &
Best Regards, -
How to find Table names for PO & Invoices in SRM Standalnoe system SRM 7.0?
Hi,
How to find Table names for PO & Invoices in SRM Standalnoe system SRM 7.0? Please let me know.
Thanks,
MonicaHi,
In SRM for all objects like SC ( BUS21210),BID,PO(BUS22010),Confirmation (BUS2203),invoice etc all the data stored
in BBP_PDHGP and BBP_PDBEI tables only, These is no separate tables..
for your reference below are the few SRM tables
BBP_PDACC Account Assignment
BBP_PDATT Document Attachment
BBP_PDBEH Backend Specific Header Data
BBP_PDBEI Backend Specific Item Data
BBP_PDBGP Partner Extension Gen. Purchasing Data
BBP_PDBINREL Transaction Object Linkage (EBP)
BBP_PDHCF Set for Tabular Customer and Solution Fields on Hdr
BBP_PDHGP Business Transaction Purchasing Information
BBP_PDHSB Bid Invitation
BBP_PDHSC Header Extension for Customer Fields
BBP_PDHSS Hdr Extension for SAP Internal Enhancements (IBUs and so on)
BBP_PDICF Set for Tabluar Customer and Solution Fields on Itm
BBP_PDIGP Business Transaction Item-Purchasing Information
BBP_PDISB Bid Invitation/Bid-Specific Item Data
BBP_PDISC Item Extension for Customer Fields
BBP_PDISS Item Ext. for SAP Internal Enhancements (IBUs and so on)
BBP_PDLIM Value Limit
BBP_PDORG Purchasing Organizational Unit
BBP_PDPSET Further Procurement Information
BBP_PDTAX Tax
CDCLS Cluster structure for change documents
CDHDR Change document header
CDPOS_STR Additional Change Document - Table for STRINGs
CDPOS_UID Additional Table for Inclusion of TABKEY>70 Characters
CRM_JCDO Change Documents for Status Object (Table JSTO)
CRM_JCDS Change Documents for System/User Statuses (Table JEST)
CRM_JEST Individual Object Status
CRM_JSTO Status Object Information
CRMD_LINK Transaction - Set - Link
CRMD_ORDERADM_H Business Transaction
CRMD_ORDERADM_I Business Transaction Item
CRMD_PARTNER Partners
SROBLROLB Persistent Roles of BOR Objects
SROBLROLC Persistent Roles of Business Classes
SRRELROLES Object Relationship Service: Roles
Thanks & Regards,
Prasad S -
How to find gr details and invoice status for particular list of purchase
Hi,
how to find gr details and invoice status for particular list of purchase orders.
is there any t.code/report for it??Hi,
You use t.code:ME2Nand enter PO number,tn Execute.Now you will have PO details .Now in item details get GR details and Invoice details in purchase order history TAB.
In t.code:MIR5, you can see blocked invoice by selection.
Regards,
Biju K
Maybe you are looking for
-
Jdbc thin driver 8.1.7 and views from older versions of oracle
Config: Windows 2000 | jdk 1.3.1 | oracle's latest jdbc driver 8.1.7, also tried 9.0.1 (classes12.zip), using thin driver I try to select,using a PreparedStatment, from a view on Oracle 8.1.7, the view is linked to a table on Oracle 7.2.2.3. I get di
-
How to save custom Producer Kits?
Hello. I've been trying to save a complete custom mixed/edited producer kit with no succes. There's an article how to load, edit and save the patches, but I haven't been able to make the custom saved producer kits to appear in the library or even in
-
Error when External Acquisition of asset F-90
Hi, i had created entire asset accounting inclient 100 and transaported to client 400 inclueading group asset. now when i am posting F-90 acquisition asset it is geving following error: *Asset 6661 600002-0 is incomplete, check the asset Message no.
-
PLEASE HELP MAIL KEEPS CRASHING!!!!
For some reason my mail keeps crashing. Whenever I try to do anything with my junk mail, the program crashes. If I mark an email as junk it crashes. If I try to move an email out of my junk mail it crashes. Can someone please please please help me ou
-
Mac OS 9 doesn't recognize hard drive
I have an iMac G3 from the summer of 2001, running OS X 10.4.11. I would like to run Mac OS 9 on it, but when I boot from my 9.2.1 retail CD (white with orange 9) and open the Installer, it shows a blank gray box where I should be able to select the