print results to out_fh instead of STDOUT
update script gen_data_from_ddl