I believe this might be some configuration problem, as it was giving the correct count a few days ago.
E.g
neo4j> match (n:LabelA) return n limit 35;
+------------------------------------------------------------------+
| n |
+------------------------------------------------------------------+
| (:LabelA {score: 0.9737793851717902, id: "A"}) |
| (:LabelA {score: 0.9737793851717902, id: "B"}) |
| (:LabelA {score: 0.9746835443037974, id: "C"}) |
| (:LabelA {score: 0.9746835443037974, id: "D"}) |
| (:LabelA {score: 0.9746835443037974, id: "E"}) |
| (:LabelA {score: 0.009041591320072333, id: "F"}) |
| (:LabelA {score: 0.0108499095840868, id: "G"}) |
| (:LabelA {score: 0.0108499095840868, id: "H"}) |
| (:LabelA {score: 0.01175406871609403, id: "I"}) |
| (:LabelA {score: 0.01175406871609403, id: "J"}) |
| (:LabelA {score: 0.0135623869801085, id: "K"}) |
| (:LabelA {score: 0.0135623869801085, id: "L"}) |
| (:LabelA {score: 0.01446654611211573, id: "M"}) |
| (:LabelA {score: 0.01446654611211573, id: "N"}) |
| (:LabelA {score: 0.01537070524412297, id: "O"}) |
| (:LabelA {score: 0.01808318264014467, id: "P"}) |
| (:LabelA {score: 0.01989150090415913, id: "Q"}) |
| (:LabelA {score: 0.02260397830018083, id: "R"}) |
| (:LabelA {score: 0.02350813743218806, id: "S"}) |
| (:LabelA {score: 0.02350813743218806, id: "T"}) |
| (:LabelA {score: 0.0244122965641953, id: "U"}) |
| (:LabelA {score: 0.02622061482820976, id: "V"}) |
| (:LabelA {score: 0.027124773960217, id: "W"}) |
| (:LabelA {score: 0.027124773960217, id: "X"}) |
| (:LabelA {score: 0.0298372513562387, id: "Y"}) |
| (:LabelA {score: 0.03074141048824593, id: "Z"}) |
| (:LabelA {score: 0.03074141048824593, id: "AA"}) |
| (:LabelA {score: 0.0325497287522604, id: "BB"}) |
| (:LabelA {score: 0.0325497287522604, id: "CC"}) |
| (:LabelA {score: 0.03978300180831826, id: "DD"}) |
| (:LabelA {score: 0.0406871609403255, id: "EE"}) |
| (:LabelA {score: 0.0433996383363472, id: "FF"}) |
| (:LabelA {score: 0.0433996383363472, id: "GG"}) |
| (:LabelA {score: 0.04430379746835443, id: "HH"}) |
| (:LabelA {score: 0.04520795660036166, id: "II"}) |
+------------------------------------------------------------------+
35 rows available after 1 ms, consumed after another 1 ms
neo4j> match (n:LabelA) return count(n);
+----------+
| count(n) |
+----------+
| 31 |
+----------+
1 row available after 1 ms, consumed after another 0 ms
There are supposed to be 3968 total nodes, but it returns 31. If I delete all the nodes, then it shows the correct number of nodes deleted.
neo4j> match (n:LabelA) detach delete(n);
0 rows available after 132 ms, consumed after another 0 ms
Deleted 3968 nodes, Deleted 7452 relationships