adds MULTI* and fix a couple of index bugs