Message
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Stonefield
Title:
SFQuery
Miscellaneous
Thread ID:
01647996
Message ID:
01647996
Views:
66
Hi,

I am using an old version of Stonefield Query (for WHERE clause of SQL Selects). As I am refactoring my application, I came across the following need/issue:
Example: In the current version when user selects to query on a value in a field (usually a unique/ID field), the resulting cFilter expression looks something like this:
cFilter = "upper(PartsFile.Part_ID) = 'XYZ123  '"
The Part_ID is a unique field name of a table. For example, Part ID in the Parts file. Now I want the program to use the PK field of the table. So when user enters in the SFQuery Part_ID 'XYZ123' I want the SFQuery to return the following:
cFilter = 'PartsFile.Part_PK = 3444'
Anybody know how to change in SFQuery (and where to change it) that it selects the PK field and not the Unique Field?

TIA
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Next
Reply
Map
View