pylib: fix hostselection database table

before hostselection was a talbe and each time a host was added
or remove entry on the table were added or removed.

Now hostselection is a view so there is no need to add or delete
row from it.

Since for the moment the only used categories in hostselection
are host, os, appliace, and global, the hostselection can be
generated with a wiev.

With this patch both attribute and firewall use hostselection in
their queries so if in the future we want to add generic categories
we can resurrect the table as it was before this patch and insert
element manually. But for the moment the view makes everything
simpler and faster.