I am trying to do some basic filtering in MongoDB Compass, but I keep on getting no results. Here is an example without filtering
And this is with filtering
I've tried the following filters and neither of them work:
{"INSTALL_TYPE" : /.*vpos.*/}
{"DIVISION" : /.*20.*/}
{"DIVISION" : "20"}
However, in another table in the same database, search works fine.
Why am I getting no results when I try filtering in MongoDB Compass in this one table?
The issue was due to the strings having quotation marks in them. When exporting the tables from Oracle SQL, quotation marks were wrapping some of the values. When I then imported the CSV, the CSV which had all its values wrapped it quotes imported fine. However, when importing a CSV where only some of the values had quotes, it caused those entries to have quotes inside the string.
Purging all the CSV files of quotes, emptying the tables, and re importing the CSVs, made all the entries no longer have quotes. And now the filtering works fine.