473,473 Members | 1,875 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Complex Ranking

3 New Member
Hi guys,

I am Trying to create a ranking query which will rank the the dates on the table if the name and offense matches.

Name * Offense * Date * What I want
Bryan * Absence * 1/12/2011 * 1
Bryan * Absence * 1/13/2011 * 2
Bryan * Tardy * 1/14/2011 * 1
Bryan * Tardy * 1/15/2011 * 2
Vishal * Absence * 1/16/2011 * 1
Vishal * Absence * 1/17/2011 * 2
Vishal * Absence * 1/18/2011 * 3
Vishal * Absence * 1/19/2011 * 4
Vince * Tardy * 1/20/2011 * 1
Vince * Tardy * 1/21/2011 * 2
Vince * Tardy * 1/22/2011 * 3

so if you look at column 4 it shows ranking per name per offense.

Any help regarding this matter will be greatly appreciated.
Jan 26 '11 #1
4 1489
Rabbit
12,516 Recognized Expert Moderator MVP
You do it like a regular ranking query except you add your two new conditions into the subquery's WHERE clause.
Jan 26 '11 #2
Bryan Guirnela
3 New Member
can you be more specific on the syntax? ive been tryin to fiddle around with it but i cant seem to make it right.. :(
Jan 26 '11 #3
Rabbit
12,516 Recognized Expert Moderator MVP
What do you have so far?
Jan 26 '11 #4
Bryan Guirnela
3 New Member
I was able to create one, although it took me a qouple of qeries then i had to connect them all.but it works hehe..Thanks anyway.
Jan 27 '11 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

11
by: Petre Huile | last post by:
I have designed a site for a client, but they have hired an internet marketing person to incrase their search engine ranking and traffic. He wants to put extra-large fonts on every page which will...
5
by: ED | last post by:
I currently have vba code that ranks employees based on their average job time ordered by their region, zone, and job code. I currently have vba code that will cycle through a query and ranks each...
1
by: Joseph Bloch | last post by:
In all the threads on ranking in Access queries, I've not seen anything that deals with ranking against a subset of the query results. What I need to do is take the following query results: Dept...
5
by: valglad | last post by:
Hi, The question below was posted about 4 years ago and noone was able to answer it back then. I have virtually the same type of problem so would appreciate if anyone can help. Thanks ...
6
by: sara | last post by:
I hope someone can help with this. Our director wants to have a report that will have the departments (Retail stores) across the top, stores down the side and the RANKING of the YTD dept sales...
5
by: Chris | last post by:
I was wodering if there was a way to rank numbers in a query like this #'s Rank 100 1 99 2 98 3 98 97 5 96 6 96
0
debasisdas
by: debasisdas | last post by:
Rank:-assigns A Unique Number For Each Row Starting With 1,except For Rows That Have Duplicate Values,in Which Case The Same Ranking Is Assigned And A Gap Appears In The Sequence For Each Duplicate...
1
by: Paulo | last post by:
Hi, I need to create a ranking column wich will be the row number... it is the seller wich most sells... Ranking Seller Sum 1 Paul 2.212,00 2 Robert ...
0
by: xahlee | last post by:
I have updated the computing sites popularity ranking, based on both alexa.com and quantcast.com. The whole report nicely formatted in HTML is here: http://xahlee.org/lang_traf/lang_sites.html ...
0
by: sipacate | last post by:
I've got a ranking query that ranks the performance of teams in challenges. The hierarchy of data is as follows: teams have members members have activities activities have activitytypes...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.