Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Filtering Records
Message
From
30/08/2001 11:25:57
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Filtering Records
Miscellaneous
Thread ID:
00550901
Message ID:
00550901
Views:
51
I am working with a company who has developed a rather large database program to keep track of costs related to construction jobs. Unfortunately the vast majority of the program was developed by an accountant. To make matters worse he developed it in Access97. I am trying to recreate some of the programs functionality using VFP.

Since variables cannot be passed per-se in Access they created functions that store query criteria in a table and then retrieve them from within the query using a function called GetSystemDefaults(). When a user wants to retrieve all records they use a crieteria of "ALL".

My question arrises from the way they allow users to filter records in a query. The program will allow users to run a report using criteria such as specific job numbers or the user can run the report on all jobs.

It is my understanding that the easiest way to do this is to use the "like" operator and a wildcard "*" to specify all data or use a specific key number to narrow the results. The program creator somehow used a combination of grouping on the function that retrieves the query criteria and a cryptic combination of "AND" and "OR" operators to achieve the same results.

Am I simply off-base in my understanding of the filtering process?

Thank you for any enlightenment that could be offered


Kris Hokanson
"Never send an accountant to do a programmers job."
Next
Reply
Map
View

Click here to load this message in the networking platform