Merge "Fixed an issue in SampleTable where the table index was incorrectly wrapped around to -1"