Request for Balance/amount of the historical Transaction summary

Hello

I'm working on a report in which one quantity/must correspond with a quantity / in transactional historical summary.

Amount through my query = quantity in transactional historical summary.

But balance through my query! = Balance in transactional historical summary.


Query is-

SELECT

item_id, SUM (target_value)

Of

(

SELECT

item_id moqv.inventory_item_id, SUM (transaction_quantity * item_cost) target_value

Of

mtl_onhand_qty_cost_v moqv

WHERE

moqv.organization_id =: org_id

AND moqv.inventory_item_id = NVL(:Item_id,moqv.inventory_item_id)

GROUP BY

moqv.inventory_item_id, moqv. Item_Cost

UNION ALL

SELECT

MMT.inventory_item_id item_id,-SUM (transaction_quantity * actual_cost * nvl(currency_conversion_rate,1)) target_value

Of

mtl_material_transactions mmt, mtst mtl_txn_source_types

WHERE

MMT.organization_id =: org_id

AND transaction_date > =: user_date + 1

AND mmt.transaction_source_type_id = mtst.transaction_source_type_id

AND mmt.inventory_item_id = NVL(:Item_id,mmt.inventory_item_id)

Mmt.subinventory_code GROUP, mmt.inventory_item_id

mmt.subinventory_code is not null

)

ITEM_ID GROUP;

Please, someone at - it help me, what changes are required to achieve the desired result.

Thanks in advance

Kind regards

Anurag Sharma

Select cost * quantity balance

Of

(select round(actual_cost,5) cost, inventory_item_id)

Of

mtl_material_transactions one

where

inventory_item_id =: ITEM_ID

and TRANSACTION_DATE<>

and transaction_id = (select max (transaction_id) in the mtl_material_transactions where inventory_item_id = a.inventory_ITEM_ID and TRANSACTION_DATE<=:p_to_date))>

(select item_id quantity, sum (target_qty) of)

(SELECT

target_qty, item_id

Of

(

SELECT

item_id moqv.inventory_item_id, SUM (transaction_quantity) target_qty

Of

mtl_onhand_qty_cost_v moqv

WHERE

moqv.organization_id =: orgn_id

- and SUBINVENTORY_CODE ('PC store', 'STORE of RTV')

GROUP BY

moqv.inventory_item_id, moqv. Item_Cost

UNION ALL

SELECT

MMT.inventory_item_id item_id, target_qty SUM (transaction_quantity)

Of

mtl_material_transactions mmt, mtst mtl_txn_source_types

WHERE

MMT.organization_id =: orgn_id

AND transaction_date > =: p_to_date + 1

AND mmt.transaction_source_type_id = mtst.transaction_source_type_id

- and MTM. SUBINVENTORY_CODE ('PC store', 'STORE of RTV')

GROUP BY mmt.inventory_item_id

)

WHERE item_id =: ITEM_ID

) z, msi mtl_system_items

where msi.inventory_item_id = z.item_id

and msi.organization_id =: orgn_id

Group item_id) xyz

where xyz.item_id = abc.inventory_item_id

Thanks for the help... I found the solution.

Tags: Oracle Development

Similar Questions

  • I want to cancel the request for cancellation of my current account transaction

    I had accidentally canceled my account with impatience and impulsive and had obtained an email notification reminding me that the transaction will take place on August 25. I wanted to cancel this process and just keep my account as is. Is this possible?

    This is an open forum, not Adobe support... Click below to contact Adobe staff for help

    While the forums are open 24/7 you can't contact Adobe support at any time

    Chat support: Mon - Fri 05:00-19:00 (US Pacific Time)<=== note="" days="" and="">

    Don't forget to stay signed with your Adobe ID before accessing the link below

    Creative cloud support (all creative cloud customer service problems)

    http://helpx.Adobe.com/x-productkb/global/service-CCM.html

  • Create the request for approval to remove the user operation with IOM api-11 g Release2

    Hello

    How do I create an approval request for an API using operation user remove? Can someone guide me? Any help is greatly appreciated...


    ARO
    Aliye

    You must use the new API set to create the request. OIM 11 g R2 supports model not application so your code will be changed.

    Examples: http://docs.oracle.com/cd/E27559_01/doc.1112/e28183/oim_up.htm#BABGBEHG

  • Problem installing Firefox 3.6.8 as error "no request for assistance" to open the file

    Used a netbook Asus Linux / Firefox version 2.0.0.0.11 for 3 years without problems. Now I can't use "Hotmail" on it, because it requires an update to the version as above.

    It appears to download but not to open it and I get the message "could not be opened because there is no such thing as the doe to request assistance associated with" I'm not sure where I should be downloading it too but chose home/user.

    I use very basic but verified the file 'open with' settings and there is no demand for a tar.bz2

    Any advice would be much appreciated

    Have you read all the 12 pages of this thread?

    http://Forum.EeeUser.com/viewtopic.php?id=41815

    I can't help myself, because I have done this process once and I wasn't happy with Firefox 3 on Asus / Xandros when I was tired. The next day, I installed Ubuntu 10.04 - EasyPeasy remix - http://www.geteasypeasy.com/

  • OIM11GR1 - request for additional attribute on the approval of the task

    Hello

    I've already set up a process in console design to assign a task to someone when a creation of the user is requested (in the assignment tab). When this person validate the task, the user is created.

    Today, the validator of request can just validate or deny the task.

    I would like to know if it was possible to provide an additional field for the validator request where he can put additional information.

    Here is an example of what I'm trying to achieve:
    A configuration of resource is requested with the creation and assignment of a badge.
    The 'referent of the badge"will receive a task where he will ask you to validate the assignment and provide the badge number.
    Commissioning is launched with the provided badge number.

    Thanks in advance

    You can have the dataset application to this effect and mark this extra attribute in 'single approver. Then, the approver can provide data while approving

    link below will help you to configure even
    http://docs.Oracle.com/CD/E14571_01/doc.1111/e14309/request.htm

  • 2nd signature required is not requested for: document finalised after the first signature!

    We are VERY DISAPPOINTED that it is obviously not more direct support of this product, or is phone - this not correct? If so, we don't remember this change notification.

    Speaking of which, without any alteration to a form of signature which includes three steps: 1) Prefil, 2) all the information and signed by the client and 3) countersign date by us and all of a sudden after working for months, he comes back and is supposed to be completed once step 2 is completed. There is no way later to fill the countersignature. I checked that the fields are still reported as such, but very recently, the third stage (without date or signature even filled) ends from step 2 is done. Something is broken and it is apparently not possible to get immediate assistance from Adobe on this.

    Things change suddenly in the way that documents are processed without warning advanced e-mail, then suddenly things break and there is nobody to contact directly for assistance. It turns out that if we go back to the classic shape everything works fine because you still have the box "I have need to sign. The 'new' shape (of shit) said anything about it? NO! Instead, he proposed adding a "me" and various other areas, with absolutely no explanation of what they are and how they are supposed to work!  Thank you, Adobe, make the new procedure so obvious and undocumented. NOT.  I should send you a bill for all the time spent trying to figure this on my own because of the absence of any reasonable support more. You are a paper company, but you seem unable to adequately document your own products. Taking the human support was a horrible move on your part - it could have been resolved in 5-10 minutes. In any case, it is marked and done and resolved and I hope and pray I will never work on a question like that again. You're just better not take the classic option.

  • There is no request for 'Shared Services' in the Group of the Foundation

    Hello world!

    I am facing a problem during the installation of the EPM system.

    After the deployment of Foundation services, there is no demand for services registerd shared in the Group of the Foundation

    I looked in 'Shared Services' = > 'Groups Appication' = > 'Foundation' only -Manager of calculation and -EMP architect

    I tried to redeploy the service of the Foundation, but is not shared Services Application

    I looked in the table HSS_COMPONENT with COMPONENT_TYPE = 30 and did not find the Shared Services

    This application exists on the production server, I tried to export application Service sharing of production on the new server using LCM, but error

    EPMLCM-18000: name of the invalid application - SSP MDF.

    Everyone knows how to save Shared Services Application?



    Solve the problem by inserting manually lines HSS_COMPONENT, HSS_COMPONENT_PROPERTY_VALUES, HSS_COMPONENT_LINKS

    as on the production server

    insert into HSS_COPMONENT values (' 1111.HUB ',' Shared Services ', 30)

  • Request for an update in the sys.registry$ view history


    Hi all

    I have successfully installed the July 2013 PSU on oracle 11g.

    Know that when I ask the sys.registry view $history it still shows the old patch time and date.

    Select ACTION_TIME, VERSION, COMMENT of the sys.registry$ history.

    3 MARCH 13 09.13.27.539465 AM 11.2.0.2

    POWER SUPPLY 11.2.0.2.9

    Can some please update me on this.

    Thanks in advance.

    You must run the psu catbundle apply that script inserts at the end entry in the history table.

    This step is in the Readme for the patch.

  • How to ignore requests for password when creating the DB with the DBCA shel scripts

    When generate a database with scripts automatically passwords DBCA asks 1 2 times at the beginning and 1 initializing ora.ini DB.

    I should replace the lines as
    Connect "SYS" / "' & & sysPassword ' as SYSDBA"
    with the password that is real because it's a public password to test databases.

    P. S.
    If these questions are not apropriate and a burden for the cmmunity you can inform me.
    Up to now, if I can't find something on common search keywords, I add it, believing it to be a contribution to the knowledge base of the Oracle communities

    I found the solution. As MarkDPowell has pointed out, invited because ACCEPT input so have to comment on it.

    And I can pass my own password public as a variable to SET - http://docs.oracle.com/cd/B10501_01/server.920/a90842/ch13.htm#1008884

    P. S.

    I'm trying not to let the non-answered son.

  • Make a request for generic insertion in the ODI procedure

    Hello
    I am writing an ODI procedure to insert into a table my sql is simple:

    Insert into ci_txn_header_k
    Select t.txn_header_id, f.env_id
    of ci_txn_header t, f1_installation f
    where t.bo_status_cd = 'HANGS' and t.txn_header_id not in (select txn_header_id from ci_txn_header_k)

    I want to make this generic query and use the functions of REF ODI in it.can I get the schema name and table using the Odiref functions. If yes then please guide me how

    Hello

    Import all tables referred to in your query in a logic model / models.

    ci_txn_header_k
    ci_txn_header,
    f1_installation f

    Suppose you import the tables into a logic model / schema called "GENERICS".

    Then just reference them using <%=odiRef.getObjectName("L""CI_TXT_HEADER","GENERIC","GLOBAL","D")%>

    IM using the "GLOBAL" context in my example above, replace with your context.

    So, something like:

    Insert in <%=odiRef.getObjectName("L","CI_TXT_HEADER_K","GENERIC","GLOBAL","D")%> k
    Select t.txn_header_id, f.env_id
    Of
    <%=odiRef.getObjectName("L","CI_TXN_HEADER","GENERIC","GLOBAL","D")%> t,
    <%=odiRef.getObjectName("L","F1_INSTALLATION","GENERIC","GLOBAL","D")%> f
    where t.bo_status_cd = 'HANGS' and t.txn_header_id not in (select txn_header_id from <%=odiRef.getObjectName("L","CI_TXN_HEADER","GENERIC","GLOBAL","D")%>)

    Hope this helps, check out the ref of the Substitution of the API for a guide, also worth looking at knowledge Modules and how they accumulate clauses in LKM and IKM steps - you can learn a lot by referencing existing code that is supplied with the product.

    Concerning
    Alastair

  • Request for ASO - changes to the Dimension type

    I changed 6 of 19 dimensions in my application for ASO of "multiple hierarchy enabled" to "stored". The dimensions changed used to have 1 single hierarchy (stored) under them. Rebuild and reload the data, the cube displays a different number? No idea why this phenomenon occurs?
    Old and new applications both use the default aggregations.
    Thanks in advance.

    Published by: wines on 5 March 2012 15:50

    When you enable multiple hierarchies enabled, it makes the Member of dimension one label only and takes the total of the first hierarchy (First member) underneath. If you change stored, its possible you aggregate now multipe groupings that you knew were being considered as hierarchies.

  • I have an Error 80070002 0 x or 0 x 80070003 normal fact shares this request for microsoft to deleating the DataStore folder. Still can't download updates__

    1. Delete the contents of the DataStore folder
    2. Click Start.
    3. Choose run.
    4. In the run box, type %windir%\SoftwareDistribution.
    5. Click OK.
    6. Open the DataStore folder.
    7. Delete all the contents of the DataStore folder.
    8. Close the window.

    fact all this and nothing

    -Mr. Fixit tool should take care of himhttp://support.microsoft.com/default.aspx/kb/971058

  • (Redirected) Its an urgent request for everyone, please post the solution to the problem in my laptop.

    My laptop model number is Inspiron 7520 15RSE. with i5 processor. and the amd graphics card.

    I have 4 experience problems in my laptop.

    1. whenever I press the power button to turn on my laptop, my screen becomes yellow with a horizontal silver line between the two and beep to start with a small break after 8 beeps and this process will continually. until and unless I have press the power button.  I HAV tried formatting my windows (complete clean install), but the problem persists. and occurs at least 5 - 7 times a day each time I turn on my laptop

    2. the problem is with my driver elantech touchpad touchpad, that is, every time that change the speed of the cursor of the mouse via the elantech touchpad software and then after restarting pc it always come back to its default position. I HAV tried to reinstall windows, then install the latest updated drivers but the problem still persists.

    3. my catalyst Control Center does not work, I am not able to open the graphics properties and configure switchable graphics. It always gives me a message. control of catalyst application has stopped working.

    I HAV tried installing the latest video of the dell website driver, but the control center does not open. Help, please.

    4 color screen my sometimes becomes dark and light whenever I try to open something. like browsing, watching video.

    I kknow that the problem is in the hardware, so please help me... : ()

    As you have a laptop, better make this laptop in the computer Forum post here:

    http://en.community.Dell.com/support-forums/laptop/default.aspx

    Bev.

  • Any request for a list of the custom components in system

    Hello

    Is there any question to find the list of the custom components in the system.

    Concerning

    Jagadish

    What is the purpose of a list of custom components?

  • Cancellation of a request for a refund

    I ordered an item on my iPad from Udemy. The iPad repeated that its cancellation all the time so I used a problem report to request a refund. Not two minutes passed, and I got the price I had paid for.

    I do not want to cancel the request for reimbursement, but all the lists I see are for people who want money.

    Your help is very appreciated.

    I think that it is best to contact iTunes Support: http://apple.com/emea/support/itunes/contact.html.

Maybe you are looking for

  • Camera remote for iPhone 5

    I'm looking for a remote camera for my iPhone 5. When I go out for a walk and met interesting shot as a deer... but by the time I pull on the phone, unlock, open the device and set up for the shot... a lot of time has passed and shooting very often d

  • Satellite A200 shows weird coloured horizontal lines

    These multicolored horizontal lines with different lengths appear on my laptop.Soon they jump all over the place, and then the screen turns off. I get the blue screen saying something went wrong and restart my computer... I don't know what the heck i

  • Satellite P300 freezes 2-3 sec while music, movies, games

    Hello! Well, this my last hope.When I'm listening to the music, watch movies or play games my computer hangs for 2-3 seconds with a strange BEEP.When happened the first time I formatted. Was ok at first, but the situation returns!I don't know what to

  • A lot of Questions of Helix / Rognes

    So I had my Helix after months of hanging out and waiting in hope, is to be a decent Warrior gear. Is two weeks and about 15 000 miles with her to this day. I have been a long X series fanatic and have to admit that this is the first time I've ever h

  • After the vista update, the file came out: \boot \BCD with status 0xc000000f. window cannot start and no response my installation dvd

    Last week I've updated in my vista once it was released the file: \boot \BCD with status 0xc000000f. I put my recovery disk window answered, is not obtained in the boot, press F8 did so. I considered that my hard drive was broken, so I changed the ha