A/R Statement Query
I am attempting to create an A/R statement for a business partner on our local intranet. It is a simple matter to get open invoices and credit memos, my problem is with certain payments.
When a business partner over pays on the account there is no invoice to apply the over payment too. These are entered as negative payments. If they are not related to a particular invoice or credit, SAP will ask you if you want to apply the negative payment as a u201CPayment on Accountu201D. We answer Yes and the negative payment shows open on the business partner as a Negative u201CIncoming Paymentu201D . At some point these are manually reconciled. What table would I get these unreconciled negative payments from?
I do not know how to pull these from a table. Any help would be greatly appreciated.
Thanks, Sam
Sam,
The details are in the Receipts table (ORCT).
Check this query
SELECT T0.DocNum AS 'Document Number', T0.DocType AS 'Document Type', T0.DocDate AS 'Posting Date',
T0.DocDueDate AS 'Due Date', T0.CardCode AS 'Customer/Vendor Code', T0.CardName AS 'Customer/Vendor Name',
T0.PayNoDoc AS 'Non-Calculated Payment', T0.NoDocSum AS 'Non-Calculated Amount', T0.DocTotal AS 'Document Total'
FROM [dbo].[ORCT] T0
WHERE T0.PayNoDoc = 'Y'
Similar Messages
-
How to edit the records value fetched by select statement query in sqldever
How to edit the records value fetched by select statement query in sqldever 2.1.1.
EX-
SELECT * FROM emp WHERE ename like 'Jaga%'
Edited by: user9372056 on Aug 31, 2010 2:16 AMHi,
Although some forum members may be using that tool, there is still a dedicated forum for SQL Developer.
SQL Developer
Maybe your chances are better there.
Regards
Peter -
Hi,
I had used the RSZC transaction to migrate query 0FIGL_VC1_Q0002 - Cash flow statement, based on 0FIGL_VC1 to a custom virtual cube which extracts data from a cube containing general ledger accounting (New) data. on execution of the query, no data is displayed.
In a similar fashion the query 0FIGL_V10_Q0001, which is based on virtual cube 0FIGL_V10 was migrated to the same custom virtual cube and was found to be executing.
has anyone faced similar issue with cash flow statement query?
Regards,
SainathLook at the import parameters - there is a hard coded and change it to Z version
https://forums.sdn.sap.com/click.jspa?searchID=10104420&messageID=5012838
Hope it Helps
Chetan
@CP.. -
Printing Prepared Statement Query
Hi all,
Is it possible to print Prepared Statement query. When i give System.out.println(query);, i get the query with '?' and not with the actual value sent. How can i print the query with the value passed in place of the '?' ?Hi all,
Is it possible to print Prepared Statement
tatement query. When i give
System.out.println(query);, i get the query with '?'
and not with the actual value sent. How can i print
the query with the value passed in place of the '?' ?The simple answer is that you can't (AFAIK), but some database drivers are able to log the sql statements.
Kaj -
Hi All,
Can some one help me in writing the stock statement query which includes
Warehouse Code, Inventory Transfer No, Inventory Transfer Date, Item Code, Item Description, Batch No/Serial No, Expiry date, Delivery Note No if any
We have add on which links the Inventory Transfer to Delivery. We can copy the inventory transfers to delivery where inventory transfer no will be stored in the item level UDF (u_delno)
Thanks in advanceTry from here to start:
Select T1.WhsCode, T0.DocNum, T0.DocDate, T1.ItemCode, T1.Dscription, T1.SerialNum, T1.u_delno
FROM dbo.OWTR T0
INNER JOIN dbo.WTR1 T1 ON T1.DocEntry = T0.DocEntry
Thanks,
Gordon -
EJB Transaction timeout and Statement Query Timeout
I am looking for some details on how statement query timeout is set when statement execution is part of the session bean transaction. I have done some test in webshere 6.1. and JBoss 5.0 and not getting the desired behavior. My understanding is following
- DB is Oracle 11g
- EJB transaction is set to 5 mins.
- Query time out setting is set to default vaule (not sure what is the default value)
- Session bean is updating say customer record using PreparedStatement
- Prior to calling session bean method I am locking the customer record using external/db tool and holding the lock.
- Call session bean method. Method waits endlessly for the lock to be acquired. No transaction rollback after 5 mins.
- After 10 minutes commit the transaction in the external db tool
- Session bean methods throws transaction rollback.
My understanding was that query timeout is set based on transaction "time to live". Please share out thoughts.
Edited by: hdjava on Jun 18, 2010 1:06 PM
Edited by: hdjava on Jun 18, 2010 1:07 PMThe following configuration seems working:
version: OC4J (9.0.3.0.0) (build 020927.1699)
AM deployment:
- bc4j.xcfg: <jbo.ejb.txntimeout>30000</jbo.ejb.txntimeout>
- orion-ejb-jar.xml: <session-deployment name="..." timeout="0"/>
OC4J config:
- data-source: inactivity-timeout="30000"
This keeps connection open for more than default 30 mins of inactivity (30000 secs configured).
Although, oc4j console prints multiple warnings:
DriverManagerConnectionPoolConnection not closed, check your code!
Looks like this is not an intended usage - but working.
Notice that it was a test, not a production environment.
Also pls see 9033: AM as EJB Session bean: pooled connection lost for new txn
I would be thankful for any experience in running AM Session EJB w/o timeout. -
Help needed on income statement query....
Hello BW gurus,
I need to make an income-statement query which gives the following output.
The 5 Variables are
Company Code
Plant
Fiscal Period (12 months) in column
Value Type
Version
#ACCOUNT 0METYPE METYPE-DESCRIPTION COMPANYCODE PLANT SALES0RG
Sales
Cost of Sales
Gross Margin
(Sales minus Cost Of Sales)
General &Admin
Other
Operating Income
(Gross margin minus G&A minus Other)
Interest Income
Interest Expense
Net Income before Tax
(Operating Income minus Interest Income - Interest expense)
Taxes
Net income
(Net Income before Tax minus Taxes)
Note: Sales,cost of sales,general and admin,other,interesat income,interest expense,taxes are under the hierarchy of ACCOUNT.
Please make a quick response.
100% points will be awarded.
Thanks in advance.
Sam MathewPlease read these:
When your query takes too long
When your query takes too long ...
How to Post a SQL statement tuning request
HOW TO: Post a SQL statement tuning request - template posting -
General stock statement query.
hi ,
can anybody help me in getting stock statement query.... no selection criteria it has to disply all the ware house with Opening stock......inward qty, outward qty,closing stock . (this general) and like this i have to get stock details date wiseHi Vignesh......
I'm in confusion. You are asking the same question with different meanings.
As you are already suggested to use Inventory Posting List. You get all of your answers to your question.
It will give you the stock Opening, In, Out, Closing Warehouse Wise (Particular/All), Date wise, Transaction wise...
Please check this path to refer This Report.
Inventory->Inventory Reports-->Inventory Posting List......
If you have different requirement then please do mention.
Regards,
Rahul -
Have any one got the stock statement query report in the folowing format....
1.ItemCode
2.Item Description
3.Item Price
4.Opening
5.Receipts
6.Issues
7.Closing
8. Value
The selection criteria are:
3.Posting Date
from wh
to wh
help me in making stock statement query
regards,
VigneshHi
Check This
select w0.itemcode, i0.docdate, w0.whscode, w0.onhand - isnull (sum (i0.inqty - i0.outqty), 0), 0
from oitw w0 left outer join oinm i0 on w0.itemcode = i0.itemcode and w0.whscode = i0.warehouse
where i0.docduedate >= [%0]
group by w0.itemcode, w0.whscode, w0.onhand, i0.docdate
having w0.itemcode = [%1] and w0.onhand - isnull (sum (i0.inqty - i0.outqty), 0) >= 0
union
select w0.itemcode, i0.docdate, w0.whscode, 0, -(w0.onhand - isnull (sum (i0.inqty - i0.outqty), 0))
from oitw w0 left outer join oinm i0 on w0.itemcode = i0.itemcode and w0.whscode = i0.warehouse
where i0.docduedate >= [%0]
group by w0.itemcode, w0.whscode, w0.onhand, i0.docdate
having w0.itemcode = [%1] and w0.onhand - isnull (sum (i0.inqty - i0.outqty), 0) < 0
or
SELECT T0.ITEMCODE, T0.DSCRIPTION,T0.OPENQTY, T0.OPENVALUE, T0.INQTY, T0.INQTY*T0.PRICE AS 'RCPT VAL', T0.OUTQTY,T0.OUTQTY*T0.PRICE AS 'ISS. VAL', T0.INQTY-T0.OUTQTY AS 'CLOSING STOCK QTY',((T0.INQTY-T0.OUTQTY)*(T0.CALCPRICE)) AS 'CLOSING STOCK VAL' FROM OINM T0 WHERE T0.DOCDATE >=[%0] AND T0.DOCDATE <=[%1]
Thanks
Kevin
Edited by: Kevin Shah on Oct 23, 2010 5:37 PM -
Hello All -
We would like to develop a query that shows us monthly sales by each US state and OUS locations. For example, on the left most column, we would have each location. Then subsequent columns to the right of that would have sales for each location in Jan, Feb, March, etc.
Can anyone help with this?
Thanks,
MikeI tried first three months below:
SELECT T0.State1 AS 'Bill-to State', (SELECT SUM(T1.DocTotal) FROM OINV T1 with (NOLOCK) INNER JOIN OCRD T2 ON T2.CardCode=T1.CardCode
WHERE MONTH(T1.DOCDATE) = 1 AND T2.State1 = T0.State1
AND YEAR(T1.DOCDATE) = YEAR(GETDATE())) AS 'JAN Amt', (SELECT SUM(T1.DocTotal) FROM OINV T1 with (NOLOCK) INNER JOIN OCRD T2 ON T2.CardCode=T1.CardCode
WHERE MONTH(T1.DOCDATE) = 2 AND T2.State1 = T0.State1
AND YEAR(T1.DOCDATE) = YEAR(GETDATE())) AS 'FEB Amt', (SELECT SUM(T1.DocTotal) FROM OINV T1 with (NOLOCK) INNER JOIN OCRD T2 ON T2.CardCode=T1.CardCode
WHERE MONTH(T1.DOCDATE) = 3 AND T2.State1 = T0.State1
AND YEAR(T1.DOCDATE) = YEAR(GETDATE())) AS 'MAR Amt',
FROM dbo.OCRD T0 LEFT JOIN dbo.OINV T1 ON T1.CardCode = T0.CardCode
GROUP BY T0.State1
ORDER BY T0.State1
But did not get any data -- not sure what I am doing wrong?!
Mike -
Doubt in Cash flow Statement Query
Hi all,
In FI module i am trying to create query 'Cash flow statement' using infocube 0figl_c01.
For 'cash inflow' i restricted to debit postings for G/L account char. with two account number (200602 & 200611 as given by finance dept.) But the values are not matching as it extracts all the entries which come to that account for the posting period. But my requirement is to take only the entries related to document type 'DZ - Customer Payments' (for which there is no char. in the infocube or in the R3 Extractor).
How to solve the issue. do i have to create a generic data source and change the infocube?
Thanks,
PrakashHi Vachan,
Thx for the reply.
The entries in the InfoCube is correct. Is there any other method by which i can solve this problem. Because changing the datasource and InfoCube is tedious at this time.
Regards,
Prakash -
I have a peculiar problem related to update statement.
In a table "table1" I have the following values for the column Name.
John
Doe
Adam
Teela
I need to do the following updates
John -> Adam
Doe -> Teela
Adam -> Doe
Teela -> John
One way of doing it would be to use the ROWID.
Update table1 set value=Adam where ROWID=1
Update table1 set value=Teela where ROWID=2
and so on and so forth.
But I don't want to use the ROWID.
Therefore the logical query that one would write is
Update table1 set value=Adam where value=John
Update table1 set value=Teela where value=Doe
Update table1 set value=Doe where value=Adam
Update table1 set value=John where value=Teela
But immediately the problem becomes apparent.
The converted table would now look like this
Doe
John
Doe
John
How do I make sure that the updation happens as I intend? Is there a way to work around it without ROWID?
Message was edited by:
user574608Much too late, but I don't want to have made it in vain ;) :
michaels> CREATE TABLE table1 (ID INTEGER,VALUE VARCHAR2(10))
Table created.
michaels> INSERT INTO table1
VALUES (1, 'John')
1 row created.
michaels> INSERT INTO table1
VALUES (2, 'Doe')
1 row created.
michaels> INSERT INTO table1
VALUES (3, 'Adam')
1 row created.
michaels> INSERT INTO table1
VALUES (4, 'Teela')
1 row created.
michaels> UPDATE table1
SET VALUE =
CASE VALUE
WHEN 'John'
THEN 'Adam'
WHEN 'Doe'
THEN 'Teela'
WHEN 'Adam'
THEN 'Doe'
WHEN 'Teela'
THEN 'John'
END
4 rows updated.
michaels> SELECT *
FROM table1
ID VALUE
1 Adam
2 Teela
3 Doe
4 John
4 rows selected. -
Profit and Loss Statement Query
Hello Experts,
I want to make customize profit and Loss Report using User Defined form with Grid view or Crystal Report. I need SQL Query , what tables will give P & L Statement Report(yearly/ monthy / quarterly).
Already available Query will be very helpful
Please Suggest
Quick Reply will be very helfulHi,
Try this to start:
SELECT T0.[FormatCode], T0.[AcctName], SUM(T1.[Credit]-T1.[Debit]) Balance
FROM OACT T0
INNER JOIN JDT1 T1 ON T0.AcctCode = T1.Account
INNER JOIN OJDT T2 ON T1.TransId = T2.TransId
WHERE T0.[ActType] in ('I','E') and DateDiff(YY,T2.[RefDate],GetDate()) = 0 AND T1.[Debit] != T1.[Credit]
GROUP BY T0.[FormatCode], T0.[AcctName]
Having SUM(T1.[Debit]-T1.[Credit]) != 0
ORDER BY T0.[FormatCode]
If you are using natural account, replace FormatCode with AcctCode.
Thanks,
Gordon -
Hi All,
Just need some help on this:
Scenario: I created a query on the stats multiprovider.
The query shows exceptions (red / green) indicating that data is loaded successfully to data targets or not.Red for failure and green for success.It is just supposed to show colors as it is used by end users.
Problem : What happens is at times wen data is loaded fine to the data targets but 0 records updated its showing red! which is a concern as its quite misleading for users. they are taking it to be data load failed though its actually a zero records update through full -update.Now i checked the table RSDDSTATWHM for such requests.There seems to be no entries in that table too.
Is it connected or can some one suggest how to handle this scenario.Its again a production environment and needs quick resolution.....tell me if you want to knw more about it..........Check your traffic light settings in transaction SPRO?
It's under the following path or similar path:
SAP BIW => Automated Processes => Monitor Settings => Set Traffic Light Color.
Don't forget the points if that helps...
Ken -
Hi All,
Just need some help on this:
Scenario: I created a query on the stats multiprovider.
The query shows exceptions (red / green) indicating that data is loaded successfully to data targets or not.Red for failure and green for success.It is just supposed to show colors as it is used by end users.
Problem : What happens is at times wen data is loaded fine to the data targets but 0 records updated its showing red! which is a concern as its quite misleading for users. they are taking it to be data load failed though its actually a zero records update through full -update.Now i checked the table RSDDSTATWHM for such requests.There seems to be no entries in that table too.
Is it connected or can some one suggest how to handle this scenario.Its again a production environment and needs quick resolution.....tell me if you want to knw more about it..........Tina,
Try setting the behavior of loading 0 records from within the monitor to get rid of this issue.
1/ Navigate to the monitor tx RSMON
2/ Choose the "Settings" menu item
3/ Choose the "Evaluation of Requests (Traffic Lights)" option
4/ Here you can choose how to evaluate 0 records, set this to green.
Hope this helps
Cheers,
Scott
Maybe you are looking for
-
Gestures and dock not working in Mavericks
Results from EtreCheck Hardware Information: MacBook Pro (13-inch, Early 2011) MacBook Pro - model: MacBookPro8,1 1 2.3 GHz Intel Core i5 CPU: 2 cores 8 GB RAM Video Information: Intel HD Graphics 300
-
I am getting a Changing Password Failed error when I try to join an active directory
I had a working AD configuration under Snow Leopard. When I upgraded to Mountain Lion, my account was no longer in sync with the domain. I got the red dot on the login screen and my domain password was out of sync. I unhooked from the domain at that
-
I am using Captivate v4. Is it possible to select different elements placed onto a slide and create a "group" - as is possible in PowerPoint ? For example - I have created an magnified view of an area visible on the slide itself. I have placed around
-
I have a 5800 with v3.0 firmware. I am having trouble internet browsing At times it will connect perfectly and then other times it will not connect at all and gives messages like: Service is not part of active profile Gateway time out and something a
-
Problems with libraries and plugins - non admin account
I''ve got a couple of problems with a fresh install of photoshop on my windows Windows 7 64 bits system. 1. Libraries panel does not work. It displays the following error and interaction is not possible: 2. 3rd party plugins would load their content.