Trouble with Database lookup table

Hi,
I have a Database Lookup Table that is giving an incorrect result. It has a simple query with a single qualifier like this:
Select
CODE,
TYPE,
SRCE,
DESC,
From TableName
Where TYPE=‘H’

It seems that the where clause is being ignored because I’m getting back all rows in the table (over 12,000) when I should only be getting back approx. 4,000 with TYPE=‘H’.
I have the exact same SQL query in a DBInput table and I get the correct result. Any ideas?
Thanks

Maybe I’m just not understanding lookup tables very well… will look for some examples of how to use.

Hi pro7,

From what you are saying, I suppose you were using LookupTableReaderWriter. In general, this is not the best component for reading from databases. Instead, please use DBInputTable as you have already found out.

Moreover, it is not that you do not understand lookup tables, but our documentation is not clear about them sometimes. LookupTableReaderWriter is not meant for writing with DB lookup tables at all (with reading not working reliably, either). You may notice we have already raised an issue about this and will pay attention to it soon.

We hope this helps you when working with CloverETL.