Enable Codeigniter Query Builder
I've stumbled upon the same issue today when trying to transition to odbc.
In CI 3.1.0 they dropped support for ODBC on their querybuilder (which -in my opinion- defeats the reasons for using the QB in the first place)
The reason is that their implementation caused a SQL injection vulnerability; however they seem to have no plans on fixing it; but rather disable QB entirely for odbc, locking you in.
source: https://forum.codeigniter.com/thread-65803.html
"upgrade notes": http://www.codeigniter.com/user_guide/installation/upgrade_310.html
Github issue stating unlikeliness of a fix: https://github.com/bcit-ci/CodeIgniter/pull/5197
Check for the following option in application/config/database.php:
$query_builder = TRUE;
$query_builder
should be true
if you want to use query builder classes of CI