fixed bug in pinning table.