WinBatch® Technical Support Forum

All Things WinBatch => WinBatch => Topic started by: JTaylor on May 04, 2020, 10:34:03 AM

Title: ADO RecordSet Filter
Post by: JTaylor on May 04, 2020, 10:34:03 AM
Is it expected behavior for an  RS.Update to remove records when used with an RS.Filter applied and records pulled from an ATG file?  Can't find anything saying such a thing but that is the behavior I am experiencing.   I believe I have tried enough things to narrow this down to the problem.   If I don't apply a filter everything works fine.   If I apply one my records disappear.

Jim

Title: Re: ADO RecordSet Filter
Post by: td on May 04, 2020, 11:23:30 AM
It is my understanding that setting the recordset filter is supposed to set the recordset cursor to the first record of the subset of records that match the filter. Clearing the filter is supposed to set the cursor back to the beginning of the recordset. At the risk of asking a simple-minded question, is your filter not finding any matches?
Title: Re: ADO RecordSet Filter
Post by: JTaylor on May 04, 2020, 12:04:12 PM
Yes.   It operates as you say but this triggers a thought.   I wonder if the problem is that I need to clear my Filter before proceeding?   Maybe that is my problem and why I seem to lose stuff.   Even though the loss doesn't always make sense to me.   Off to follow that thought...

Thanks.

Jim
Title: Re: ADO RecordSet Filter
Post by: JTaylor on May 04, 2020, 12:16:00 PM
Thanks again for getting my brain to work.  That was the [OBVIOUS] problem.  I wasn't clearing the Filter after finishing the task.

Jim