This is what I tried:
RPTconn.Open "Provider=Microsoft.Jet.OLEDB.4.0;" & _
"Data Source=" & App.Path & "\XXXXXXXX.mdb"
RPTrs.Open "SELECT JobNum, Client, AE, BalDue, ArtTpDate, FrmsdtdoneNPRTDt, " & _
"BLOSODt, BLADtNPRTDt, OrgDropDate, ActualDropDt, StatDt, Comment " & _
"FROM Master GROUP BY JobNum", RPTconn
I get the following error:
You tried to execute a query that does not include the specified expression 'Client' as part of an aggregate function.
Here is the data in a CSV format:
JobLoc,AE,JobNum,Client,StatDt,DeptCode,ActCDAct,PieceIDTapeDPInfo,
PieceSizeProg,SkedMadeYNR,QtyOrdNameCtProdCt,QtyRecQtyProd,
RecDateProdDate,BalDue,ArtTpDate,BLOSODate,BLADtNPRTDt,FrmsdtdoneNPRTDt,
VendorPressLaserJet,Comment,SR,OrgDropDate,1stSchedDropDt,ActualDropDt,
History,OrgRevdCalendar
U,7AN,22011.01HD,Home Depot - Burbank,12/14/2005,DP,LSso,h-Postcard-cutsht,"4-up 12-1/2 x 18"" 9pt C1S",Y,20074,,,-20074,,12/14,12/14,,Color - Duplex,,7Mlnw,12/21,,,,
U,7AN,22011.01HD,Home Depot - Burbank,12/14/2005,DP,LSso,t-TAPES,12/12 DP,,20074,,,-20074,here 12/12,12/14,12/14,,,,7Mlnw,12/21,,,,
U,7AN,22010.02HD,Home Depot - Monroe,12/13/2005,DO,NPRT,h-Postcard-ekta,,Y,20086,,,-20086,,SOout 12/8,NPRT 12/8,appr'd 12/8,EKTA,changed to ekta 12/9,7Mlnw,12/8,,12/?,,
U,7AN,22010.02HD,Home Depot - Monroe,12/13/2005,DO,NPRT,t-TAPES,11/29 SR,,20086,,,-20086,here 11/29,SOout 12/8,NPRT 12/8,,,,7Mlnw,12/8,,12/?,,
U,7AN,22010.01HD,Home Depot - Bristol,12/13/2005,DO,NPRT,h-Postcard-ekta,,Y,20087,,,-20087,,SOout 12/5,NPRT 12/6,appr'd 12/6,EKTA,changed to ekta 12/9,7Mlnw,12/8,,12/?,,
U,7AN,22010.01HD,Home Depot - Bristol,12/13/2005,DO,NPRT,t-TAPES,11/29 HM,,20087,,,-20087,here 11/29,SOout 12/5,NPRT 12/6,,,,7Mlnw,12/8,,12/?,,
U,7MO,22006.01FM,Fannie Mae,12/13/2005,MS,DRdc,f-Brochure-cutsht Static copy,"2-up 12-1/2 x 18"" 80# satin text",Y,1055,1055,12/12/2005,0,,SOout 12/5,NPRT 12/5,"appr'd 12/5,done 12/12",Color - Duplex, Samples to Jason Jeremiah,7Mlnw,Ship 12/7,,Ship 12/?,,
U,7MO,22006.01FM,Fannie Mae,12/13/2005,MS,DRdc,m-ART 3 Kits,11/23 HM,,1055,,,-1055,art here 11/23,SOout 12/5,NPRT 12/5,,,,7Mlnw,Ship 12/7,,Ship 12/?,,
U,7MO,22005.02CN,Care Net,12/14/2005,MS,DRdc,a-OSE-ekta,,Y,3258,,,-3258,,SOout 12/9,PCut 12/12,done 12/12,EKTA,,7Mlnw,12/15,,,,
U,7MO,22005.02CN,Care Net,12/14/2005,DO,NPRT,h-Christmas Card static copy,"2-up 18"" 9pt C1S",Y,3258,,,-3258,,SOout 12/9,NPRT 12/12,appr'd 12/12,Color - Duplex,,7Mlnw,12/15,,,,
U,7MO,22005.02CN,Care Net,12/14/2005,DO,NPRT,t-TAPES 3 Kits,12/6 HM,,3258,,,-3258,here 12/7,SOout 12/9,NPRT 12/12,,,,7Mlnw,12/15,,,,
U,7MO,22005.01CN,Care Net,12/13/2005,DO,NPRT,h-Christmas Card static copy,"2-up 18"" 9pt C1S",Y,860,,,-860,,SOout 12/7,NPRT 12/12,appr'd 12/12,Color - Duplex,,7Mlnw,12/9,,Ship 12?,,
U,7MO,22005.01CN,Care Net,12/13/2005,DO,NPRT,t-TAPES 2 Kits,12/6 HM,,860,,,-860,here 12/6,SOout 12/7,NPRT 12/12,,,,7Mlnw,12/9,,Ship 12?,,
The output would be:
JobLoc,AE,JobNum,Client,StatDt,DeptCode,ActCDAct,PieceIDTapeDPInfo,
PieceSizeProg,SkedMadeYNR,QtyOrdNameCtProdCt,QtyRecQtyProd,
RecDateProdDate,BalDue,ArtTpDate,BLOSODate,BLADtNPRTDt,
FrmsdtdoneNPRTDt,VendorPressLaserJet,Comment,SR,OrgDropDate,
1stSchedDropDt,ActualDropDt,History,OrgRevdCalendar
U,7AN,22011.01HD,Home Depot - Burbank,12/14/2005,DP,LSso,h-Postcard-cutsht,"4-up 12-1/2 x 18"" 9pt C1S",Y,20074,,,-20074,,12/14,12/14,,Color - Duplex,,7Mlnw,12/21,,,,
U,7AN,22010.02HD,Home Depot - Monroe,12/13/2005,DO,NPRT,h-Postcard-ekta,,Y,20086,,,-20086,,SOout 12/8,NPRT 12/8,appr'd 12/8,EKTA,changed to ekta 12/9,7Mlnw,12/8,,12/?,,
U,7AN,22010.01HD,Home Depot - Bristol,12/13/2005,DO,NPRT,h-Postcard-ekta,,Y,20087,,,-20087,,SOout 12/5,NPRT 12/6,appr'd 12/6,EKTA,changed to ekta 12/9,7Mlnw,12/8,,12/?,,
U,7MO,22006.01FM,Fannie Mae,12/13/2005,MS,DRdc,f-Brochure-cutsht Static copy,"2-up 12-1/2 x 18"" 80# satin text",Y,1055,1055,12/12/2005,0,,SOout 12/5,NPRT 12/5,"appr'd 12/5,done 12/12",Color - Duplex, Samples to Jason Jeremiah,7Mlnw,Ship 12/7,,Ship 12/?,,
U,7MO,22005.02CN,Care Net,12/14/2005,MS,DRdc,a-OSE-ekta,,Y,3258,,,-3258,,SOout 12/9,PCut 12/12,done 12/12,EKTA,,7Mlnw,12/15,,,,
U,7MO,22005.01CN,Care Net,12/13/2005,DO,NPRT,h-Christmas Card static copy,"2-up 18"" 9pt C1S",Y,860,,,-860,,SOout 12/7,NPRT 12/12,appr'd 12/12,Color - Duplex,,7Mlnw,12/9,,Ship 12?,,
Swi