Subject Re: [firebird-support] IN clause limitation
Author Doug Chamberlin
G. Plante wrote:
> For example, it can have 200 000 customers in the CUSTOMERS table.
> The user (according to his security level) can access only 10 000
> customers. And when this same user run the report, he could decide to
> print report only for 5000 customers he selected. So, without telling
> you all details, the only way for the moment I have is to use the IN
> clause.

Could you create a view of the customers table that includes the
security restrictions for each user automatically? (Perhaps joining the
customers table with another one that lists each user-customer
combination that can be viewed.) That way each user looks at the view
and not the actual table and thereby only sees the customers they are
entitled to see.

The report generator would also pull data only from the view and should
be able to do that easily.

I have done this before and it works well.