Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
sql-user
Starting Member
3 Posts |
Posted - 2004-09-23 : 09:26:11
|
Hello and thanks in advance:I need to find out the percentage of the number of the units fixed within a certain timeframe. I'll explain by example: from excel I filter it this way:The table field called "TAT " is less than or equals to the number "7".Field: Percent Fixed: Count([TAG_ID])Criteria: "where TAT<=7"That's the total then I have to find out by location (we have 2 location).I have tried a few things but the syntax looks wrong all the time... Can anybody help?Thanks/regards==================================================Computer Vancouver - Shops, Professionals, Training and free resources.http://www.vancouverfinder.org/computers/computer-vancouver.html |
|
RickD
Slow But Sure Yak Herding Master
3608 Posts |
Posted - 2004-09-30 : 09:07:52
|
Could you possibly give more information?At a guess, i'd say group by location.. |
 |
|
jsmith8858
Dr. Cross Join
7423 Posts |
Posted - 2004-09-30 : 09:15:24
|
i have no idea what you are asking, but you might want something like:select sum(iif(TaT < 7,1,0)) as TatCount, count([TAG_ID]) as TotalCount, TatCount / TotalCount as Pctfrom YourTable - Jeff |
 |
|
|
|
|