[bugfix] new range index: convert type of lookup key to index type where necessary
[bugfix] new range index: wrong type returned for field
[ignore] Error is expected in test case.
Merge pull request #312 from wolfgangmm/develop

[bugfix] choose correct type for range index lookup