[ic] Arbitrary table listings via [page] tag

Richard Eddy interchange-users@icdevgroup.org
Sun Sep 1 21:11:01 2002


>>>>My MySQL database contains an arbitrary table called "ecomposers" 
>>>>containing
>>>>a list of composers with two fields, code and composer.
>>>>
>>>>I can display a list of the entries in the composer field beginning 
>>>>with "B"
>>>>using a loop within a page such as:
>>>>
>>>>[loop search="
>>>>         fi=ecomposers
>>>>         ac=yes
>>>>         bs=yes
>>>>         st=db
>>>>         sf=composer
>>>>         se=B
>>>>         su=yes
>>>>         ra=yes
>>>>         rf=all
>>>>         tf=composer
>>>>         "]
>>>>     [page scan     ... ][loop-data ecomposers composer][/page]<BR>
>>>>[/loop]
>>>>
>>>>However, no matter what code I put within the
>>>>[search-region]...[/search-region] tags on page "test.html" I cannot
>>>>generate a similar list with:
>>>>
>>>>[page scan
>>>>     fi=ecomposers
>>>>     ac=yes
>>>>     bs=yes
>>>>     st=db
>>>>     sf=composer
>>>>     se=B
>>>>     su=yes
>>>>     ra=yes
>>>>     rf=all
>>>>     tf=composer
>>>>     sp=test
>>>>     ]My link
>>>>[/page]
>>>>
>>>>which generates:
>>>>
>>>>../cgi-bin/buywellic2/scan/fi=ecomposers/ac=yes/bs=yes/st=db/sf=composer/se 
>>>>
>>>>=B/su=yes/ra=yes/rf=all/tf=composer/sp=test.html
>>>>
>>>>I have been unable to resolve the following problem despite many hours
>>>>reading the manuals and the forum messages and would appreciate any 
>>>>help you
>>>>can give.
>>>
>>>
>>>Richard, is it safe to presume that you duplicated the code within the 
>>>search-region in your test.html just as you can find in the results.html 
>>>file?  Specifically, do you have the search-list tags as well the error 
>>>processing for no-matches?
>>>
>>>If so, you must be seeing something...
>>Since receiving your reply I have done as you suggested, replacing the 
>>code between the search-list tags of a working results.html file but the 
>>results are the same.
>>
>>With [item-field composer] I get blank lines equal to the number of 
>>matches I would expect instead of composer names.
>
>Put the [dump] tag into the target page and then look at the last search 
>element.  I had a problem where scan was creating loops with invalid 
>names, its a long shot but perhaps you might be seeing the same thing ...
>
>Barry

Thanks for the suggestion Barry, but the dump showed a valid scan line (ie 
the one I quoted in an earlier message).

No code that I place between [search-list] and [/search-list] produces 
anything from the ecomposers table. I don't understand why something should 
work in a [loop search] defined within the page but not as [page scan]. 
There would seem to be no doubt about the ecomposers table being accessible 
from within the MySQL database, otherwise I wouldn't be seeing correct 
results in the [loop-search] output.

May I ask what code you would place between the [search-list] and 
[/search-list] tags based on the [page scan] spec above?

Richard.