This can be done by replacing std::array with C-arrays (compiler/Intelisense/static analysis crashes on large std::array).
Also split the database in separate columns for better cache-locality. Use a special view that allows for n-bit selection from a unsigned integer array.