Adding Text search fields

Support, Tips and Mods for Matt Navarre's SearchResults technique.
Posts: 50
Joined: Mon Dec 21, 2009 8:45 am
PostPosted: Mon Dec 21, 2009 9:54 am
I'm trying to add a couple of extra TEXT fields to fmSearchResults. I've followed the instructions:
Added an additional field to the Table01 layout, given it a new object name (Text07) and modified the "Search - Perform Find" script to handle the additional field - yet whenever I perform the search I get no results. The data is there, it just seems that there is a problem somewhere.

Also, I often get one less result than what should be returned. If there are 7 valid records, only 6 get returned. The return value is set to 30.
SeedCode Staff
SeedCode Staff
Posts: 2764
Joined: Thu Nov 20, 2003 11:01 am
PostPosted: Mon Dec 21, 2009 3:40 pm
LOL. Sorry about that. The directions are complete but our screen shot showed adding another instance of the line incrementing the $n variable: that was a mistake. You only want one instance of that line incrementing $n.

Take a look at the new screen shot in the documentation here:

http://www.seedcode.com/pmwiki/pmwiki.p ... MoreFields

Make your script look like that and I believe both of your problems will be addressed. Very sorry for the inconvenience.
John Sindelar
SeedCode
Posts: 50
Joined: Mon Dec 21, 2009 8:45 am
PostPosted: Mon Dec 21, 2009 4:38 pm
Thanks John,

I had figured that was the case. It was the one line of code that seemed out of place.

Still having issues with not all of the results showing up. Figuring it might be something in the Create Line Results script. Off to debug more.
Posts: 50
Joined: Mon Dec 21, 2009 8:45 am
PostPosted: Mon Dec 21, 2009 4:42 pm
I've also noticed that the $$sr Objects variable doesn't always seem to get updated or it gets changed back to the default. I've added an additional field in the TEXT field section, it while debugging it doesn't always seem to add the Text07 entry into the variable.
Posts: 50
Joined: Mon Dec 21, 2009 8:45 am
PostPosted: Mon Dec 21, 2009 4:56 pm
I was having trouble where not all of the results would display in the list. I'm working with a very small recordset (10 records) to test and configure with. In doing a search I should get 6 records back - fmSR was returning 4 and in some instances only 1. While stepping through the scripts I could see that all 6 records were being found, but not added to the results display.

In the Create Line Results script there is a loop about 3/4 of the way down. When I added a "Go To Record/Request/Page [First]" step just AHEAD of the loop command that seemed to fix it.

Still testing.
SeedCode Staff
SeedCode Staff
Posts: 2764
Joined: Thu Nov 20, 2003 11:01 am
PostPosted: Mon Dec 21, 2009 5:00 pm
Yes, if you sort your results you'll need to go to the first record after sorting.

You can find more about this here: http://www.seedcode.com/pmwiki/pmwiki.p ... rOfResults
Last edited by John Sindelar on Mon Dec 21, 2009 5:02 pm, edited 1 time in total.
John Sindelar
SeedCode
Posts: 50
Joined: Mon Dec 21, 2009 8:45 am
PostPosted: Mon Dec 21, 2009 5:02 pm
And I was sorting.

Return to fmSearchResults

Who is online

Users browsing this forum: No registered users and 2 guests

cron
(855) SEEDCODE
[email protected]
Follow us: