Categorized bibliography error

I am trying to use EndNote X9 to get a categorized bibliography with Chicago 17th Footnotes.
I have a document that has 106 bibliographic references. (I have checked this). They all get generated in the bibliography.
When I go into Word - EndNote X9 - Categorize References - In the configure categories dialogue box that opens up, only 102 references show up. (Not 106).
If I select all the 102 references and put them in Primary Sources and try to generate the bibliography, the the remaining 4 references show up in Uncategorized references. However, these 4 references do not show in the configure categories dialogue box.
I have tried everything i could think of:

  1. Creating a travelling library through Export travelling library, but only 102 references get exported.
  2. Deleted the 04 books from the document and the library and reentering the books again in the endnote library and the document. The error gets generated again.
  3. Uninstalling the EndNote addon in Word and reinstalling.
  4. Going into EndNote - Tools - Recover library. But nothing works.

I have not categorized through editing the style.  I am using the Word addon to try to categorize.

The only thing I have noticed is that these 04 books are references of other book volumes used in the document. But there are other volumes of multi volume works which I have used which do not have a problem.

Has anyone come across such a problem or a solution?

Any help is greatly appreciated. Thanks.