![]() | |
#1
| |||
| |||
|
#2
| |||
| |||
|
#3
| |||
| |||
|
|
Fmp 8.5 Adv, windows Just to gather my thoughts, it does work, but any imput apreciated. I have a search field, calculated from various fields in the solution. I wanted to present the user with the option to include/exclude certain fields. So I created a include/exclude value list, created a global field (gInfoYN) where they make their choise. And included an If in the searchfield. If ( gInfoYN = "Include" ; MyTable::Info ; "" ) But now the calculation suddenly has a global inside it, and although the contents of the gfield itself is not present inside the calculation (only used for the IF) the search field can no longer be indexed. Which seriously cripples the search speed. Now I created two variables and a scipt that governs the values in these values. The fields are now buttons that trigger the script. The sript toggels the visible value from yes to no and the contents from the variable as well. Now I put the variable inside the calc and I am able to set the indexing on again. |
#4
| |||
| |||
|
|
Now I created two variables and a scipt that governs the values in these values. The fields are now buttons that trigger the script. The sript toggels the visible value from yes to no and the contents from the variable as well. Now I put the variable inside the calc and I am able to set the indexing on again. You simply can't have a field that is both indexed and changes on the fly accross an entire database at the flick of a switch. There ARE some options though. If the database is gauranteed to be very small, you can have the switch from gInfoYN call a 'replace' on the field with the new value. This will limited by the speed of the replace. Another option is to is to use 3 fields: One with the extra data One without the extra data and one as an unstored calc that displayes the data based on gInfo. You'll have to set it up so that when you perform a find, you do it on the appropriate 'behind the scenes' field which is indexed. Hope that helps, Dave |
![]() |
| Thread Tools | |
| Display Modes | |
| |