Looking for values in a database with complex conditions
In the previous recipe, you saw how to search for columns in a database table based on simple conditions. With Kettle, you can also search by providing complex conditions or involving more than one table. In this recipe, you will learn how to perform that kind of search by using the Database join step. To let you compare the different options for searching data in a database with ease, we will work with the same example that you saw in the preceding recipe—the Steel Wheels sample data. You want to look for products that match a given search term and whose prices are below a given value.
Getting ready
In order to follow this recipe, you need the Steel Wheels database. The code to generate this database is available from several locations, as mentioned in Chapter 1, Working with Databases.
How to do it...
Perform the following steps:
Create a new transformation.
Add a Data Grid step that generates a dataset like the one shown in the following...