In the VFP7 foundation class in the Data Query Folder there is a class called Filter Dialog. It allows for the selection of any table within a DBC. Then you can build SQL [WHERE.......] clauses. I use it right out of the box in my VFP application. I also use it in a form to build OLE DB recordsets to populate a grid and textboxes on the form. However for that I had to subclass the Filter Dialog to include the [Like] condition for MsSQL.