Added validation for the table id

Closes dandelion/issues#31