I have a situation where in i have the following tables.
Employee - emp_id, emp_name, emp_address
Employee_assets - emp_id(FK), asset_id, asset_name (1-many for employee)
Employee_family_members - emp_id(FK), fm_name, fm_relationship (1-many for employee)
Now, I have to run a scheduled kettle job which reads in the data from these tables in say batches of 1000 employees and create a XML output for those 1000 records based on the relationship in DB with family members and assets. It will be a nested XML record for every employee.
Please note that the performance of this kettle job is very crucial in my scenario.
I have two questions here -
- What is the best way to pull in records from the database for a 1-many relationship in schema?
- What is the best way to generate the XML output structure given that XML join steps are a performance hit?