Select correct table. Fixes #378