Bug 64111 - generated index error with multiple seealso entries
generated index error with multiple seealso entries
Product: Red Hat Linux
Classification: Retired
Component: docbook-style-dsssl (Show other bugs)
All Linux
medium Severity medium
: ---
: ---
Assigned To: Tim Waugh
Depends On:
  Show dependency treegraph
Reported: 2002-04-25 16:13 EDT by Tammy Fox
Modified: 2008-05-01 11:38 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2002-05-03 13:48:38 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
Example SGML file with 2 seealso index terms (22.08 KB, text/plain)
2002-05-01 10:51 EDT, Tammy Fox
no flags Details
Can you test this patch out to see if it does the right thing for you and doesn't break anything else? (1.03 KB, patch)
2002-05-02 04:36 EDT, Tim Waugh
no flags Details | Diff
example with multi secondary indexterms (22.61 KB, text/plain)
2002-05-02 15:05 EDT, Tammy Fox
no flags Details

  None (edit)
Description Tammy Fox 2002-04-25 16:13:49 EDT
If you use /usr/bin/collateindex.pl to generate an index from indexterms,
it adds an extra comma to the generated index file, causing it not
to parse correctly.

For example, if you have the following indexterm definitions:

	  <primary>file system</primary>

	  <primary>file system</primary>

It generates an HTML index that looks like this:
file system
    ext3, Formating ext3 File Systems with mkfs
        See also mkfs
        Assigning a Label with e2label
        See also e2label
Comment 1 Tim Waugh 2002-04-25 17:03:43 EDT
I can't figure out how to use collateindex.pl.  Can you give me a step-by-step 
list of what to do, along with a complete (but minimal) input file?  Thanks.
Comment 2 Tammy Fox 2002-05-01 10:51:40 EDT
Created attachment 56045 [details]
Example SGML file with 2 seealso index terms
Comment 3 Tammy Fox 2002-05-01 10:54:11 EDT
I attached a sample file that produces the error. You can run db2indexed-html
from the docs-stuff CVS module on devserv. It runs collateindex.pl and creates
generated-index.html. Ignore the error msg about not having
Comment 4 Tim Waugh 2002-05-01 12:20:25 EDT
I think I see what's going on. 
What do you think that the generated-index.sgml indexentry element should look 
like for that case?
Comment 5 Tammy Fox 2002-05-01 12:57:25 EDT
The simplest way to fix it is to see if another seealso already exists and
not insert another comma. That seems acceptable to me.
Comment 6 Tim Waugh 2002-05-01 13:02:53 EDT
I'm not sure it's all that simple.  It isn't just the comma that's in the 
wrong place---the ulink isn't allowed there either. 
Please try to edit the generated-index.sgml's indexentry into something you're 
happy with, and I'll try to get collateindex.pl to generate that for this 
Comment 7 Tammy Fox 2002-05-01 16:18:54 EDT
Can you put all the locators in a comma-separated list after the indexterm and
put all the seealso entries at the end of the list like this:

  <primaryie>file system
    <ulink url="test.html" role="AEN9">Chapter Test</ulink>,
    <ulink url="test.html#SECTION" role="AEN30">Example of Section 1

Comment 8 Tim Waugh 2002-05-02 04:36:23 EDT
Created attachment 56144 [details]
Can you test this patch out to see if it does the right thing for you and doesn't break anything else?
Comment 9 Tim Waugh 2002-05-02 10:59:27 EDT
I've built this as docbook-style-dsssl-1.76-2.  Please re-open if it breaks 
something (I'm pretty sure it doesn't).
Comment 10 Tammy Fox 2002-05-02 15:04:53 EDT
Actually, it is putting the seealso statements at the end of the indexterms, but
at the end of the wrong indexterms. I am about to attach a file that has
multiple secondary indexterms under the same primary indexterm. The seealso locators
should be under the ext3 secondary indexterm, not under the last secondary
Comment 11 Tammy Fox 2002-05-02 15:05:54 EDT
Created attachment 56204 [details]
example with multi secondary indexterms
Comment 12 Tim Waugh 2002-05-03 03:31:54 EDT
Please take a look to see if docbook-style-dsssl-1.76-3 is any better.
Comment 13 Tammy Fox 2002-05-03 13:48:34 EDT
Yes. It looks correct now. Thanks!

Note You need to log in before you can comment on or make changes to this bug.