I hope someone out there can help me.
I have a table that has date, time, cellid, and 25 other numeric data fields (call them f1, f2, etc). There are entries for each cellid, every halfhour, every day.
I need to find the max(f1) and list all the data within that row for each cellid.
Example table
1234, 7/25/2004, 00:00, 134, 3525, 235652, 234, 115...
1234, 7/25/2004, 00:30, 1244, 4546,2342, 35252, 1555...
1235, 7/25/2004, 00:00, 44454, 4444, 6572, 453434, 445...
1235, 7/25/2004, 00:30, 23525, 222, 351, 3525, 3234....
1236, 7/25/2004, 00:00, 45422, 2334, 11564, 12345, 12313....
1236, 7/25/2004, 00:30, 456467, 4564, 1111, 12344, 12345....
Example results
7/25/2004, 1234, 00:30, 1244, 4546, 2342, 35252, 1555...
7/25/2004, 1235, 00:00, 44454, 4444, 6572, 453434, 445...
7/25/2004, 1236, 00:30, 456467, 4564, 1111, 12344, 12345...
There are ~3500 different cellids (it varies) and 48 halfhour entries per day per cellid. Since I don't want the max value across the whole day of all the fields, I can't use max on the other fields, and if I use them in the group by, I get multiple rows of data.
Can anyone help?
I have a table that has date, time, cellid, and 25 other numeric data fields (call them f1, f2, etc). There are entries for each cellid, every halfhour, every day.
I need to find the max(f1) and list all the data within that row for each cellid.
Example table
1234, 7/25/2004, 00:00, 134, 3525, 235652, 234, 115...
1234, 7/25/2004, 00:30, 1244, 4546,2342, 35252, 1555...
1235, 7/25/2004, 00:00, 44454, 4444, 6572, 453434, 445...
1235, 7/25/2004, 00:30, 23525, 222, 351, 3525, 3234....
1236, 7/25/2004, 00:00, 45422, 2334, 11564, 12345, 12313....
1236, 7/25/2004, 00:30, 456467, 4564, 1111, 12344, 12345....
Example results
7/25/2004, 1234, 00:30, 1244, 4546, 2342, 35252, 1555...
7/25/2004, 1235, 00:00, 44454, 4444, 6572, 453434, 445...
7/25/2004, 1236, 00:30, 456467, 4564, 1111, 12344, 12345...
There are ~3500 different cellids (it varies) and 48 halfhour entries per day per cellid. Since I don't want the max value across the whole day of all the fields, I can't use max on the other fields, and if I use them in the group by, I get multiple rows of data.
Can anyone help?