Fixes #123 DatabaseMetaData.getPrimarys respects table filter

• Fixed generated SQL
• Added test coverage