trialExport: Use incremental query

Instead of getting all rows at once and risiking running out of memory for large datasets use an incremental approuch instead where the data is retrived and exported in increments. Currently 150 datasets per row.