Highlighted
Established Member..
Established Member..
136 views

Logic flaw in index code prevents index from completing

Jump to solution

Logic flaw in index code prevents index from completing
Indexing Knowedge Managment fails. In the Knowledge Errors table the following messages are seen: "Error indexing document, bad attachment'. In many cases customers state that Index Attachments is set to false.

Solution to this problem is provided in KM00245513: The following steps will resolve this issue.
1. Go to Database Manager
2. Access ScriptLibrary
3. Find and open script library "KMDocument_Index"
4. Locate this line (should be line #226): indexDoc = system.library.KMDocument_Index.setDocumentFieldValue("docbody_"+vlang,ALText);
5. Modify the line to read: indexDoc = system.library.KMDocument_Index.setDocumentFieldValue("docbody_"+vlang,ALText, indexDoc);
6. Save
7. Perform a Full Index on Knowledge_Library
8. Index should complete and errors should no longer be present.

Problem is i can't locate line: indexDoc = system.library.KMDocument_Index.setDocumentFieldValue("docbody_"+vlang,ALText);

in UAT or PROD (attached).

The closest to this line i can get is: indexDoc = system.library.KMDocument_Index.setDocumentFieldValue( "adlearn_" + vlang, ALText, indexDoc );

0 Likes
1 Solution

Accepted Solutions
Highlighted
Acclaimed Contributor.
Acclaimed Contributor.

Re: Logic flaw in index code prevents index from completing

Jump to solution

Hello Xholi,

hope you are doing fine.

According to your description I check from 9.31 to 9.41 OOB and in all of them I have the same script line:

indexDoc = system.library.KMDocument_Index.setDocumentFieldValue("docbody_"+vlang,docbodyfile, indexDoc);

I believe that maybe the KM is not correct about and was a little mistake. Here are to possible suggestion, modify the above line or modify the line below:

indexDoc = system.library.KMDocument_Index.setDocumentFieldVa​lue( "adlearn_" + vlang, ALText, indexDoc );

The result would be:

indexDoc = system.library.KMDocument_Index.setDocumentFieldValue("docbody_"+vlang,docbodyfile, indexDoc);

by

indexDoc = system.library.KMDocument_Index.setDocumentFieldValue("docbody_"+vlang,ALText, indexDoc);

OR

indexDoc = system.library.KMDocument_Index.setDocumentFieldVa​lue( "adlearn_" + vlang, ALText, indexDoc );

by

indexDoc = system.library.KMDocument_Index.setDocumentFieldVa​lue( "docbody_" + vlang, ALText, indexDoc );

Test one change, if doesn't work test the another change. In case to not have positive results, we should report thst the we need to fix the KM.

Carlos Villalobos R
Customer Support Engineer
If you find that this or any other post resolves your issue, please be sure to mark it as an accepted solution.
If you are satisfied with anyone’s response please remember to give them a KUDOS by clicking on the STAR at the bottom left of the post and show your appreciation.

View solution in original post

0 Likes
1 Reply
Highlighted
Acclaimed Contributor.
Acclaimed Contributor.

Re: Logic flaw in index code prevents index from completing

Jump to solution

Hello Xholi,

hope you are doing fine.

According to your description I check from 9.31 to 9.41 OOB and in all of them I have the same script line:

indexDoc = system.library.KMDocument_Index.setDocumentFieldValue("docbody_"+vlang,docbodyfile, indexDoc);

I believe that maybe the KM is not correct about and was a little mistake. Here are to possible suggestion, modify the above line or modify the line below:

indexDoc = system.library.KMDocument_Index.setDocumentFieldVa​lue( "adlearn_" + vlang, ALText, indexDoc );

The result would be:

indexDoc = system.library.KMDocument_Index.setDocumentFieldValue("docbody_"+vlang,docbodyfile, indexDoc);

by

indexDoc = system.library.KMDocument_Index.setDocumentFieldValue("docbody_"+vlang,ALText, indexDoc);

OR

indexDoc = system.library.KMDocument_Index.setDocumentFieldVa​lue( "adlearn_" + vlang, ALText, indexDoc );

by

indexDoc = system.library.KMDocument_Index.setDocumentFieldVa​lue( "docbody_" + vlang, ALText, indexDoc );

Test one change, if doesn't work test the another change. In case to not have positive results, we should report thst the we need to fix the KM.

Carlos Villalobos R
Customer Support Engineer
If you find that this or any other post resolves your issue, please be sure to mark it as an accepted solution.
If you are satisfied with anyone’s response please remember to give them a KUDOS by clicking on the STAR at the bottom left of the post and show your appreciation.

View solution in original post

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.