Thanks for your help, Terry. Once you confirmed that I was using the correct structure for creating an editable, deletible query, I began digging into the structure of the tables themselves.
I found that I had somehow removed the 'primary key' status from the stationid field, and that was the...
Hi Chris,
I was able to get the code that you posted to work.
I even configured my system to use dd/mm/yyyy.
What dates are you using dates are you using for StartDate and EndDate?
Dennis
Hi,
Just extend the concept a little further. Create a third query that uses phase2 to restrict the records from your table, giving you access to all of the other fields like this:
Final query:
SELECT YourTable.id, YourTable.date, YourTable.ref, YourTable.name, YourTable.fld1...
Yes, one way to accomplish it would be to use two queries like this:
Query name: phase1
SELECT YourTable.id, Max(YourTable.date) AS fldDate
FROM YourTable
GROUP BY YourTable.id ORDER BY YourTable.id, Max (YourTable.date);
This will give you the latest date for each duplicate id. Then...
Have verified that your 'holidays' recordset is populated?
Just before your .findfirst statement, add:
recordsetname.movelast
debug.print recordsetname.recordcount
If you have records in the recordset, verify that the fieldname is what you specify in you criteria string.
If...
Hi Chris,
If you're using a date value in your criteria, use '#' delimiters. ex: #8/11/2001# If you use quote delimiters it will use a string comparison and your data will have to be in precisely the same format as your string critera.
Dennis
Hi,
I am having trouble creating a list of records that I can delete.
I have three tables that are set up (more or less)as follows:
LOCATIONMASTER DETAIL STATIONMASTER
LocationID ---> LocationID
LocationName StationID <-- StationID
Date...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.