How can i use calculation from one sheet into another sheet in discoverer

I have a function which has to be used for several calcualtions in discoverer report.For each row the function is called 8 times, Is there any way that i can create a caculation based on the function in one tab and use this value returned by the function in the other tabs in the discoverer so that i can eliminte the function being called 8 times for each row.
Please help.

Hi Lloyd ,
Thanks for the reply. See below for the detail explanation of what i am Talking about.
I am Developing a Operational Expense Report based on a Custom Table.
I get the following columns from the custom Table - Account, Amount Manual, Amount Local, Amount Overseas.
Then I have two Functions which Calculates two different Ratios Based on the other Custom Table.
1st function - Qualifying Sales Ratio
CREATE OR REPLACE FUNCTION xxwfs_avi_q_sales_ratio (p_period VARCHAR2)
RETURN NUMBER
IS
v_q_ratio NUMBER := NULL;
BEGIN
SELECT ROUND ((a.nonqualified_ar_amount / b.nq_nq_ar_amount), 4) qualifying_sales_ratio
INTO v_q_ratio
FROM (SELECT SUM(NVL(gp.total,0)) qualified_ar_amount
FROM xxwfs_gp_table gp
WHERE gp.company = 24101
AND gp.gtp_qualified = 'Q'
AND gp.org_id = 126
AND gp.gl_date >= p_from_date
ANDgp.gl_date <= p_to_period) a,
(SELECT SUM(NVL(gp.total,0)) nq_nq_ar_amount
FROM xxwfs_gp_table gp
WHERE gp.company = 24101
AND gp.gtp_qualified in( 'Q','NQ')
AND gp.org_id = 126
AND gp.gl_date >= p_from_date
ANDgp.gl_date <= p_to_period) b;
RETURN v_q_ratio;
EXCEPTION
WHEN OTHERS
THEN
v_q_ratio := 0;
RETURN v_q_ratio;
END xxwfs_avi_q_sales_ratio;
2nd Function - Nonqualifying Sales Ratio
CREATE OR REPLACE FUNCTION xxwfs_avi_nq_sales_ratio (p_period VARCHAR2)
RETURN NUMBER
IS
v_q_ratio NUMBER := NULL;
BEGIN
SELECT ROUND ((a.nonqualified_ar_amount / b.nq_nq_ar_amount), 4) nonqualifying_sales_ratio
INTO v_q_ratio
FROM (SELECT SUM(NVL(gp.total,0)) nonqualified_ar_amount
FROM xxwfs_gp_table gp
WHERE gp.company = 24101
AND gp.gtp_qualified = 'NQ'
AND gp.org_id = 126
AND gp.gl_date >= p_from_date
ANDgp.gl_date <= p_to_period) a,
(SELECT SUM(NVL(gp.total,0)) nq_nq_ar_amount
FROM xxwfs_gp_table gp
WHERE gp.company = 24101
AND gp.gtp_qualified is not null
AND gp.org_id = 126
AND gp.gl_date >= p_from_date
AND gp.gl_date <= p_to_date) b;
RETURN v_q_ratio;
EXCEPTION
WHEN OTHERS
THEN
v_q_ratio := 0;
RETURN v_q_ratio;
END xxwfs_avi_nq_sales_ratio;
The report is Run based on the parameter for the Range of gl_date.
I registered these functions in discoverer and passing the parameter values to calculate the ratios. The 2 ratios are just one time calculations for the range of gl_date the report is run.
The i mulitiply Qualifying Sales Ratio with the columns Amount Manual, Amount Local and Amount Overseas to get Qualifyied Amount Manual, Qualified Amount Local , Qualifyied Amount Overseas and the Nonqualifing Sales Ratio with the same Amount Manual, Amount Local and Amount Overseas columns to get NonQualifyied Amount Manual, NonQualified Amount Local , NonQualifyied Amount Overseas.
This is the design i am approching now. For each record the function is called 8 times to calculates the qualifying and Non qualifying Sales ratios Ato caculate the other 6 columns based on these Ratio Calculations.
So i was thinking if there is any way that i can get the Ratios for a specific date range in the First tab and usethe Value of the ratios in the other tab so that the function call is minimized.
Waiting for your replies.

Similar Messages

  • How can I using tpcall from one service to another service in the same server

    When I using tpforward between two services in one server, it's working ok. However,
    when I using tpcall from one service to another service, it's failed?
    anybody can tell me why?
    thanks
    george

    "george" <[email protected]> wrote:
    >
    When I using tpforward between two services in one server, it's working
    ok. However,
    when I using tpcall from one service to another service, it's failed?
    anybody can tell me why?Basically, tpcall:ing another service in the same server is a no-no, unless you
    a) are running a multi-threaded server (requires TUXEDO 7 or newer + compilation
    options) or
    b) use tpacall() instead of tpcall() and specify the flag TPNOREPLY. This is probably
    not what you want to accomplish, though.
    The reason is that TUXEDO servers by default (and always in versions before 7)
    are single-threaded. If service A and B both reside in server X, server X will
    be busy taking care of the call to A. If A makes a call to B, the call will be
    put on the queue to X, but X will not look at the queue until it is done with
    A, which won't happen until B returns... deadlock!
    You can play tricks with starting multiple instances of X, but in the end you
    will always face a risk (something lika a race-condition) for a dead-lock.
    Solution: Move service B to another server (usually quite easy) OR switch to multi-threading,
    if that's possible. Just make sure all code your service calls is MT-safe as well...
    thanks
    georgeHope this helps you,
    /Per

  • How can I use footage from one project in another?

    The best format for saving your video from one project so that it can be used in another Premiere Elements project is DV-AVI. For hi-def video, the format is HDV.
    To save your video as a standard-definition DV-AVI, go to Share, Personal Computer and select the AVI output option with the DV preset. When you're ready to mix together these segments open a new project using the DV settings and assemble them on that timeline.
    To save your video as a high-definition M2T video, go to Share,  Personal Computer and select the MPEG output option with the 1440x1080 MPEG preset. When you're ready  to mix together these segments open a new project using the HDV settings  and assemble them on that timeline.

    The best format for saving your video from one project so that it can be used in another Premiere Elements project is DV-AVI. For hi-def video, the format is HDV.
    To save your video as a standard-definition DV-AVI, go to Share, Personal Computer and select the AVI output option with the DV preset. When you're ready to mix together these segments open a new project using the DV settings and assemble them on that timeline.
    To save your video as a high-definition M2T video, go to Share,  Personal Computer and select the MPEG output option with the 1440x1080 MPEG preset. When you're ready  to mix together these segments open a new project using the HDV settings  and assemble them on that timeline.

  • How can I automate pasting from one document into another?

    Hi, I have a need for a document that I am regularly appending a blank form from another document to. I would typically just open the second document and select and copy the block of text and then return to my working document and enter a page break and then paste in the form, over and over.  I do this so often that a way to automate this would be a huge help.  However I have had little luck working with automator myself probably because I am missing something.  But I would appreciate any ideas....Thanks

    If you took time to read carefully Pages User Guide, you would know this well described feature :
    and you would use it to build a template as I urged you to do.
    Yvan KOENIG (VALLAURIS, France) vendredi 29 avril 2011 14:42:20
    Please :
    Search for questions similar to your own before submitting them to the community

  • How to get a value from one item into another

    How can i get value from one item into another item.
    Ex: I have a report, in there i have check boxes, and when i have checked some rows, and press submitt, a prosses computates it into a item on another page, and a branche redirects to page 3. Then i'm going to use the value in the item into a PL/SQL script in an report to show the submittet items.
    How can i do this?
    Computation script, pages and all that is fixed. But i dont know which PL/SQL statement to use to get th value from the item.

    Hi Fredr1k,
    Use the V() function from pl/sql.
    e.g. V('P3_MY_ITEM')
    will return the value of that page item.
    As long as the pl/sql is called from within the Apex environment.
    Regards
    Michael

  • How can I copy text from one card to another while creating cards using Iphoto?

    I created two cards with different pictures using Iphoto on Macnotebook. 
    I want to use the same text message.
    How can I copy text from one card to another?

    select the text and copy (edit menu ==> copy) tehn gpo to the next card and paste
    LN

  • HT201250 how can i pass information from one mac to another mac by using the time capsule

    how can i pass information from one mac to another mac by using the time capsule

    If you want to transfer files, settings, etc., you must open Migration Assistant (Applications > Utilities) in the Mac that you want to transfer the files and follow the instructions

  • How can I transfer work from one computer to another?

    How can I transfer work from one computer to another?

    Welcome to the forum.
    I can think of three basic ways to accomplish what you wish to do:
    Use the Project Archiver to archive your Project (and check the box to gather the media files), to an external HDD. Probably the easiest way to do it.
    Copy the Project and ALL media files to an external HDD, but be prepared to relink the media files to the Project, as the drive letter (part of the Absolute Path) will have changed.
    Edit loosely, and Share to an AV file, which will be Imported into a New Project on that second computer. Or, edit VERY tightly, and do the same. I like the first, as removing, replacing Transitions, etc., can be much more difficult, unless that "tight edit" is 100% done.
    Good luck,
    Hunt
    Message was edited by: Bill Hunt to correct formatting

  • How can I transfer information from one ipad to another?

    how can I transfer information from one ipad to another ?

    What kind of information? You can sync things like Contacts and Calendars by using iCloud. You can backup one iPad to iTunes on a computer and then sync the backup to the other iPad. You can configure your iTunes content and sync the same content to both iPads.
    It is based on what you want to do. Or are you looking for a way to send files from one iPad to another wirelessly? There are apps to do things like that, as well as cloud services, such as DropBox.

  • How can i copy apps from one computer to another?

    how can i copy apps from one computer to another?

    You don't mention which operating system you have so it's difficult to provide an answer since the mac and Windows stores the files differently.
    The other thing you can do is just re-download the apps from the iTunes Store. Just login to the iTunes Store on the other computer using the same Apple ID. On the right-hand side of the iTunes Store page you will see a 'Purchased' link. Clicking on that will take you to a page that will list your past purchases which you can re-download to the new computer.

  • About photoshop organizer: how can I shift pictures from one catalogue to another one?

    how can I shift pictures from one catalogue to another one?

    Sync to computer then from there to other device.  Photo stream can be used to sync between devices, but that has to be set up BEFORE the photos are taken.
    Read this...  import photos to your computer...
    http://support.apple.com/kb/HT4083

  • HT1495 How can transfer a application from one iphone to another iphone?

    How can transfer a application from one iphone to another iphone?

    Follow the instructions here or here; using the first set of instructions then requires syncing the second device with the iTunes library containing it.
    (89299)

  • How can I migrate everything from one account to another on same computer?

    How can I migrate everything from one account to another on same computer?

    Transferring files from one User Account to another

  • How can I send stuff from one iPhone to another via Bluetooth?

    How can I send stuff from one iPhone to another via Bluetooth?

    There are some apps that will let you send photos from one iOS device to another over BT.

  • How can you transfer data from one ipod to another ?

    How can you transfer data from one ipod to another ipod ?

    The geniusbar told me what to do, I understood but there is still a problem for me >:/ It's not showing up though. Like "device."  Nothing is happening, and I tried as soon as I got home. Then after half an hour, then an hour, then 3 hours. My problem is that it's not showing up! It's stuck in recovery mode! There's still like 25% battery. So I have no idea why.

Maybe you are looking for

  • Image from LR in blown out more in Bridge Camera Raw

    Hello, thanks for reading... I was just about to post this question, when I think I stumbled upon the answer, but I am not sure... so I decided to post anyway, for input. After completing adjustments to my .cr2 (Canon 30D) images in LR 2.2, I decided

  • Linked adobe file will not open in Word 2007

    I open a word document (.docm) from a share point site and inside it is a linked adobe file. When I try to launch it, it gives me an error that the file cannot be found, server location not available, etc.. However, if I open Adobe Reader first, then

  • Starting server 8.1 -- How? No error messages.

    Installed WebLogic 8.1 on a Linux RHAS 4u4 machine (Linux xxx.xxx 2.6.9-42.ELsmp #1 SMP Wed Jul 12 23:27:17 EDT 2006 i686 i686 i386 GNU/Linux) Workshop comes up okay but when I click "Start Weblogic Server", the fuel gauge comes up and it grinds for

  • How to handle Two independent unit of measure in IS Retail

    Hi The requirement is, for few articles need to maintain Inventory in two different independent unit of measure i.e. in Each (EA) as well in Kilogram(KG). It is understood from the SAP documents that the above scenario can be handled through u201CCat

  • How to access GPS from Nokia 5130 Xprssmusic?

    I have Downloaded one GPS app for my Nokia 5130 xpresmusic. But when i run the app; at staring, app shows one message that is, "No selected GPS receiver" and when I go to connect to GPS receiver manually, app automatically starts Bluetooth and again