Advertisement

11.09.2004 at 04:40AM PST, ID: 21199839
[x]
Attachment Details

Applying filters - .MDB (Queries) vs .ADP (Views) - what is the best approach?

Asked by BlueDelta5 in Microsoft Access Database, Microsoft ADP

Tags: adp, mdb, from

I am converting an Access 2002 .mdb frontend to .adp. The backend .mdb tables have been imported into SQL, linked to the .adp via a system DSN.
The .mdb contained many forms, based on Queries. In these forms I had command buttons which used Applyfilter to display subsets of the query resultant dataset. Some of these Forms are displayed as continuous one-line forms to show a list of records. In the .mdb this was a very quick way to display the subset of records (presumably because the queries were in the local front-end?)

Now along comes .adp so
a) I have to find an alternative to all the Queries. I have tried creating a View using the same criteria as the original query, but for some reason the screen update is now VERY slow. I suspect the conditional formatting I've used to flag certain fields in colour, etc, may be partly to blame, as well as the View now being in the back-end.
b) I am also having trouble using DoCmd.Applyfilter in code - it keep saying it needs either the Filter Name or a valid SQL statement as parameters - I've tried with either, and with both - it still won't have it. It works if I use Applyfilter in a macro (apart from being slow as described above) - but I'm trying to get rid of macros so I'd rather not do that.
c) Tried setting the Form's filter and serverfilter properties - it works if I enter the argument in the Properties dialogue, but not in the code of the command button's OnClick event procedure.

Is there better (faster!) approach than filtering a View dataset? Would a Stored Procedure be a better fit?
Could it be that other code and maybe some forgotten DAO inherited from the access .mdb would be causing the sluggishness? (I wonder particularly about Date and Time functions such as Now() which I probably need to replace with GetDate and GetTime, although I've already  remmed all that out to no avail.)

Any advice / shared experience would be much appreciated.

Start Free Trial
[+][-]11.09.2004 at 06:31AM PST, ID: 12533312

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11.09.2004 at 07:53AM PST, ID: 12534456

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: Microsoft Access Database, Microsoft ADP
Tags: adp, mdb, from
Sign Up Now!
Solution Provided By: SidFishes
Participating Experts: 2
Solution Grade: B
 
 
[+][-]01.13.2005 at 05:15AM PST, ID: 13033606

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32