Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Macro Substitution
Message
From
13/02/2003 17:17:58
 
 
To
13/02/2003 17:06:55
Jim Rieck
Quicken Loans/Rock Financial/Title Sourc
Livonia, Michigan, United States
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00752893
Message ID:
00752956
Views:
12
Jim,

I'm wondering if there are some design issues with what you are doing, but the eval() function is helpful for this. Of course, qqfield must be in the form of table1.field1 for this to work.
select * from promolist;
    where qq_promo and BITTEST(region,0);
    and DATE() <= promolist.expire;
    and iif(!empty(qqfield),eval(qqfield),.f.)
>Steve,
>
> Yes that is correct except they are not memory variables, they are fields in another table.
>
>Jim
>
>>Jim,
>>
>>Can you explain further? Are you saying you are storing names of memory variables in that field, and that it name of the variable may be different from record to record.
>>
>>>All,
>>>
>>> I want to use macro substitution in a select statement. I have a field in a table that references variable. With the code that is below I am getting a missing operand message and I not sure why. Please help!
>>>
>>>
>>>select * from promolist;
>>>where qq_promo and BITTEST(region,0);
>>>and DATE() <= promolist.expire;
>>>and IIF(!EMPTY(promolist.qqfield) and &promolist.qqfield ,.T.,.F.)
>>>
Steve Gibson
Previous
Reply
Map
View

Click here to load this message in the networking platform