228 CHAPTER 11 n FILTERING THE RESULTS OF (Shared web hosting)
228 CHAPTER 11 n FILTERING THE RESULTS OF SEARCHES CHAPTER 11 n FILTERING THE RESULTS OF SEARCHES to map values to parameters. Once you have defined your filter, you need to attach the filter definition to a class. At the end of our User class definition, we specify that it uses a filter named activatedFilter. We then need to set a condition corresponding to an HQL WHERE clause for the attached filter. In our case, we used :activatedParam = activated, where :activatedParam is the named parameter specified on the filter definition, and activated is the column name from the user table. You should ensure that the named parameter goes on the left-hand side so that Hibernate s generated SQL doesn t interfere with any joins. Listing 11-1. Hibernate XML Mapping for User
We recommend you use shared web hosting services, because many users agree that it is cheap, reliable and customer-satisfying webhost.