I found a bit of a hack.
@property CI_DB_result $query
To your model.
Then rather than
$query = $this->db->query(), Use
$this->query = $this->db->query().
Then, as you type
$this->query, the autocompleter will come up as expected.
This will be troublesome though if you need to have 2 queries active, or a query within a loop from another query. In such cases, you would have to have 2 variables for each query.