Solved

Getting a Percent from a returned row of data

Posted on 2008-06-17
1
577 Views
Last Modified: 2008-06-17
I need to get a percentage of a number I am returning from a query, such as
My current returned columns are:

Year     count(acct type > 1)       % of acct type count with something > 1000
2000         122                                        10%
2001            85                                        32%


I can get the year and count of acct type, but I'm not sure how to get the % of that for the next column.
I'm guessing I need a variable for the count(acct Type > 1).

Any help is appreciated.

Thanks
0
Comment
Question by:David2112
1 Comment
 

Accepted Solution

by:
David2112 earned 0 total points
ID: 21806945
Ok,

Here's what I did.
Thankfully, I had to put this into an Excel spreadsheet, so
I just got the percentages from an additional query and did a COUNTIF to get the percentage based on the month.

0

Featured Post

Resolve Critical IT Incidents Fast

If your data, services or processes become compromised, your organization can suffer damage in just minutes and how fast you communicate during a major IT incident is everything. Learn how to immediately identify incidents & best practices to resolve them quickly and effectively.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
SQL Query 26 68
Syntax Issue with SSIS module 26 101
Stored Proc - Rewrite 42 56
SQL Recursion schedule 13 14
Confronted with some SQL you don't know can be a daunting task. It can be even more daunting if that SQL carries some of the old secret codes used in the Ye Olde query syntax, such as: (+)     as used in Oracle;     *=     =*    as used in Sybase …
This article describes how to use the timestamp of existing data in a database to allow Tableau to calculate the prior work day instead of relying on case statements or if statements to calculate the days of the week.
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question