adding indexes into format for python2.6 compatibility