Hi Renee,
Did the suggestion that Bob Quintal posted help you out?
Note to Bob: Thanks for following up!
I tried the script you gave in Access and in SQL Analyzer, with no luck.
I'm only running Access 2003, if that helps,
Very strange, because I worked up the example using Access 2003.
Tom Wickerath
Microsoft Access MVP
http://www.accessmvp.com/TWickerath/
__________________________________________
:
Hi Tom,
You were right about Dolls Unity, my maximum date was incorrect, but for the
others I wanted to stay the same, reason being, opid's are not exclusive.
Any Oper could post on any Vendor. I tried the script you gave in Access and
in SQL Analyzer, with no luck.
I'm only running Access 2003, if that helps, but I'd rather just go straight
to Query Analyzer. Anything to help is appreciated!!!
Here's my query, and the results I'm getting. I only want the entire row
with the most date for each WSPVCode...
select WSPVcode,
WSPVname,
ShuserCode,
max(WSDatePosted)as MaxDate
from Faster.WSublet
inner join Faster.SHeader
on SHopId=WSopId
where WSDatePosted<>0
group by WSPVcode,WSPVname,SHUserCode
order by WSPVcode
WSPVCode WSPVName MaxDate SHUserCode
000154 A-1 DRIVE SHAFT 20021119 3010
000154 A-1 DRIVE SHAFT 20040301 3514
000154 A-1 DRIVE SHAFT 20030507 4007
000154 A-1 DRIVE SHAFT 20030104 4008
000154 A-1 DRIVE SHAFT 20051129 4018
000154 A-1 DRIVE SHAFT 20080722 6004
000154 A-1 DRIVE SHAFT 20041117 6012
000154 A-1 DRIVE SHAFT 20040624 STU1
000154 A-1 DRIVE SHAFT 20040205 STU3
000154 A-1 DRIVE SHAFT 20050823 TMP1
011610 ADSCOM CORP. 20040205 STU3
011610 ADSCOM CORP. 20040218 VAL
011725 ADVANCED TANK SYSTEMS,INC 20051116 4018
011725 ADVANCED TANK SYSTEMS,INC 20081014 6004
011725 ADVANCED TANK SYSTEMS,INC 20040707 STU1
011725 ADVANCED TANK SYSTEMS,INC 20031009 VAL
014310 ALBAN TRACTOR CO. INC. 20041202 3015
014310 ALBAN TRACTOR CO. INC. 20050317 3016
014310 ALBAN TRACTOR CO. INC. 20050210 3513
014310 ALBAN TRACTOR CO. INC. 20030306 4008
014310 ALBAN TRACTOR CO. INC. 20050929 4018
014310 ALBAN TRACTOR CO. INC. 20060523 4019
014310 ALBAN TRACTOR CO. INC. 20081209 6004
014310 ALBAN TRACTOR CO. INC. 20031211 STU3
014310 ALBAN TRACTOR CO. INC. 20031015 TMP4
014310 ALBAN TRACTOR CO. INC. 20040520 VAL
019783 ALTEC INC 20040806 3008
019783 ALTEC INC 20090218 6004
019783 ALTEC INC 20060606 AB
019783 ALTEC INC 20040611 STU1
058940 AUTO BARN, INC 20030610 1010
058940 AUTO BARN, INC 20031003 2003
058940 AUTO BARN, INC 20040112 3010
058940 AUTO BARN, INC 20050111 3513
058940 AUTO BARN, INC 20051129 4018
058940 AUTO BARN, INC 20050329 5046
058940 AUTO BARN, INC 20050819 AB
058940 AUTO BARN, INC 20061108 AID1
058940 AUTO BARN, INC 20090326 CL
058940 AUTO BARN, INC 20080219 STU1
058940 AUTO BARN, INC 20061213 STU2
058940 AUTO BARN, INC 20061016 STU3
058940 AUTO BARN, INC 20040309 TMP1
058940 AUTO BARN, INC 20030729 TMP3
058940 AUTO BARN, INC. 20021217 2003
058940 AUTO BARN, INC. 20030216 3004
058940 AUTO BARN, INC. 20030403 3506