rename leaf nodes to be the table name