with thisform.ADOControl > .CommandType = 1 > .ConnectionString = ; > [Provider=MSDASQL.1;Persist Security Info=False;]+; > [Extended Properties="]+; > [DSN=Visual FoxPro Database;UID=;]+; > [SourceDB=c:\mypath\mydatabase.dbc;SourceType=DBC;]+; > [Exclusive=No;BackgroundFetch=Yes;Collate=Machine;Null=Yes;Deleted=Yes;"] > .RecordSource = "select * from mytable where room_no = 1 group by singer_no" >endwithThis sample is OLE DB to VFP. VFP SQL is not a one-to-one implementation of ANSI SQL, with SQL server this might not work. I don't have it installed to test. Craig, Mark, JVP and many others could help you better than I. Please repost your question.