2010/2/20 Attila <ejjeliorjarat@gmail.com>: > if a == id then -- Checked, they are the same > return t.id > end You will have to use t[id] here, because id is not a constant. t.id is the same as t['id'] which is a different thing altogether!