Tags:
create new tag
view all tags
When doing a formatted search across multiple webs, the search results are currently grouped by web. If you do a search in Weba, Webb and Webc, then the hits for Weba appear, followed by the hits for Webb, followed by the hits for Webc.

As well, the header is output at the beginning of each group of hits.

Is there any plan to offer a 'unified' way of searching across multiple webs, in which the header is only output once, and the hits are not grouped by web? When used with the TablePlugin this would allow for sorting by columns without regard to what web the topic comes from.

I'd be willing to try implementing this feature if we can agree on how to specify such a search.

Or if there is already a way to do this, would someone please let me know?

-- FrankSmith - 27 Nov 2002

I am interested in this as well. I wanted to take care of it by modifying my lib/TWiki/Search.pm (in the searchWeb function), but it seems that it would require almost a complete re-write of that function, which is around 600 lines long. Any thoughts on a better method than this?

-- DavidSachitano - 11 Jun 2003

No change in code is needed. Do this:

  • Do not specify a header in the formatted search, but put the header above the search
  • Use the TablePlugin to do an initial sort on a column of choice

See example in WebChangesForAllWebs

-- PeterThoeny - 28 Oct 2003

Whilst I appreciate the ingenuity of the Table Plugin solution, I think we need a solution that merges results from multiple webs. Without it, combination of output from webs cannot be used as input to other scenarios.

I think a refactor and modularisation of SearchDotPm would be a good idea anyway - 600 lines for a single sub should be advised against in the CodingGuidelines

-- MartinCleaver - 28 Oct 2003

Yes, Search.pm needs an overhaul, it is probably the ugliest piece of code in TWiki.

-- PeterThoeny - 29 Oct 2003

First step of making the Search.pm implementation cleaner is done. Still ways to go.

-- PeterThoeny - 01 Nov 2003

Edit | Attach | Watch | Print version | History: r7 < r6 < r5 < r4 < r3 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r7 - 2003-11-01 - PeterThoeny
 
  • Learn about TWiki  
  • Download TWiki
This site is powered by the TWiki collaboration platform Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2026 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.