1. The record source is really for a subform and how do you specify a record source for a subform in code?
A Subform isn't open in its own right. You need to get to it via the
mainform, using the Name property of the Subform Control (which may
not be the same as the name of the form within that control!) E.g.
Me!subformname.Form.Recordsource = strSQL
2. It is my understanding that a pass-through query must be constructed using the query design wizard, remove the table and using the Query menu item to select pass-through query and then the query will have a link icon associated with it. How is this "pass-through" feature accomplished when you specify the query in code? My goal is, of course, to have the query (searching a large table for duplicates) execute as fast as possible.
The query design wizard is simply one of many ways to construct a SQL
string. No matter how you build it, a Query (local or passthrough) is
just a SQL string. If the query is stored in the Queries collection
(either using the user interface, or the CreateQueryDef method in
code) it will be in the collection with an icon.