Yes, there is a ORDER clause ... which was in my original code (that code no longer exists).
The files are opened outside of the form.
Note that the relations actually work for each grid IF I click on that grid, but doing so causes the other grid's relations to fail.
>>This is sort of a continuation of an earlier thread. In that earlier thread, I learned an alternative solution to that problem. My question here is: Why does what I had done not work??
>>
>>I have two grids that appear on the same form that have the same table as their recordsource. Each of them uses SET RELATION to get a description field from another table.
>>
>>I decided to open up the table used as my RecordSource using AGAIN with another ALIAS for each grid, and the other table as well:
>>
>>For my first grid:
>>
USE MyTable AGAIN in 0 ALIAS MyTable1
>>USE MyJobs AGAIN in 0 ALIAS MyJobs1
>>SET RELATION to Jobidnum IN MyTable1 INTO MyJobs1
>> ...
>
>Shouldn't the INTO table, in this case the alias MyJobs1, include an ORDER clause, to specify an index? Otherwise, the relation will use recno() to find a match - and that is rarely what you need.
>
>Also, I didn't see a mention of where you open the tables - Form.Load() seems the correct place.
Jim Nelson
Newbury Park, CA