I missed one thing, ```ts_visible``` is compared with ```>``` and not equality. But it looks like ```ts_hidden``` is matched against "0" as well.
The problem with queries selecting ```*``` is that they tend to fill up the query cache with unnecessary data and tend to decrease the hit ratio of this cache level. As a best practice, we should always only select the columns we really need.