Table module fix for compound attributes & improve paging performance

- Table module fix for compound attributes
- Improve paging performance by moving some code getTableMetaData