Calculate Percentage from the result of row result

Expert
I want to calculate percentage from row result
For Ex
Vendor
ID  Record Percentage
1001                                1002                   1003                                sum
A   10   10%                     B   20   20%        C   70     70%                  100         100% 
X    50   25%                    Y   125  62.5%      Z   25     12.5%               200          100%
I want to get percentage such as A percentage 10/(102070), , X percentage 50/(5012525)
not A 10/(10207050125+25) = 3.33%
Please help me to get the percentage which client want to
thanks

Dear Lemine.
Try using this..
Percentage Share of Result (%CT)
%CT<Operand>
Specifies how high the percentage share is in relation to the result. The result
means the result of aggregation at the next level (interim result).
%CT Incoming Orders specifies the share of incoming order values of each
individual characteristic value (for example of each customer) in relation to
the characteristic's result (for example, customer of a division).
Percentage Share of Overall Result (%GT)
%GT <Operand>
Specifies how high the percentage share is in relation to the overall result.
The overall result means the result of aggregation at the next level in the list.
In the calculation of the overall result, the dynamic filters (filters that were
not already defined in the Query Designer) are included.
Hope this helps u..
Best Regards,
VVenkat,,

Similar Messages

  • Count the number of rows resulting from a select statement

    Hi,
    Is there any way of counting the number of rows resulting from a select statement. i.e I have a select distinct statement and I then want to perform an IF statement on the number of rows resulting from the select statement.
    Any help appreciated
    Thanks
    Gary

    Declare
    var1 number;
    Begin
    select count(distinct column_name) into
    var1 from table_name;
    If var1 > x Then
    End IF;
    End;
    Hope I understood the problem correctly
    null

  • Exclude accounts from the SharePoint online search results

    We have an issue whereby I want to exlude all unlicensed Office365 accounts from the people search on SharePoint online. We have a lot of shared mailboxes etc which are showing up in the people results and we want to only display active "real"
    accounts
    Any suggestions?

    Hi, Greetings. Hope this helps you.
    pls check the link
     http://ryansteeno.wordpress.com/2012/02/01/exclude-unwanted-users-from-people-search/
    Please remember to click 'Mark as Answer' on the answer if it helps you

  • How can I find out what is on my macbook and not on my other macs that results in continual downloads from the satelite dish and resulting overcharges?

    How can I find out what is on my macbook  that results in continual usage and usage charges from the satelite dish when turned on, even in the middle of the night- which doesn't happen with my other macs?

    I have BusyCal installed, but no alarms that I could find.
    However, I do think I've found the source of the sound: the Firefox add-on "LiveJournal." It routinely checks my LJ and plays a "ding.wav" file whenever there are new posts to my Friends' page. I noticed that the sound started happening more frequently, but after I closed Firefox, it stopped. But since Firefox didn't have any sound/notification settings on its own, I thought to check the extensions, and voila!
    I'm pretty sure the problem is solved, but who knows if the sound will mysteriously return...
    I

  • Urgent ---calculate version  from the current week number

    hi,
         i have an requrenment to modify the charasteric routines
      i have xxx table with parameter i have to read this paramater n  if this parameter contains value 'D' then calculate version(eg:- A00,A01 ...) from the current week number.
    pls advice me which FM i have to call or provide me with some sample codeing.
    points wil be rewarded
    ravi

    There is a FM "WEEKNR_GET".
    This will give you the week no. You need to read the param value from the table that you mentioned and call this FM and updat the version.
    You will need a ABAP person to do this.
    Ravi Thothadri

  • C# : Get Column name for an Insert Query from The Selected GridView Row.

    Hi Guys, I am trying to insert data in an SQL table by executing an Insert Query. 
    The problem is that I need to get the column name from a cell in the selected gridview Row.
    Here's the snippet:
    SqlCommand cmd30 = new SqlCommand("insert into mytable ( '"+GridView7.SelectedRow.Cells[0].Text+"' , r_id) values ('"+ GridView7.SelectedRow.Cells[1].Text +"', '"+TextBox1.Text+"')",con30);
            cmd30.ExecuteNonQuery();
    **r_id is not a Primary Key.
    The Error is get is:
    Incorrect syntax near 'r_id'.
    Any Help will be appreciated.
    Thanks,
    Shaleen
    TheHexLord

    Hi TheShaleen,
    Like your title mentioned.GridView control is a web class.This forum is to discuss problems of C# development.  Your question is not related to the topic of this forum.
    You'll need to post it in the dedicated ASP.Net Forum  for more efficient responses, where you can contact ASP.NET experts. Thanks for understanding.
    Best regards,
    Kristin
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Attempted HotSync results in message: VFSDB Cache.c, Line:4051, unattached record. I did a hard reset and backup from the card. Same result on Hot Sync.

    null
    Post relates to: Tungsten E2

    Major Update: The G-Keys can now be edited without recompiling by editing shell scripts at "/usr/share/g15daemon/macros/"
    Each button has it's own script file named by it's label (e.g. to edit the functionality of G1, open the script named G1.) The button will try to execute the scripts as programs, so make sure they are executable (chmod +x) and as long as the name remains the same, if you want to replace the files with something different, know that the arguments currently given to the files ($1 and $2) are ($1)on/off and ($2)0-2  (where 0 is M1 and 2 is M3)
    To download the updated sources, go here (only the g15daemon source/patch was updated). This thread's OP has been updated.
    Last edited by rabcor (2015-02-12 04:46:48)

  • SSRS Expression to calculate percentage with the denominator being the first value in the same column group in a matrix report

    Hello, Expert,
    Could you please help me with the following problem? Thanks in advance!
    I have designed the matrix report (SSRS 2012) with database table structure looks like below.    
    Week           
    Version
         Count
    Week1
    V1.1
    4000
    Week1
    V1.2
    4000
    Week1
    V1.3
    4000
    Week2
    V1.1
    3000
    Week2
    V1.2
    3000
    Week2
    V1.3
    3000
    Week3
    V1.1
    2000
    Week3
    V1.2
    2000
    Week3
    V1.3
    2000
    Week4
    V1.1
    1000
    Week4
    V1.2
    1000
    Week4
    V1.3
    1000
    The matrix report displays like below. Column grows based on no of Week in the table.   
    Week1
    Week2
    Week3
    Week4
    V1.1
    4000
    3000
    2000
    1000
    V1.2
    4000
    3000
    2000
    1000
    V1.3
    4000
    3000
    2000
    1000
    What I want to do now is: instead of the Count values, I need to calculate the percentage of each week over the
    Count in Week1 so that each cell displays Count(Week2)/Count(Week1), Count(Week3)/Count(Week1), etc. What is the SSRS expression for that? I’m new to SSRS, Please help!

    Heidi,
    Thank you so much for your reply and solution! Now I know how to get the first field in a group. But I can't apply your solution directly just yet because in order to explain my problem I simplified my data structure. My real data structure has a nested
    group like this:
    Week  VersionMajor VersionMinor Count
    Week1  V1           V1.1         2000
    Week2  V1           V1.1         1500
    Week3  V1           V1.1         800
    Week1  V1           V1.2         1000
    Week2  V1           V1.2         500
    Week3  V1           V1.2         200
    Week1  V1           V1.1         2000
    Week2  V1           V1.1         1500
    Week3  V1           V1.1         800
    Week1  V1           V1.2         1000
    Week2  V1           V1.2         500
    Week3  V1           V1.2         200
    Here is the query for the above data:
    SELECT 'Week1' AS Week, 'V1' AS VersionMajor, 'V1.1' AS VersionMinor, 2000 AS Count
    UNION ALL
    SELECT 'Week2' AS Week, 'V1' AS VersionMajor, 'V1.1' AS VersionMinor, 1500 AS Count
    UNION ALL
    SELECT 'Week3' AS Week, 'V1' AS VersionMajor, 'V1.1' AS VersionMinor, 800 AS Count
    UNION ALL
    SELECT 'Week1' AS Week, 'V1' AS VersionMajor, 'V1.2' AS VersionMinor, 1000 AS Count
    UNION ALL
    SELECT 'Week2' AS Week, 'V1' AS VersionMajor, 'V1.2' AS VersionMinor, 500 AS Count
    UNION ALL
    SELECT 'Week3' AS Week, 'V1' AS VersionMajor, 'V1.2' AS VersionMinor, 200 AS Count
    UNION ALL
    SELECT 'Week1' AS Week, 'V1' AS VersionMajor, 'V1.1' AS VersionMinor, 2000 AS Count
    UNION ALL
    SELECT 'Week2' AS Week, 'V1' AS VersionMajor, 'V1.1' AS VersionMinor, 1500 AS Count
    UNION ALL
    SELECT 'Week3' AS Week, 'V1' AS VersionMajor, 'V1.1' AS VersionMinor, 800 AS Count
    UNION ALL
    SELECT 'Week1' AS Week, 'V1' AS VersionMajor, 'V1.2' AS VersionMinor, 1000 AS Count
    UNION ALL
    SELECT 'Week2' AS Week, 'V1' AS VersionMajor, 'V1.2' AS VersionMinor, 500 AS Count
    UNION ALL
    SELECT 'Week3' AS Week, 'V1' AS VersionMajor, 'V1.2' AS VersionMinor, 200 AS Count
    And my matrix table looks like this:
    What I need to do is to calculate the percentage of each week over week1 for
    1) V1 Total
    2) V1.1
    3) V1.2
    I can't use your solution directly because I need to apply Sum function for each cell and the Sum function gives me error when I try to use it on the denominator
    First(Fields!Count.Value,"VersionMinor"). If you could help me further to get to the final solution, I'd really appreciate it!!
    Happy New Year!

  • How do I crop a percentage from the edges of an image?

    I'm using a batch crop and straighten script to separate scanned photos, but there is always a little bit where the crop hasn't been performed perfectly. I'd like to find a way to crop 1-2% off all edges of my document/image. I'm not worried about loosing image integrity. Would be nice to have a script to add to my existing script. Essentially this step will make my edges crisp and eliminate any slivers of white space or bent corners.
    Here is the script that I'm using to divide my scanned photos:
    #target Photoshop 
    app.bringToFront; 
    var inFolder = Folder.selectDialog("Please select folder to process");  
    if(inFolder != null){ 
    var fileList = inFolder.getFiles(/\.(jpg|tif|psd|)$/i); 
    var outfolder = new Folder(decodeURI(inFolder) + "/Edited"); 
    if (outfolder.exists == false) outfolder.create(); 
    for(var a = 0 ;a < fileList.length; a++){ 
      if(fileList[a] instanceof File){ 
        var doc= open(fileList[a]); 
        doc.flatten(); 
        var docname = fileList[a].name.slice(0,-4); 
        CropStraighten(); 
        doc.close(SaveOptions.DONOTSAVECHANGES);  
        var count = 1; 
        while(app.documents.length){ 
          var saveFile = new File(decodeURI(outfolder) + "/" + docname +"#"+ zeroPad(count,3) + ".jpg"); 
          SaveJPEG(saveFile, 12); 
          activeDocument.close(SaveOptions.DONOTSAVECHANGES) ;  
          count++; 
    function CropStraighten() { 
    executeAction( stringIDToTypeID('CropPhotosAuto0001'), undefined, DialogModes.NO ); 
    function SaveJPEG(saveFile, jpegQuality){ 
    jpgSaveOptions = new JPEGSaveOptions(); 
    jpgSaveOptions.embedColorProfile = true; 
    jpgSaveOptions.formatOptions = FormatOptions.STANDARDBASELINE; 
    jpgSaveOptions.matte = MatteType.NONE; 
    jpgSaveOptions.quality = jpegQuality;  
    activeDocument.saveAs(saveFile, jpgSaveOptions, true,Extension.LOWERCASE); 
    function zeroPad(n, s) {  
    n = n.toString();  
    while (n.length < s) n = '0' + n;  
    return n;  
    Message was edited by: Jeremy Klein

    Hmm...not sure what is going on. It seems to do something if the percentage is higher than .1, but nothing below that. It is doing some strange things, treating some images, but disregarding others.
    Thanks for all your help. I can close this thread. I don't want to take up any more of your time and I can always use an automated script to do the process, it just takes longer.
    Here's is my last version of the code:
    #target Photoshop
    app.bringToFront;
    var inFolder = Folder.selectDialog("Please select folder to process"); 
    if(inFolder != null){
      var fileList = inFolder.getFiles(/\.(jpg|tif|psd|)$/i);
      var outfolder = new Folder(decodeURI(inFolder) + "/Edited");
      if (outfolder.exists == false) outfolder.create();
      for(var a = 0 ;a < fileList.length; a++){
        if(fileList[a] instanceof File){
          var doc= open(fileList[a]);
          doc.flatten();
          var docname = fileList[a].name.slice(0,-4);
          CropStraighten();
          doc.close(SaveOptions.DONOTSAVECHANGES); 
          var count = 1;
          while(app.documents.length){
            cropPercentage(0.02);
            var saveFile = new File(decodeURI(outfolder) + "/" + docname +"#"+ zeroPad(count,3) + ".jpg");
            SaveJPEG(saveFile, 12);
            activeDocument.close(SaveOptions.DONOTSAVECHANGES) ; 
            count++;
    function CropStraighten() {
      executeAction( stringIDToTypeID('CropPhotosAuto0001'), undefined, DialogModes.NO );
    function cropPercentage(ratio) {
      if (app.documents.length > 0 && ratio < 0.5) {
        var doc = app.activeDocument
        var crop_w = Math.floor(doc.width*ratio + 0.5)
        var crop_h = Math.floor(doc.height*ratio + 0.5)
        doc.crop(new Array(crop_w, crop_h, doc.width-crop_w, doc.height-crop_h))
    function SaveJPEG(saveFile, jpegQuality){
      jpgSaveOptions = new JPEGSaveOptions();
      jpgSaveOptions.embedColorProfile = true;
      jpgSaveOptions.formatOptions = FormatOptions.STANDARDBASELINE;
      jpgSaveOptions.matte = MatteType.NONE;
      jpgSaveOptions.quality = jpegQuality; 
      activeDocument.saveAs(saveFile, jpgSaveOptions, true,Extension.LOWERCASE);
    function zeroPad(n, s){ 
      n = n.toString(); 
      while (n.length < s) n = '0' + n; 
      return n; 

  • How to calculate value from perticular column and row in pivot table

    Hi all,
    I am having following pivot table.
    Country
    A
    B
    C
    D
    F
    G
    H
    J
    K
    L
    M
    Grand Total
    Canada
    1
    1
    3
    3
    12
    14
    13
    97
    China
    8
    4
    3
    19
    India
    2
    47
    448
    176
    395
    3656
    1964
    1360
    8077
    USA
    1545
    352
    380
    26
    10
    4
    8
    32
    2054
    1023
    758
    4624
    UK
    12
    19
    13
    23
    33
    298
    Grand Total
    1545
    352
    381
    29
    72
    474
    184
    427
    5743
    3028
    2167
    13114
    Now I want sum of Columns A, B, C, K, M where Country = India in one field.
    and sum of D, F, g in another field. and sum of remainig columns in another field.
    How can i get sum of values with some where condition in pivot table.
    Thanks,

    Hi Michael,
    Following is the representation which i want
    CouRntry
    ROW LABLES
    A
    B
    C
    Total of
    ABC
    F
    G
    Total
    Of FG
    J
    K
    L
    TOTAL
    of JL
    Grand
    Total
    Canada
    1
    1
    3
    3
    12
    14
    13
    97
    China
    8
    4
    3
    19
    India
    2
    47
    448
    176
    395
    3656
    1964
    1360
    8077
    USA
    1545
    352
    380
    26
    10
    4
    8
    32
    2054
    1023
    758
    4624
    UK
    12
    19
    13
    23
    33
    298
    Grand Total
    1545
    352
    381
    29
    72
    474
    184
    427
    5743
    3028
    2167
    1
    Also if i get sum how can i add a column in between of the fields.
    Thanks

  • Updated and factory reset macbookpro, how to recover lost videos from the application "front row"

    Desperately need an answer, every response is appreciated.

    What do you mean you factory reset it?
    If you erased & reinstalled the OS then I'm afraid to tell you that those items are gone.
    A data recovery company may be able to recover files but it could be difficult or impossible depending on the disk type & how it was setup.
    You need to avoid writing any new data to a disk that will be recovered from to stand the best chance of finding deleted files. Power off the Mac & leave it off until you have decided on a course of action.
    Don't you have any backups at all?

  • How to use script to get the first table row on each page?

    I create a print form to display a table. I set a conditional page break on this table, so the table rows on each page could be different.
    For example, there're total 50 rows in this table. On the 1st page, there're 5 rows, but on the 2nd page, there're only 2 rows, and so on...
    Now I want to get some value from the 1st table row on each page. How can do that? I can refer to a table row using TableRow[n], but I don't know how to calculate 'n' in script (either FormCalc or JavaScript) for the 1st row on each page.
    Any ideas?

    Hi Wei,
    There is an option of setting the overflow header in the pallette. You may check that out. It is basically used to have the table header to be seen in all pages, if the table is overflowing to multiple pages. You may put your first row as the overflow header.
    - hope this helps, Kindly update,
    thanks and regards,
    - anto.

  • Strange arrow showing on sub-folders after moving from the main one

    I put all my desktop located files into ONE folder.
    Then I needed quicker access to some of the folders so I moved them back to my desktop.
    Now they all have a little arrow in the bottom left corner.
    Why is this?
    Is it important?
    When I put them into the one main folder they retain the little arrow which is different to the triangle that allows access to the folder contents in list view though seems to have the same function once in the main folder. They don't have that triangle any more.
    it is a curly arrow rather than a little triangle.
    If there was a way to upload screen shots I am sure you would understand properly what I am trying to say.
    At first this used to be on just one sub folder now it is on many of them.
    Thanks for any insight on this
    Shirley

    Shirley Drabble1 wrote:
    I put all my desktop located files into ONE folder.
    Then I needed quicker access to some of the folders so I moved them back to my desktop.
    Now they all have a little arrow in the bottom left corner.
    Anything with a curly arrow in the lower-left corner of its icon is an "alias" that points to the original. If you do Finder File -> Get Info you can see that the "Kind" of such an item is "Alias".
    You can create an alias in the Finder by holding down the command and option keys when you drag a file, by using the menu option File -> Make Alias, or by choosing "Make Alias" from the "contextual menu" that results when you click on an item while holding down the control key.

  • Filter by selecting keywords from the keyword panel, AND-rule

    Hello,
    I'd like to have an option to use the AND-rule when selecting multiple keywords from the keyword panel.
    For example, if I had the following keyword hierarchy:
    - Places
    - London
    - New York
    - Subjects
    - Car
    - Buildings
    Now, if I'd like to see cars photographed in New York, I need to go to the find panel and enter the keywords there. If I select multiple keywords from the keyword pane (ctrl-click keywrods "New York" and "Car"), I get all photos from New York and all photos of cars. What I'd like to have is a switch (check box) in the preferences-dialog (*) to chance this behavior to use the AND rule, so that selecting multiple keywords from the keyword panel would result into showing only those photos that have ALL of the keywords, instead ANY of them as it is now.
    (*): or perhaps even in the keyword panel as a sort of small icon, like the "add keyword" (plus sign) and "remove keyword" (minus sign) icons.

    I would love to see a better solution for keyword matching too. Imagine if we could have the power of regular expressions!
    At least we could use parenthesis (for grouping), ampersands (&) for "and", and plus (+) for "or." Wildcards would be nice too, and while we're at it, exclamation mark (!) for "not." Consider the following construct.
    ((dave & aileen) + (bonnie & steve)) & !pete
    Reads like this:
    Both dave and aileen, or both bonnie and steve, but in either case, not pete.
    Or you could change it like this:
    ((dave + aileen) & ! pete) + (shannon & dane)
    Reads like this: Either dave or aileen but not pete, or shannon and dane.
    For even greater power, allow us to store and edit frequent search terms. Then I could easily come up with some elaborate search term, and re-use it later, or change it in some small way for later.
    It would be even better if all this were part of a total metadata search. How about:
    (keyword:dave + keyword:aileen) & (year:2008 & location:US|California|Los Angeles|Home)
    Maybe this is getting to be too complex for casual use, but it really could be quite powerful for searching those catalogs of 10000+ pictures.

  • Af:commandButton only works for the first 10 rows returned in the af:table

    Using JDeveloper 10.1.3.2.0.
    I am new to ADF programming. I have attempted to create an ADF page that contains a search and return table in the same page. The search appears to work fine but the return table displays odd behavior. If the search returns more than 10 rows such that it is possible to page forward through the rows returned the command button associated with the return table that allows the user to pick a particular row and navigate to another page does not work. If the user finds what he/she is looking for in the first ten rows then the command button works fine and the user is taken to the next page. The command button is actually defined to have an af:setActionListener to set a value in a backing bean and then command button has an action to invoke a backing bean. Both of these fire just fine if the selection is made from the first 10 rows. However once the user pages forward to another set of rows then neither seem to happen. Any advice on where to figure out what I did wrong?

    When I get a component that seems to do nothing under certain circumstances, the first thing I usually check for is Javascript errors. Sometimes errors on page load can keep a component's Javascript from firing properly.
    Try reproducing your problem in Firefox (or another browser with a decent Javascript error console; IE doesn't have one, although I think you can get extensions that provide JS debugging). Check the error console:
    # Before scrolling off the first 10 rows.
    # Right after scrolling off the first 10 rows.
    # After unsuccessfully clicking the command button.
    Do any interesting errors show up in steps 2 or 3?

Maybe you are looking for

  • Update to 10.6.8 colour problems with external display

    I have a mid-2010 13" macbook pro. I use a mini DVI to HDMI adaptor to connect to my Philips LCD TV. It has always worked perfectly including audio. Since update to 10.6.8 (yesterday) there is a colour-cast on the external display that makes it unusa

  • Need help sorting an ArrayList of strings by an in common substring

    I'm trying to sort a .csv file, which I read into an ArrayList as strings. I would like to sort by the IP address within the string. Can someone please help me figure out the best way to sort these strings by a common substring each has, which is an

  • How to make business cards in iPage

    Got the template up, but what I type into the upperleft "card" is not replicating on all the others.  Also how do I get it to print on an avery product?  Thanks.

  • Show image when cursor hovers over image

    I would like to have the "i" image used to flip to the information screen be hidden or invisible unless the user hovers over the image, where I want the image to be visible and active after a second or two delay. This will allow a click or touch in t

  • Slow Wi-Fi on MacBook Pro Retina

    About a two weeks i have a slow speed on my laptop: 0,7 - 2 Mbps, but in the same LAN iPhone 4 have ~12 Mbps. My router is ASUS WL-520gc; network details: Mode PHY:802.11g Channel: 1 (2.4 Hz) Security: Personal WPA2 RSSI: -53 Transmission speed: 54 E