This Zetadocs technical note applies to:
- Zetadocs NAV 5.5 and above
When opening a NAV record which has a large number of associated lines, an error message “Failed to search for documents in SharePoint” is shown and no related documents appear in the Zetadocs addin. This is more likely to occur in a 32 bit SharePoint system.
Users may also notice the Zetadocs Document Factbox loading and archiving slowly in records with large numbers of lines.
Zetadocs needs to pass a query to SharePoint in order to fetch all related documents for the open NAV record and any associated records. The search query includes searches for documents archived against line items, which do not usually have documents associated with them. This combined query results in a large SharePoint search when there are a large number of lines associated with the record.
When SharePoint performs the search, it is possible that the memory limit for a 32-bit process is reached, and thus a memory error is returned to Zetadocs, which results in the “Failed to search for documents in SharePoint” error message.
This issue has been resolved in the September update rollup (6.1.338) of Zetadocs for NAV, available for download here.
Please note that for NAV 2013, the fix is available in the September update rollup with a file date of 10th February 2015.
There is now a configurable flag that provides the option to exclude unnecessary items from the SharePoint search query. The steps to exclude the line items are detailed below:
- Run Table9041213 – Zetadocs Record Mapping Header from the Object Designer.
- Check the “Navigation Only” box for each to following mappings:
- 4 Purchase Invoice Line -> Posted Purchase Receipt
- 8 Purchase Header -> Purchase Lines
- 9 Posted Puchase Invoice -> Posted Purchase Invoice Line
- 14 Sales Header -> Sales Line
- 15 Posted Sales Invoice -> Posted Sales Invoice Line
- 32 Posted Purchase Invoice -> Posted Purchase Receipts
- 44 Posted Shipment -> Shipment Line
- 45 Posted Credit Memo -> Posted Credit Memo Line
- 46 Posted Return Receipt -> Posted Return Receipt Line
- 47 Posted Purchase Receipt -> Posted Purchase Receipt Line
- 48 Posted Purchase Credit Memo -> Posted Purchase Credit Memo Line
- 49 Posted Return Shipment -> Posted Return Shipment Line
This excludes line items from the SharePoint query for all record types, but will still search for records that are related to those lines. Anything that is archived against these line items will no longer appear in the Zetadocs addin for the opened record type.
The “Navigation Only” table column can be enabled for any other mappings to exclude the unneeded record types from the SharePoint search.
This behaviour was corrected in the update detailed above.
Last updated: 25th November 2015 (SB/NT/WK/NT)
Keywords: SharePoint memory search fail delay