Hi,
I have some data in panel format:
id1, 1990, 100
id1, 1991, 101
id1, 1992, 99
id1, 1993, 103
id2, 1990, 80
id2, 1991, 83
id2, 1992, 78
id2, 1993, 90
id3..... etc.
Is there any way I can -- without re-structuring the data -- write a
query that will return the top two records from each panel? Similar to
the max function but taking the top two instead of top one. The
desired output would be:
id1, 1993, 103
id1, 1991, 101
id2, 1993, 90
id2, 1991, 83
id3.... etc.
Thanks in advance for the help,
Alan 0 932 This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: DFS |
last post by:
This UNION query is very slow. With only 3,000 records in the Parent table
and 7,000 records in the Child table, it takes about 60 seconds to run and
returns about 2200 records.
Any ideas on...
|
by: Steve |
last post by:
Form FrmRestock's recordsource is QryFrmRestock. The TransactionDate field's
criteria is set ats:
Forms!FrmRestock!LastXDays. LastXDays on the form is a combobox where the
selections are 30, 60...
|
by: Tom Mitchell |
last post by:
All:
I'm stumped on a query. How do I find duplicates in a table where one
of the duplicates has values is a certain field and the other doesn't.
For example, I have the following table:
...
|
by: Nicolae Fieraru |
last post by:
Hi All,
I have a query, Select Count(BoolField) from tblMyTable, Where BoolField =
true.
If I run the query by itself, it returns the number of true records
I want to use the result of that...
|
by: Martin Lacoste |
last post by:
Ok, before I headbutt the computer... don't know why when I add
criteria in a query, I get an 'invalid procedure call'. I also don't
know why after searching the help in access, the various access...
|
by: NumberCruncher |
last post by:
Hi All,
I am struggling with setting up my first system of tables, forms,and reports, and could use your help!
I am setting up a database to keep track of the production of a produced item. The...
|
by: csolomon |
last post by:
Hello:
I am using two queries to get one result set. The issue is, I return no data when I combine them into one query. I have listed both queries, as well as the 3rd query that shows them...
|
by: Alan.Aylett |
last post by:
Hi,
I have a panel of data organised as follows:
id1, 1990, 100
id1, 1991, 101
id1, 1992, 100
id1, 1993, 103
id2, 1990, 80
id2, 1991, 90
|
by: dizzydangler |
last post by:
Hi all,
I am a new Access user and just starting to get my head around some of the basic concepts, so please take it easy on me :) My company has been managing client records on excel, and I’m in...
|
by: taylorcarr |
last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
|
by: aa123db |
last post by:
Variable and constants
Use var or let for variables and const fror constants.
Var foo ='bar';
Let foo ='bar';const baz ='bar';
Functions
function $name$ ($parameters$) {
}
...
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
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...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
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...
| |