fix crash in table creation